[PATCH 19/20] [WIP] build: point remainder at $(LINUX_SRC_DIR)
Elliott Mitchell
ehem+openwrt at m5p.com
Sat Nov 11 22:51:08 PST 2023
These appear to need the kernel source, but my confidence is less than
certain on several spots.
Signed-off-by: Elliott Mitchell <ehem+openwrt at m5p.com>
---
include/kernel-defaults.mk | 6 +++---
package/kernel/cryptodev-linux/Makefile | 2 +-
package/kernel/linux/modules/w1.mk | 4 ++--
package/kernel/qca-ssdk/Makefile | 2 +-
package/network/utils/arptables/Makefile | 2 +-
target/imagebuilder/Makefile | 2 +-
target/imagebuilder/files/Makefile | 4 ++--
target/sdk/Makefile | 6 +++---
toolchain/kernel-headers/Makefile | 2 +-
9 files changed, 15 insertions(+), 15 deletions(-)
diff --git a/include/kernel-defaults.mk b/include/kernel-defaults.mk
index 178d4c0a5d..a170e86cef 100644
--- a/include/kernel-defaults.mk
+++ b/include/kernel-defaults.mk
@@ -31,10 +31,10 @@ ifeq ($(strip $(CONFIG_EXTERNAL_KERNEL_TREE)),"")
else
define Kernel/Prepare/Default
mkdir -p $(KERNEL_BUILD_DIR)
- if [ -d $(LINUX_DIR) ]; then \
- rmdir $(LINUX_DIR); \
+ if [ -d $(LINUX_SRC_DIR) ]; then \
+ rmdir $(LINUX_SRC_DIR); \
fi
- ln -s $(CONFIG_EXTERNAL_KERNEL_TREE) $(LINUX_DIR)
+ ln -s $(CONFIG_EXTERNAL_KERNEL_TREE) $(LINUX_SRC_DIR)
if [ -d $(LINUX_OBJ_DIR)/user_headers ]; then \
rm -rf $(LINUX_OBJ_DIR)/user_headers; \
fi
diff --git a/package/kernel/cryptodev-linux/Makefile b/package/kernel/cryptodev-linux/Makefile
index 0c1f63a605..40692eb060 100644
--- a/package/kernel/cryptodev-linux/Makefile
+++ b/package/kernel/cryptodev-linux/Makefile
@@ -47,7 +47,7 @@ endef
define Build/Compile
$(MAKE) -C $(PKG_BUILD_DIR) \
$(KERNEL_MAKE_FLAGS) \
- KERNEL_DIR="$(LINUX_DIR)"
+ KERNEL_DIR="$(LINUX_SRC_DIR)"
endef
define Build/InstallDev
diff --git a/package/kernel/linux/modules/w1.mk b/package/kernel/linux/modules/w1.mk
index e6b5263e2c..55d7e60cca 100644
--- a/package/kernel/linux/modules/w1.mk
+++ b/package/kernel/linux/modules/w1.mk
@@ -6,8 +6,8 @@
#
W1_MENU:=W1 support
-W1_MASTERS_DIR:=$(LINUX_DIR)/drivers/w1/masters
-W1_SLAVES_DIR:=$(LINUX_DIR)/drivers/w1/slaves
+W1_MASTERS_DIR:=$(LINUX_SRC_DIR)/drivers/w1/masters
+W1_SLAVES_DIR:=$(LINUX_SRC_DIR)/drivers/w1/slaves
define KernelPackage/w1
SUBMENU:=$(W1_MENU)
diff --git a/package/kernel/qca-ssdk/Makefile b/package/kernel/qca-ssdk/Makefile
index 3770d29e8c..69e1eff8b1 100644
--- a/package/kernel/qca-ssdk/Makefile
+++ b/package/kernel/qca-ssdk/Makefile
@@ -36,7 +36,7 @@ LNX_CONFIG_OPTS = LNX_MAKEOPTS='$(KERNEL_MAKEOPTS)' MODULE_TYPE=KSLIB modules
MAKE_FLAGS+= \
TARGET_NAME=$(CONFIG_TARGET_NAME) \
TOOL_PATH=$(firstword $(TOOLCHAIN_BIN_DIRS)) \
- SYS_PATH=$(LINUX_DIR) \
+ SYS_PATH=$(LINUX_SRC_DIR) \
TOOLPREFIX=$(TARGET_CROSS) \
KVER=$(LINUX_VERSION) \
ARCH=$(LINUX_KARCH) \
diff --git a/package/network/utils/arptables/Makefile b/package/network/utils/arptables/Makefile
index 7f32ed1395..520c7dcf27 100644
--- a/package/network/utils/arptables/Makefile
+++ b/package/network/utils/arptables/Makefile
@@ -32,7 +32,7 @@ endef
MAKE_FLAGS += \
COPT_FLAGS="$(TARGET_CFLAGS) -D__OPTIMIZE__=1" \
- KERNEL_DIR="$(LINUX_DIR)"
+ KERNEL_DIR="$(LINUX_SRC_DIR)"
define Package/arptables-legacy/install
$(INSTALL_DIR) $(1)/usr/sbin
diff --git a/target/imagebuilder/Makefile b/target/imagebuilder/Makefile
index c4910b6c4b..1a68f6e374 100644
--- a/target/imagebuilder/Makefile
+++ b/target/imagebuilder/Makefile
@@ -15,7 +15,7 @@ override MAKEFLAGS=
IB_NAME:=$(VERSION_DIST_SANITIZED)-imagebuilder-$(if $(CONFIG_VERSION_FILENAMES),$(VERSION_NUMBER)-)$(BOARD)$(if $(SUBTARGET),-$(SUBTARGET)).$(HOST_OS)-$(HOST_ARCH)
PKG_BUILD_DIR:=$(BUILD_DIR)/$(IB_NAME)
IB_KDIR:=$(patsubst $(TOPDIR)/%,$(PKG_BUILD_DIR)/%,$(KERNEL_BUILD_DIR))
-IB_LDIR:=$(patsubst $(TOPDIR)/%,$(PKG_BUILD_DIR)/%,$(LINUX_DIR))
+IB_LDIR:=$(patsubst $(TOPDIR)/%,$(PKG_BUILD_DIR)/%,$(LINUX_SRC_DIR))
IB_DTSDIR:=$(patsubst $(TOPDIR)/%,$(PKG_BUILD_DIR)/%,$(LINUX_SRC_DIR))/arch/$(LINUX_KARCH)/boot/dts/
IB_IDIR:=$(patsubst $(TOPDIR)/%,$(PKG_BUILD_DIR)/%,$(STAGING_DIR_IMAGE))
diff --git a/target/imagebuilder/files/Makefile b/target/imagebuilder/files/Makefile
index 78ec7e2e94..1e4d91324b 100644
--- a/target/imagebuilder/files/Makefile
+++ b/target/imagebuilder/files/Makefile
@@ -184,8 +184,8 @@ package_list: FORCE
package_install: FORCE
@echo
@echo Installing packages...
- $(OPKG) install $(firstword $(wildcard $(LINUX_DIR)/libc_*.ipk $(PACKAGE_DIR)/libc_*.ipk))
- $(OPKG) install $(firstword $(wildcard $(LINUX_DIR)/kernel_*.ipk $(PACKAGE_DIR)/kernel_*.ipk))
+ $(OPKG) install $(firstword $(wildcard $(LINUX_SRC_DIR)/libc_*.ipk $(PACKAGE_DIR)/libc_*.ipk))
+ $(OPKG) install $(firstword $(wildcard $(LINUX_SRC_DIR)/kernel_*.ipk $(PACKAGE_DIR)/kernel_*.ipk))
$(OPKG) install $(BUILD_PACKAGES)
prepare_rootfs: FORCE
diff --git a/target/sdk/Makefile b/target/sdk/Makefile
index 243d58bbaf..d118ff5ed6 100644
--- a/target/sdk/Makefile
+++ b/target/sdk/Makefile
@@ -49,7 +49,7 @@ BASE_FEED:=$(if $(BASE_FEED),$(BASE_FEED),$(shell cd $(TOPDIR); LC_ALL=C git svn
BASE_FEED:=$(if $(BASE_FEED),$(BASE_FEED),$(shell cd $(TOPDIR); LC_ALL=C svn info 2>/dev/null | sed -ne 's/^URL: /src-svn base /p'))
BASE_FEED:=$(if $(BASE_FEED),$(BASE_FEED),src-git-full base $(PROJECT_GIT)/openwrt/openwrt.git$(if $(GIT_BRANCH),;$(GIT_BRANCH),$(if $(GIT_TAGNAME),;$(GIT_TAGNAME))))
-KDIR_BASE = $(patsubst $(TOPDIR)/%,%,$(LINUX_DIR))
+KDIR_BASE = $(patsubst $(TOPDIR)/%,%,$(LINUX_SRC_DIR))
KDIR_ARCHES = $(LINUX_KARCH)
# arch/arm64/ includes reference files in arch/arm/, so we'll need both
@@ -78,7 +78,7 @@ KERNEL_FILES_BASE := \
modules.builtin \
$(foreach arch,$(KDIR_ARCHES),$(addprefix arch/$(arch)/,$(KERNEL_FILES_ARCH)))
-KERNEL_FILES := $(patsubst $(TOPDIR)/%,%,$(wildcard $(addprefix $(LINUX_DIR)/,$(KERNEL_FILES_BASE))))
+KERNEL_FILES := $(patsubst $(TOPDIR)/%,%,$(wildcard $(addprefix $(LINUX_SRC_DIR)/,$(KERNEL_FILES_BASE))))
# The kernel source hosts various userspace utilities sources.
# These are packaged separately from the kernel and kernel modules.
@@ -91,7 +91,7 @@ USERSPACE_UTILS_FILES := \
tools/spi \
tools/usb/usbip
-USERSPACE_FILES := $(patsubst $(TOPDIR)/%,%,$(wildcard $(addprefix $(LINUX_DIR)/,$(USERSPACE_UTILS_FILES))))
+USERSPACE_FILES := $(patsubst $(TOPDIR)/%,%,$(wildcard $(addprefix $(LINUX_SRC_DIR)/,$(USERSPACE_UTILS_FILES))))
all: compile
diff --git a/toolchain/kernel-headers/Makefile b/toolchain/kernel-headers/Makefile
index dc70f32c90..4191173909 100644
--- a/toolchain/kernel-headers/Makefile
+++ b/toolchain/kernel-headers/Makefile
@@ -38,7 +38,7 @@ else
endif
HOST_BUILD_DIR:=$(KERNEL_BUILD_DIR)/linux-$(LINUX_VERSION)
PKG_HASH:=$(LINUX_KERNEL_HASH)
-LINUX_DIR := $(HOST_BUILD_DIR)
+LINUX_SRC_DIR := $(HOST_BUILD_DIR)
FILES_DIR :=
PATCH_DIR := ./patches$(if $(wildcard ./patches-$(LINUX_VERSION)),-$(LINUX_VERSION))
--
(\___(\___(\______ --=> 8-) EHM <=-- ______/)___/)___/)
\BS ( | ehem+openwrt at m5p.com PGP 87145445 | ) /
\_CS\ | _____ -O #include <stddisclaimer.h> O- _____ | / _/
8A19\___\_|_/58D2 7E3D DDF4 7BA6 <-PGP-> 41D1 B375 37D0 8714\_|_/___/5445
More information about the openwrt-devel
mailing list