make/Init.gmk
changeset 47313 eb28be8f935d
parent 47253 92fd0e04e0e1
child 47346 ea082b202a23
--- a/make/Init.gmk	Wed Oct 04 10:54:18 2017 -0700
+++ b/make/Init.gmk	Thu Oct 05 11:02:18 2017 +0200
@@ -137,15 +137,16 @@
 
     # The spec files depend on the autoconf source code. This check makes sure
     # the configuration is up to date after changes to configure.
-    CUSTOM_CONFIG_DIR ?= $(topdir)/closed/autoconf
-
-    $(SPECS): $(wildcard $(topdir)/common/autoconf/*) $(wildcard $(CUSTOM_CONFIG_DIR)/*)
+    $(SPECS): $(wildcard $(topdir)/make/autoconf/*) \
+            $(if $(CUSTOM_CONFIG_DIR), $(wildcard $(CUSTOM_CONFIG_DIR)/*))
         ifeq ($(CONF_CHECK), fail)
-	  @echo "Error: The configuration is not up to date for '$(lastword $(subst /, , $(dir $@)))'."
+	  @echo Error: The configuration is not up to date for \
+	      "'$(lastword $(subst /, , $(dir $@)))'."
 	  $(call PrintConfCheckFailed)
 	  @exit 2
         else ifeq ($(CONF_CHECK), auto)
-	  @echo "Note: The configuration is not up to date for '$(lastword $(subst /, , $(dir $@)))'."
+	  @echo Note: The configuration is not up to date for \
+	      "'$(lastword $(subst /, , $(dir $@)))'."
 	  @( cd $(topdir) && \
 	      $(MAKE) $(MFLAGS) $(MAKE_LOG_FLAGS) -r -R -f $(topdir)/make/Init.gmk \
 	      SPEC=$@ HAS_SPEC=true ACTUAL_TOPDIR=$(topdir) \
@@ -266,6 +267,7 @@
 	  $(ECHO) "Re-running configure using default settings"
         endif
 	( cd $(OUTPUTDIR) && PATH="$(ORIGINAL_PATH)" \
+	    CUSTOM_CONFIG_DIR="$(CUSTOM_CONFIG_DIR)" \
 	    $(BASH) $(CONFIGURE_CMD) $(CONFIGURE_COMMAND_LINE) )
 
   ##############################################################################