changeset 636:339e4df096a2

8007093: build-infra: Make should fail if spec is older than configure files Reviewed-by: tbell
author erikj
date Mon, 04 Feb 2013 10:53:38 +0100
parents 7e584be2ee58
children dea045cc48ca
files common/makefiles/Main.gmk
diffstat 1 files changed, 8 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/common/makefiles/Main.gmk	Fri Feb 01 11:22:41 2013 +0100
+++ b/common/makefiles/Main.gmk	Mon Feb 04 10:53:38 2013 +0100
@@ -75,7 +75,14 @@
   all: overlay-images
 endif
 
-start-make:
+# Setup a rule for SPEC file that fails if executed. This check makes sure the configuration
+# is up to date after changes to configure
+$(SPEC): $(wildcard $(SRC_ROOT)/common/autoconf/*)
+	@$(ECHO) ERROR: $(SPEC) is not up to date
+	@$(ECHO) Please rerun configure!
+	@if test "x$(IGNORE_OLD_CONFIG)" != "xtrue"; then exit 1; fi
+
+start-make: $(SPEC)
 	@$(call AtMakeStart)
 
 langtools: langtools-only