Bug 717372 - The clobber information should live in the tree; r=khuey
authorBenoit Girard <b56girard@gmail.com>
Tue, 13 Mar 2012 13:00:24 -0400
changeset 114590 8cab8f873f847080d7b8f349486e399d1e6b3b60
parent 114589 5e32ac4dfea22adcc36af0908b80d489f0403285
child 114591 72c8d4dc10328ce397cc7d5c10ef18c5eb0538d4
push id23926
push userryanvm@gmail.com
push dateSat, 01 Dec 2012 15:27:30 +0000
treeherdermozilla-central@ecdf0e332f17 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerskhuey
bugs717372
milestone20.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 717372 - The clobber information should live in the tree; r=khuey
CLOBBER
client.mk
configure.in
new file mode 100644
--- /dev/null
+++ b/CLOBBER
@@ -0,0 +1,18 @@
+# To Trigger a clobber replace ALL of the textual description below,
+# giving a bug number and a one line description of why a clobber is
+# required. Modifying this file will make configure check that a
+# clobber has been performed before the build can continue.
+#
+# MERGE NOTE: When merging two branches that require a CLOBBER, you should
+#             merge both CLOBBER descriptions, to ensure that users on
+#             both branches correctly see the clobber warning.
+#
+#                  O   <-- Users coming from both parents need to Clobber
+#               /     \
+#          O               O
+#          |               |
+#          O <-- Clobber   O  <-- Clobber
+#
+# Note: The description below will be part of the error message shown to users.
+#
+Bug 717372 - The clobber information should live in the tree
--- a/client.mk
+++ b/client.mk
@@ -274,16 +274,17 @@ EXTRA_CONFIG_DEPS := \
 	@$(PYTHON) $(TOPSRCDIR)/js/src/config/check-sync-dirs.py $(TOPSRCDIR)/js/src/build $(TOPSRCDIR)/build
 	@echo Generating $@ using autoconf
 	cd $(@D); $(AUTOCONF)
 
 CONFIG_STATUS_DEPS := \
   $(wildcard $(TOPSRCDIR)/*/confvars.sh) \
   $(CONFIGURES) \
   $(TOPSRCDIR)/allmakefiles.sh \
+  $(TOPSRCDIR)/CLOBBER \
   $(TOPSRCDIR)/nsprpub/configure \
   $(TOPSRCDIR)/config/milestone.txt \
   $(TOPSRCDIR)/js/src/config/milestone.txt \
   $(TOPSRCDIR)/browser/config/version.txt \
   $(TOPSRCDIR)/build/virtualenv/packages.txt \
   $(TOPSRCDIR)/build/virtualenv/populate_virtualenv.py \
   $(NULL)
 
--- a/configure.in
+++ b/configure.in
@@ -118,16 +118,32 @@ then
 	***
 	EOF
     exit 1
     break
   fi
 fi
 MOZ_BUILD_ROOT=`pwd`
 
+dnl Do not allow building if a clobber is required
+dnl ==============================================================
+dnl TODO Make this better, ideally this would clobber automaticially
+if test -e $_objdir/CLOBBER; then
+  if test $_topsrcdir/CLOBBER -nt $_objdir/CLOBBER; then
+    echo "	***"
+    echo "	*	CLOBBER has been modified indicating a clobber is required:"
+    cat $_topsrcdir/CLOBBER | sed '/^#/d' | sed 's/^/	*	/'
+    echo "	***"
+    exit 1
+    break;
+  fi
+else
+  touch $_objdir/CLOBBER
+fi
+
 MOZ_PATH_PROGS(PYTHON, $PYTHON python2.7 python2.6 python2.5 python)
 if test -z "$PYTHON"; then
     AC_MSG_ERROR([python was not found in \$PATH])
 fi
 
 AC_MSG_RESULT([Creating Python environment])
 dnl This verifies our Python version is sane and ensures the Python
 dnl virtualenv is present and up to date. It sanitizes the environment