[openwrt/openwrt] build: build kernel image before building modules/packages

LEDE Commits lede-commits at lists.infradead.org
Tue Feb 16 14:10:20 EST 2021


nbd pushed a commit to openwrt/openwrt.git, branch master:
https://git.openwrt.org/5ed1e5140a80558ab47fd70410ae3242bed5becf

commit 5ed1e5140a80558ab47fd70410ae3242bed5becf
Author: Felix Fietkau <nbd at nbd.name>
AuthorDate: Thu Oct 22 10:29:34 2020 +0200

    build: build kernel image before building modules/packages
    
    This is needed for linux 5.10, where modules.builtin is generated from
    vmlinux.o
    
    Signed-off-by: Felix Fietkau <nbd at nbd.name>
---
 include/kernel-defaults.mk | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/include/kernel-defaults.mk b/include/kernel-defaults.mk
index e5a0ba367b..b069c1e671 100644
--- a/include/kernel-defaults.mk
+++ b/include/kernel-defaults.mk
@@ -113,7 +113,7 @@ endef
 
 define Kernel/CompileModules/Default
 	rm -f $(LINUX_DIR)/vmlinux $(LINUX_DIR)/System.map
-	+$(KERNEL_MAKE) modules
+	+$(KERNEL_MAKE) $(if $(KERNELNAME),$(KERNELNAME),all) modules
 endef
 
 OBJCOPY_STRIP = -R .reginfo -R .notes -R .note -R .comment -R .mdebug -R .note.gnu.build-id
@@ -137,7 +137,7 @@ endef
 
 define Kernel/CompileImage/Default
 	rm -f $(TARGET_DIR)/init
-	+$(KERNEL_MAKE) $(if $(KERNELNAME),$(KERNELNAME),all) modules
+	+$(KERNEL_MAKE) $(if $(KERNELNAME),$(KERNELNAME),all)
 	$(call Kernel/CopyImage)
 endef
 
@@ -147,7 +147,7 @@ define Kernel/CompileImage/Initramfs
 	$(CP) $(GENERIC_PLATFORM_DIR)/other-files/init $(TARGET_DIR)/init
 	$(if $(SOURCE_DATE_EPOCH),touch -hcd "@$(SOURCE_DATE_EPOCH)" $(TARGET_DIR)/init)
 	rm -rf $(KERNEL_BUILD_DIR)/linux-$(LINUX_VERSION)/usr/initramfs_data.cpio*
-	+$(KERNEL_MAKE) $(if $(KERNELNAME),$(KERNELNAME),all) modules
+	+$(KERNEL_MAKE) $(if $(KERNELNAME),$(KERNELNAME),all)
 	$(call Kernel/CopyImage,-initramfs)
 endef
 else



More information about the lede-commits mailing list