summaryrefslogtreecommitdiffstats
path: root/scripts/Makefile.asm-generic
diff options
context:
space:
mode:
authorMasahiro Yamada <masahiroy@kernel.org>2022-11-19 04:15:50 +0900
committerMasahiro Yamada <masahiroy@kernel.org>2022-11-22 23:40:02 +0900
commita2430b25c31840a6dcbf95c65415d5fee2984dbc (patch)
tree279c58348f88232abb0a350fed080547e94163c3 /scripts/Makefile.asm-generic
parent5724ac5589ad93d35d95a845222f566175c681b8 (diff)
downloadlinux-stable-a2430b25c31840a6dcbf95c65415d5fee2984dbc.tar.gz
linux-stable-a2430b25c31840a6dcbf95c65415d5fee2984dbc.tar.bz2
linux-stable-a2430b25c31840a6dcbf95c65415d5fee2984dbc.zip
kbuild: add kbuild-file macro
While building, installing, cleaning, Kbuild visits sub-directories and includes 'Kbuild' or 'Makefile' that exists there. Add 'kbuild-file' macro, and reuse it from scripts/Makefie.* Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> Reviewed-by: Nicolas Schier <nicolas@fjasle.eu> Reviewed-by: Alexander Lobakin <alobakin@pm.me> Tested-by: Alexander Lobakin <alobakin@pm.me>
Diffstat (limited to 'scripts/Makefile.asm-generic')
-rw-r--r--scripts/Makefile.asm-generic6
1 files changed, 3 insertions, 3 deletions
diff --git a/scripts/Makefile.asm-generic b/scripts/Makefile.asm-generic
index 1d501c57f9ef..8d01b37b7677 100644
--- a/scripts/Makefile.asm-generic
+++ b/scripts/Makefile.asm-generic
@@ -10,15 +10,15 @@ PHONY := all
all:
src := $(subst /generated,,$(obj))
--include $(src)/Kbuild
+
+include $(srctree)/scripts/Kbuild.include
+-include $(kbuild-file)
# $(generic)/Kbuild lists mandatory-y. Exclude um since it is a special case.
ifneq ($(SRCARCH),um)
include $(srctree)/$(generic)/Kbuild
endif
-include $(srctree)/scripts/Kbuild.include
-
redundant := $(filter $(mandatory-y) $(generated-y), $(generic-y))
redundant += $(foreach f, $(generic-y), $(if $(wildcard $(srctree)/$(src)/$(f)),$(f)))
redundant := $(sort $(redundant))