aboutsummaryrefslogtreecommitdiff
path: root/scripts/Kbuild.include
diff options
context:
space:
mode:
authorMichal Marek <mmarek@suse.cz>2009-12-07 16:38:33 +0100
committerMichal Marek <mmarek@suse.cz>2009-12-12 13:08:16 +0100
commitbc081dd6e9f622c73334dc465359168543ccaabf (patch)
treec015f5eba8e1bc79b2eb3861b8e95f15ee6d047d /scripts/Kbuild.include
parent6299fee7b84ac7b4429b4e2787b99470a89cd5f5 (diff)
kbuild: generate modules.builtin
To make it easier for module-init-tools and scripts like mkinitrd to distinguish builtin and missing modules, install a modules.builtin file listing all builtin modules. This is done by generating an additional config file (tristate.conf) with tristate options set to uppercase 'Y' or 'M'. If we source that config file, the builtin modules appear in obj-Y. Signed-off-by: Michal Marek <mmarek@suse.cz>
Diffstat (limited to 'scripts/Kbuild.include')
-rw-r--r--scripts/Kbuild.include6
1 files changed, 6 insertions, 0 deletions
diff --git a/scripts/Kbuild.include b/scripts/Kbuild.include
index c67e73ecd5b..ed2773edfe7 100644
--- a/scripts/Kbuild.include
+++ b/scripts/Kbuild.include
@@ -149,6 +149,12 @@ ld-option = $(call try-run,\
# $(Q)$(MAKE) $(build)=dir
build := -f $(if $(KBUILD_SRC),$(srctree)/)scripts/Makefile.build obj
+###
+# Shorthand for $(Q)$(MAKE) -f scripts/Makefile.modbuiltin obj=
+# Usage:
+# $(Q)$(MAKE) $(modbuiltin)=dir
+modbuiltin := -f $(if $(KBUILD_SRC),$(srctree)/)scripts/Makefile.modbuiltin obj
+
# Prefix -I with $(srctree) if it is not an absolute path.
# skip if -I has no parameter
addtree = $(if $(patsubst -I%,%,$(1)), \