[Buildroot] [git commit] package/linux-headers: use BR2_MAKE

Arnout Vandecappelle arnout at mind.be
Mon Apr 10 15:24:14 UTC 2023


commit: https://git.buildroot.net/buildroot/commit/?id=36bdfd29d87d48c3519876d93738b2aae9d7cb97
branch: https://git.buildroot.net/buildroot/commit/?id=refs/heads/master

Since kernel version 6.2, the minimum GNU Make version is 3.82 [1]. We
have an optional host-make 4.0 minimum dependency, so we can use it as
is. It's a bit unfortunate that we have to apply this even to older
kernel versions, but make itself builds fairly fast compared to the
toolchain (which is the only reason to build linux-headers).

Use BR2_MAKE for linux-headers, and depend on BR2_MAKE_HOST_DEPENDENCY.

Signed-off-by: Oleg Lyovin <ovlevin at sberdevices.ru>
Signed-off-by: Arnout Vandecappelle <arnout at mind.be>
---
 package/linux-headers/linux-headers.mk | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/package/linux-headers/linux-headers.mk b/package/linux-headers/linux-headers.mk
index e2a0b7a7c9..b4b5a5b47d 100644
--- a/package/linux-headers/linux-headers.mk
+++ b/package/linux-headers/linux-headers.mk
@@ -125,6 +125,8 @@ LINUX_HEADERS_INSTALL_STAGING = YES
 # linux-headers is part of the toolchain so disable the toolchain dependency
 LINUX_HEADERS_ADD_TOOLCHAIN_DEPENDENCY = NO
 
+LINUX_HEADERS_DEPENDENCIES = $(BR2_MAKE_HOST_DEPENDENCY)
+
 # For some architectures (eg. Arc, Cris, Hexagon, ia64, parisc,
 # score and xtensa), the Linux buildsystem tries to call the
 # cross-compiler, although it is not needed at all.
@@ -137,7 +139,7 @@ LINUX_HEADERS_ADD_TOOLCHAIN_DEPENDENCY = NO
 # of "its" headers
 define LINUX_HEADERS_CONFIGURE_CMDS
 	(cd $(@D); \
-		$(TARGET_MAKE_ENV) $(MAKE) \
+		$(TARGET_MAKE_ENV) $(BR2_MAKE) \
 			ARCH=$(KERNEL_ARCH) \
 			HOSTCC="$(HOSTCC)" \
 			HOSTCFLAGS="$(HOSTCFLAGS)" \
@@ -148,7 +150,7 @@ endef
 
 define LINUX_HEADERS_INSTALL_STAGING_CMDS
 	(cd $(@D); \
-		$(TARGET_MAKE_ENV) $(MAKE) \
+		$(TARGET_MAKE_ENV) $(BR2_MAKE) \
 			ARCH=$(KERNEL_ARCH) \
 			HOSTCC="$(HOSTCC)" \
 			HOSTCFLAGS="$(HOSTCFLAGS)" \



More information about the buildroot mailing list