mirror of
https://github.com/torvalds/linux.git
synced 2026-04-18 06:44:00 -04:00
kbuild: add $(objtree)/ prefix to some in-kernel build artifacts
$(objtree) refers to the top of the output directory of kernel builds. This commit adds the explicit $(objtree)/ prefix to build artifacts needed for building external modules. This change has no immediate impact, as the top-level Makefile currently defines: objtree := . This commit prepares for supporting the building of external modules in a different directory. Signed-off-by: Masahiro Yamada <masahiroy@kernel.org> Reviewed-by: Nicolas Schier <nicolas@fjasle.eu>
This commit is contained in:
@@ -35,10 +35,10 @@
|
||||
PHONY := __modpost
|
||||
__modpost:
|
||||
|
||||
include include/config/auto.conf
|
||||
include $(objtree)/include/config/auto.conf
|
||||
include $(srctree)/scripts/Kbuild.include
|
||||
|
||||
MODPOST = scripts/mod/modpost
|
||||
MODPOST = $(objtree)/scripts/mod/modpost
|
||||
|
||||
modpost-args = \
|
||||
$(if $(CONFIG_MODULES),-M) \
|
||||
@@ -119,11 +119,11 @@ include $(kbuild-file)
|
||||
|
||||
output-symdump := $(KBUILD_EXTMOD)/Module.symvers
|
||||
|
||||
ifeq ($(wildcard Module.symvers),)
|
||||
missing-input := Module.symvers
|
||||
ifeq ($(wildcard $(objtree)/Module.symvers),)
|
||||
missing-input := $(objtree)/Module.symvers
|
||||
else
|
||||
modpost-args += -i Module.symvers
|
||||
modpost-deps += Module.symvers
|
||||
modpost-args += -i $(objtree)/Module.symvers
|
||||
modpost-deps += $(objtree)/Module.symvers
|
||||
endif
|
||||
|
||||
modpost-args += -e $(addprefix -i , $(KBUILD_EXTRA_SYMBOLS))
|
||||
|
||||
Reference in New Issue
Block a user