diff options
Diffstat (limited to 'debian/patches/debian/kbuild-look-for-module.lds-under-arch-directory-too.patch')
-rw-r--r-- | debian/patches/debian/kbuild-look-for-module.lds-under-arch-directory-too.patch | 27 |
1 files changed, 16 insertions, 11 deletions
diff --git a/debian/patches/debian/kbuild-look-for-module.lds-under-arch-directory-too.patch b/debian/patches/debian/kbuild-look-for-module.lds-under-arch-directory-too.patch index eea69e455..174199c4c 100644 --- a/debian/patches/debian/kbuild-look-for-module.lds-under-arch-directory-too.patch +++ b/debian/patches/debian/kbuild-look-for-module.lds-under-arch-directory-too.patch @@ -22,26 +22,29 @@ Therefore, we move module.lds under the arch build directory in rules.real and change Makefile.modfinal to look for it in both places. --- -Index: linux/scripts/Makefile.modfinal -=================================================================== ---- linux.orig/scripts/Makefile.modfinal -+++ linux/scripts/Makefile.modfinal -@@ -29,12 +29,13 @@ quiet_cmd_cc_o_c = CC [M] $@ + scripts/Makefile.modfinal | 6 ++++-- + 1 file changed, 4 insertions(+), 2 deletions(-) + +diff --git a/scripts/Makefile.modfinal b/scripts/Makefile.modfinal +index 8568d256d6fb..415cff66539b 100644 +--- a/scripts/Makefile.modfinal ++++ b/scripts/Makefile.modfinal +@@ -28,11 +28,13 @@ quiet_cmd_cc_o_c = CC [M] $@ + %.mod.o: %.mod.c FORCE $(call if_changed_dep,cc_o_c) - ARCH_POSTLINK := $(wildcard $(srctree)/arch/$(SRCARCH)/Makefile.postlink) +ARCH_MODULE_LDS := $(word 1,$(wildcard scripts/module.lds arch/$(SRCARCH)/module.lds)) - ++ quiet_cmd_ld_ko_o = LD [M] $@ cmd_ld_ko_o += \ $(LD) -r $(KBUILD_LDFLAGS) \ $(KBUILD_LDFLAGS_MODULE) $(LDFLAGS_MODULE) \ -- -T scripts/module.lds -o $@ $(filter %.o, $^); \ -+ -T $(ARCH_MODULE_LDS) -o $@ $(filter %.o, $^); \ - $(if $(ARCH_POSTLINK), $(MAKE) -f $(ARCH_POSTLINK) $@, true) +- -T scripts/module.lds -o $@ $(filter %.o, $^) ++ -T $(ARCH_MODULE_LDS) -o $@ $(filter %.o, $^) quiet_cmd_btf_ko = BTF [M] $@ -@@ -57,7 +58,7 @@ if_changed_except = $(if $(call newer_pr + cmd_btf_ko = \ +@@ -52,7 +54,7 @@ if_changed_except = $(if $(call newer_prereqs_except,$(2))$(cmd-check), \ printf '%s\n' 'savedcmd_$@ := $(make-cmd)' > $(dot-target).cmd, @:) # Re-generate module BTFs if either module's .ko or vmlinux changed @@ -50,3 +53,5 @@ Index: linux/scripts/Makefile.modfinal +$(call if_changed_except,ld_ko_o,vmlinux) ifdef CONFIG_DEBUG_INFO_BTF_MODULES +$(if $(newer-prereqs),$(call cmd,btf_ko)) +-- +2.42.0 |