kconfig: enforce remaking config.mk after oldconfig changes .config

Without any command under the .config target, config.mk will not be remade in
the same execution of make after oldconfig changes .config. This can result to
inconsistency between .config and the built image right after .config is
changed.

Tracked-On: #1588
Signed-off-by: Junjie Mao <junjie.mao@intel.com>
Reviewed-by: Anthony Xu <anthony.xu@intel.com>
This commit is contained in:
Junjie Mao 2018-10-19 21:52:15 +08:00 committed by lijinxia
parent c7907a823c
commit 8bde372c32
1 changed files with 4 additions and 0 deletions

View File

@ -38,7 +38,11 @@ $(eval $(call check_dep_py3lib,kconfiglib,KCONFIG_DEPS))
# This target invoke silentoldconfig to generate or update a .config. Useful as
# a prerequisite of other targets depending on .config.
#
# A dummy command is necessary to trigger the remaking of config.mk right after
# oldconfig changes HV_CONFIG in the same execution of make.
$(HV_OBJDIR)/$(HV_CONFIG): oldconfig
@true
# Note: This target must not depend on a phony target (e.g. oldconfig) because
# it'll trigger endless re-execution of make.