Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

kbuild: do not require sub-make for separate output tree builds

As explained in commit 3204a7fb98a3 ("kbuild: prefix $(srctree)/ to some
included Makefiles"), I want to stop using --include-dir some day.

I already fixed up the top Makefile, but some arch Makefiles (mips, um,
x86) still include check-in Makefiles without $(srctree)/.

Fix them up so 'need-sub-make := 1' can go away for this case.

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>

+7 -8
+2 -3
Makefile
··· 191 191 ifneq ($(abs_srctree),$(abs_objtree)) 192 192 # Look for make include files relative to root of kernel src 193 193 # 194 - # This does not become effective immediately because MAKEFLAGS is re-parsed 195 - # once after the Makefile is read. We need to invoke sub-make. 194 + # --included-dir is added for backward compatibility, but you should not rely on 195 + # it. Please add $(srctree)/ prefix to include Makefiles in the source tree. 196 196 MAKEFLAGS += --include-dir=$(abs_srctree) 197 - need-sub-make := 1 198 197 endif 199 198 200 199 ifneq ($(filter 3.%,$(MAKE_VERSION)),)
+1 -1
arch/mips/Makefile
··· 254 254 # 255 255 # Board-dependent options and extra files 256 256 # 257 - include arch/mips/Kbuild.platforms 257 + include $(srctree)/arch/mips/Kbuild.platforms 258 258 259 259 ifdef CONFIG_PHYSICAL_START 260 260 load-y = $(CONFIG_PHYSICAL_START)
+3 -3
arch/um/Makefile
··· 41 41 42 42 HOST_DIR := arch/$(HEADER_ARCH) 43 43 44 - include $(ARCH_DIR)/Makefile-skas 45 - include $(HOST_DIR)/Makefile.um 44 + include $(srctree)/$(ARCH_DIR)/Makefile-skas 45 + include $(srctree)/$(HOST_DIR)/Makefile.um 46 46 47 47 core-y += $(HOST_DIR)/um/ 48 48 ··· 76 76 -idirafter $(objtree)/include -D__KERNEL__ -D__UM_HOST__ 77 77 78 78 #This will adjust *FLAGS accordingly to the platform. 79 - include $(ARCH_DIR)/Makefile-os-$(OS) 79 + include $(srctree)/$(ARCH_DIR)/Makefile-os-$(OS) 80 80 81 81 KBUILD_CPPFLAGS += -I$(srctree)/$(HOST_DIR)/include \ 82 82 -I$(srctree)/$(HOST_DIR)/include/uapi \
+1 -1
arch/x86/Makefile
··· 75 75 KBUILD_CFLAGS += $(call cc-option,$(cc_stack_align4)) 76 76 77 77 # CPU-specific tuning. Anything which can be shared with UML should go here. 78 - include arch/x86/Makefile_32.cpu 78 + include $(srctree)/arch/x86/Makefile_32.cpu 79 79 KBUILD_CFLAGS += $(cflags-y) 80 80 81 81 # temporary until string.h is fixed