Bug 1054727 - Port |Bug 1042432 - Change how UPLOAD_EXTRA_FILES is passed down from mozconfig.cache to the build system| and |Bug 991976 - Only fail creating .mozconfig.mk once| to comm-central r=jcranmer,a=Standard8
authorIan Neal <iann_cvs@blueyonder.co.uk>
Tue, 19 Aug 2014 17:48:00 +0100
changeset 20595 48c029bc97bfcc9905c9bf51c32fc94c531b7b10
parent 20594 3655132711fc56b0de7f1ac78b71346060b399cf
child 20596 ea6a0f129c13189ab95ba94cd225d961dafa7775
push id1209
push usermbanner@mozilla.com
push dateTue, 02 Sep 2014 16:59:36 +0000
treeherdercomm-beta@842e0fd167ee [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjcranmer, Standard8
bugs1054727, 1042432, 991976
Bug 1054727 - Port |Bug 1042432 - Change how UPLOAD_EXTRA_FILES is passed down from mozconfig.cache to the build system| and |Bug 991976 - Only fail creating .mozconfig.mk once| to comm-central r=jcranmer,a=Standard8
build/mozconfig.cache
client.mk
--- a/build/mozconfig.cache
+++ b/build/mozconfig.cache
@@ -55,17 +55,17 @@ else
     case "$master" in
     *use1.mozilla.com*|*usw2.mozilla.com*)
         mk_add_options "export SCCACHE_NAMESERVER=169.254.169.253"
         ;;
     esac
     ac_add_options "--with-compiler-wrapper=python2.7 $topsrcdir/sccache/sccache.py"
     mk_add_options MOZ_PREFLIGHT_ALL+=build/sccache.mk
     mk_add_options MOZ_POSTFLIGHT_ALL+=build/sccache.mk
-    UPLOAD_EXTRA_FILES="$UPLOAD_EXTRA_FILES sccache.log.gz"
+    mk_add_options "export UPLOAD_EXTRA_FILES+=sccache.log.gz"
     case "$platform" in
     win*)
         # sccache supports a special flag to create depfiles.
         export _DEPEND_CFLAGS='-deps$(MDDEPDIR)/$(@F).pp'
         # Windows builds have a default wrapper that needs to be overridden
         mk_add_options "export CC_WRAPPER="
         mk_add_options "export CXX_WRAPPER="
         # For now, sccache doesn't support separate PDBs so force debug info to be
--- a/client.mk
+++ b/client.mk
@@ -191,19 +191,25 @@ ifdef WANT_MOZCONFIG_MK
 # For now, only output "export" lines from mozconfig2client-mk output.
 MOZCONFIG_MK_LINES := $(filter export||%,$(MOZCONFIG_OUT_LINES))
 $(OBJDIR)/.mozconfig.mk: $(FOUND_MOZCONFIG) $(call mkdir_deps,$(OBJDIR))
 	$(if $(MOZCONFIG_MK_LINES),( $(foreach line,$(MOZCONFIG_MK_LINES), echo "$(subst ||, ,$(line))";) )) > $@
 
 # Include that makefile so that it is created. This should not actually change
 # the environment since MOZCONFIG_CONTENT, which MOZCONFIG_OUT_LINES derives
 # from, has already been eval'ed.
--include $(OBJDIR)/.mozconfig.mk
+include $(OBJDIR)/.mozconfig.mk
 endif
 
+# UPLOAD_EXTRA_FILES is appended to and exported from mozconfig, which makes
+# submakes as well as configure add even more to that, so just unexport it
+# for submakes to pick it from .mozconfig.mk and for configure to pick it
+# from mach environment.
+unexport UPLOAD_EXTRA_FILES
+
 # These targets are candidates for auto-running client.py
 
 ifeq (01,$(MAKELEVEL)$(if $(ALWAYS_RUN_CLIENT_PY),1,))
 
 build profiledbuild configure:: run_client_py
 	$(MAKE) -f $(TOPSRCDIR)/client.mk $@
 else