diff options
Diffstat (limited to 'Makefile')
-rw-r--r-- | Makefile | 27 |
1 files changed, 11 insertions, 16 deletions
@@ -404,7 +404,7 @@ include $(srctree)/arch/$(ARCH)/Makefile | |||
404 | export KBUILD_DEFCONFIG | 404 | export KBUILD_DEFCONFIG |
405 | 405 | ||
406 | config %config: scripts_basic outputmakefile FORCE | 406 | config %config: scripts_basic outputmakefile FORCE |
407 | $(Q)mkdir -p include/linux | 407 | $(Q)mkdir -p include/linux include/config |
408 | $(Q)$(MAKE) $(build)=scripts/kconfig $@ | 408 | $(Q)$(MAKE) $(build)=scripts/kconfig $@ |
409 | $(Q)$(MAKE) -C $(srctree) KBUILD_SRC= .kernelrelease | 409 | $(Q)$(MAKE) -C $(srctree) KBUILD_SRC= .kernelrelease |
410 | 410 | ||
@@ -421,8 +421,6 @@ PHONY += scripts | |||
421 | scripts: scripts_basic include/config/MARKER | 421 | scripts: scripts_basic include/config/MARKER |
422 | $(Q)$(MAKE) $(build)=$(@) | 422 | $(Q)$(MAKE) $(build)=$(@) |
423 | 423 | ||
424 | scripts_basic: include/linux/autoconf.h | ||
425 | |||
426 | # Objects we will link into vmlinux / subdirs we need to visit | 424 | # Objects we will link into vmlinux / subdirs we need to visit |
427 | init-y := init/ | 425 | init-y := init/ |
428 | drivers-y := drivers/ sound/ | 426 | drivers-y := drivers/ sound/ |
@@ -436,25 +434,22 @@ ifeq ($(dot-config),1) | |||
436 | 434 | ||
437 | # Read in dependencies to all Kconfig* files, make sure to run | 435 | # Read in dependencies to all Kconfig* files, make sure to run |
438 | # oldconfig if changes are detected. | 436 | # oldconfig if changes are detected. |
439 | -include .kconfig.d | 437 | -include include/config/auto.conf.cmd |
440 | 438 | -include include/config/auto.conf | |
441 | include .config | ||
442 | 439 | ||
443 | # If .config needs to be updated, it will be done via the dependency | ||
444 | # that autoconf has on .config. | ||
445 | # To avoid any implicit rule to kick in, define an empty command | 440 | # To avoid any implicit rule to kick in, define an empty command |
446 | .config .kconfig.d: ; | 441 | .config include/config/auto.conf.cmd: ; |
447 | 442 | ||
448 | # If .config is newer than include/linux/autoconf.h, someone tinkered | 443 | # If .config is newer than include/config/auto.conf, someone tinkered |
449 | # with it and forgot to run make oldconfig. | 444 | # with it and forgot to run make oldconfig. |
450 | # If kconfig.d is missing then we are probarly in a cleaned tree so | 445 | # if auto.conf.cmd is missing then we are probarly in a cleaned tree so |
451 | # we execute the config step to be sure to catch updated Kconfig files | 446 | # we execute the config step to be sure to catch updated Kconfig files |
452 | include/linux/autoconf.h: .kconfig.d .config | 447 | include/config/auto.conf: .config include/config/auto.conf.cmd |
453 | $(Q)mkdir -p include/linux | ||
454 | $(Q)$(MAKE) -f $(srctree)/Makefile silentoldconfig | 448 | $(Q)$(MAKE) -f $(srctree)/Makefile silentoldconfig |
449 | |||
455 | else | 450 | else |
456 | # Dummy target needed, because used as prerequisite | 451 | # Dummy target needed, because used as prerequisite |
457 | include/linux/autoconf.h: ; | 452 | include/config/auto.conf: ; |
458 | endif | 453 | endif |
459 | 454 | ||
460 | # The all: target is the default when no target is given on the | 455 | # The all: target is the default when no target is given on the |
@@ -779,7 +774,7 @@ PHONY += prepare-all | |||
779 | prepare3: .kernelrelease | 774 | prepare3: .kernelrelease |
780 | ifneq ($(KBUILD_SRC),) | 775 | ifneq ($(KBUILD_SRC),) |
781 | @echo ' Using $(srctree) as source for kernel' | 776 | @echo ' Using $(srctree) as source for kernel' |
782 | $(Q)if [ -f $(srctree)/.config ]; then \ | 777 | $(Q)if [ -f $(srctree)/.config -o -d $(srctree)/include/config ]; then \ |
783 | echo " $(srctree) is not clean, please run 'make mrproper'";\ | 778 | echo " $(srctree) is not clean, please run 'make mrproper'";\ |
784 | echo " in the '$(srctree)' directory.";\ | 779 | echo " in the '$(srctree)' directory.";\ |
785 | /bin/false; \ | 780 | /bin/false; \ |
@@ -822,7 +817,7 @@ include/asm: | |||
822 | 817 | ||
823 | # Split autoconf.h into include/linux/config/* | 818 | # Split autoconf.h into include/linux/config/* |
824 | 819 | ||
825 | include/config/MARKER: scripts/basic/split-include include/linux/autoconf.h | 820 | include/config/MARKER: scripts/basic/split-include include/config/auto.conf |
826 | @echo ' SPLIT include/linux/autoconf.h -> include/config/*' | 821 | @echo ' SPLIT include/linux/autoconf.h -> include/config/*' |
827 | @scripts/basic/split-include include/linux/autoconf.h include/config | 822 | @scripts/basic/split-include include/linux/autoconf.h include/config |
828 | @touch $@ | 823 | @touch $@ |