From: Angus Gratton Date: Sun, 8 Jan 2017 23:09:05 +0000 (+1100) Subject: build system: Fix sdkconfig.defaults file preventing menuconfig changes X-Git-Tag: v2.0-rc1~67^2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=6421479dabaea425ce08a705200533f02600b050;p=esp-idf build system: Fix sdkconfig.defaults file preventing menuconfig changes 'make defconfig' now behaves similarly whether sdkconfig.defaults is present or not, and 'make menuconfig' doesn't trigger a defconfig. --- diff --git a/make/project_config.mk b/make/project_config.mk index b8e40f4357..011aa1ff0e 100644 --- a/make/project_config.mk +++ b/make/project_config.mk @@ -25,7 +25,7 @@ KCONFIG_TOOL_ENV=KCONFIG_AUTOHEADER=$(abspath $(BUILD_DIR_BASE)/include/sdkconfi COMPONENT_KCONFIGS="$(COMPONENT_KCONFIGS)" KCONFIG_CONFIG=$(SDKCONFIG) \ COMPONENT_KCONFIGS_PROJBUILD="$(COMPONENT_KCONFIGS_PROJBUILD)" -menuconfig: $(KCONFIG_TOOL_DIR)/mconf $(IDF_PATH)/Kconfig | defconfig +menuconfig: $(KCONFIG_TOOL_DIR)/mconf $(IDF_PATH)/Kconfig $(call prereq_if_explicit,defconfig) $(summary) MENUCONFIG $(KCONFIG_TOOL_ENV) $(KCONFIG_TOOL_DIR)/mconf $(IDF_PATH)/Kconfig @@ -39,14 +39,11 @@ $(SDKCONFIG): defconfig endif endif -$(wildcard $(PROJECT_PATH)/sdkconfig.defaults): | menuconfig defconfig - cp $< $@ - # defconfig creates a default config, based on SDKCONFIG_DEFAULTS if present defconfig: $(KCONFIG_TOOL_DIR)/mconf $(IDF_PATH)/Kconfig $(BUILD_DIR_BASE) $(summary) DEFCONFIG ifneq ("$(wildcard $(SDKCONFIG_DEFAULTS))","") - cp $(SDKCONFIG_DEFAULTS) $(SDKCONFIG) + cat $(SDKCONFIG_DEFAULTS) >> $(SDKCONFIG) # append defaults to sdkconfig, will override existing values endif mkdir -p $(BUILD_DIR_BASE)/include/config $(KCONFIG_TOOL_ENV) $(KCONFIG_TOOL_DIR)/conf --olddefconfig $(IDF_PATH)/Kconfig