Back out e8d8faa25955 (bug 1241111) for breaking platform.ini, a=bustage
authorPhil Ringnalda <philringnalda@gmail.com>
Sun, 31 Jan 2016 10:01:22 -0800
changeset 305406 0512df61134e23991be14b08307edd16c007a74e
parent 305405 b2a3dc4b161fdfac6db78cc5bbfb1f53a383b65a
child 305413 271c3cec24fe679423e849ca0c4d8f57235d497a
push id9214
push userraliiev@mozilla.com
push dateMon, 07 Mar 2016 14:25:21 +0000
treeherdermozilla-aurora@8849dd1a4a79 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbustage
bugs1241111
milestone47.0a1
backs oute8d8faa2595513aca6258f0d9e224f86c6ecd01e
Back out e8d8faa25955 (bug 1241111) for breaking platform.ini, a=bustage
build/Makefile.in
configure.in
toolkit/content/Makefile.in
toolkit/mozapps/installer/package-name.mk
toolkit/xre/Makefile.in
--- a/build/Makefile.in
+++ b/build/Makefile.in
@@ -11,33 +11,23 @@ APP_INI_DEPS = $(topsrcdir)/config/miles
 
 MOZ_APP_BUILDID := $(shell cat $(DEPTH)/config/buildid)
 APP_INI_DEPS += $(DEPTH)/config/buildid
 
 DEFINES += -DMOZ_APP_BUILDID=$(MOZ_APP_BUILDID)
 
 APP_INI_DEPS += $(DEPTH)/config/autoconf.mk
 
-ifdef MOZ_SOURCE_CHANGESET
-MOZ_SOURCE_STAMP := $(MOZ_SOURCE_CHANGESET)
-else
 MOZ_SOURCE_STAMP := $(firstword $(shell cd $(topsrcdir)/$(MOZ_BUILD_APP)/.. && hg parent --template='{node}\n' 2>/dev/null))
-endif
-
 ifdef MOZ_SOURCE_STAMP
 DEFINES += -DMOZ_SOURCE_STAMP='$(MOZ_SOURCE_STAMP)'
 endif
 
-
 ifdef MOZ_INCLUDE_SOURCE_INFO
-ifdef MOZ_SOURCE_REPO
-source_repo := $(MOZ_SOURCE_REPO)
-else
 source_repo ?= $(call getSourceRepo,$(topsrcdir)/$(MOZ_BUILD_APP)/..)
-endif
 ifneq (,$(source_repo))
   DEFINES += -DMOZ_SOURCE_REPO='$(source_repo)'
 endif
 endif
 
 endif
 
 # NOTE: Keep .gdbinit in the topsrcdir for people who run gdb from the topsrcdir.
--- a/configure.in
+++ b/configure.in
@@ -8708,28 +8708,23 @@ if test "$MOZILLA_OFFICIAL"; then
     AC_DEFINE(MOZILLA_OFFICIAL)
     # Build revisions should always be present in official builds
     MOZ_INCLUDE_SOURCE_INFO=1
 fi
 
 # On official builds, we need to know in Telemetry what revision this is built from.
 # This is e.g. needed to match incoming data to a specific revision of the Histograms.json
 # file.
-# External builds (specifically Ubuntu) may drop the hg repo information, so we allow to
-# explicitly set the repository and changeset information in.
-if test "$MOZILLA_OFFICIAL"; then
-    if test -z "$MOZ_SOURCE_REPO" && test -z "$MOZ_SOURCE_CHANGESET" && test -d ${_topsrcdir}/.hg; then
-        MOZ_SOURCE_CHANGESET=`cd $_topsrcdir && hg parent --template='{node}'`
-        MOZ_SOURCE_REPO=`cd $_topsrcdir && hg showconfig paths.default | sed -e 's|^ssh://|http://|' -e 's|/$||'`
-    fi
-    SOURCE_REV_URL=$MOZ_SOURCE_REPO/rev/$MOZ_SOURCE_CHANGESET
-fi
-
-AC_SUBST(MOZ_SOURCE_CHANGESET)
-AC_SUBST(MOZ_SOURCE_REPO)
+if test "$MOZILLA_OFFICIAL" && test -d ${_topsrcdir}/.hg; then
+  SOURCE_REV=`cd $_topsrcdir && hg parent --template='{node|short}'`
+  SOURCE_REPO=`cd $_topsrcdir && hg showconfig paths.default | sed -e 's|^ssh://|http://|' -e 's|/$||'`
+  SOURCE_REV_URL=$SOURCE_REPO/rev/$SOURCE_REV
+else
+  SOURCE_REV_URL=
+fi
 AC_SUBST(SOURCE_REV_URL)
 
 AC_SUBST(MOZ_INCLUDE_SOURCE_INFO)
 
 if test "$MOZ_TELEMETRY_REPORTING"; then
     AC_DEFINE(MOZ_TELEMETRY_REPORTING)
 
     # Enable Telemetry by default for nightly and aurora channels
--- a/toolkit/content/Makefile.in
+++ b/toolkit/content/Makefile.in
@@ -6,29 +6,21 @@
 USE_RCS_MK := 1
 include $(topsrcdir)/config/makefiles/makeutils.mk
 
 DEFINES += \
   -DCXXFLAGS='$(CXXFLAGS)' \
   -DCPPFLAGS='$(CPPFLAGS)' \
   $(NULL)
 
-ifdef MOZ_SOURCE_CHANGESET
-MOZ_SOURCE_STAMP = $(MOZ_SOURCE_CHANGESET)
-else
 MOZ_SOURCE_STAMP ?= $(shell hg -R $(topsrcdir) parent --template='{node}\n' 2>/dev/null)
-endif
 ifdef MOZ_SOURCE_STAMP
 DEFINES += -DSOURCE_CHANGESET='$(MOZ_SOURCE_STAMP)'
 endif
 
 ifdef MOZ_INCLUDE_SOURCE_INFO
-ifdef MOZ_SOURCE_REPO
-source_repo = $(MOZ_SOURCE_REPO)
-else
 source_repo ?= $(call getSourceRepo)
-endif
 ifneq (,$(filter http%,$(source_repo)))
   DEFINES += -DSOURCE_REPO='$(source_repo)'
 else ifneq (,$(strip $(source_repo)))
   DEFINES += -DSOURCE_GIT_COMMIT='$(source_repo)'
 endif
 endif
--- a/toolkit/mozapps/installer/package-name.mk
+++ b/toolkit/mozapps/installer/package-name.mk
@@ -151,31 +151,25 @@ else
 BUILDID = $(shell $(PYTHON) $(MOZILLA_DIR)/config/printconfigsetting.py $(DIST)/bin/platform.ini Build BuildID)
 endif
 
 ifndef INCLUDED_RCS_MK
   USE_RCS_MK := 1
   include $(MOZILLA_DIR)/config/makefiles/makeutils.mk
 endif
 
-ifdef MOZ_SOURCE_CHANGESET
-MOZ_SOURCE_STAMP = $(MOZ_SOURCE_CHANGESET)
-else
 MOZ_SOURCE_STAMP = $(firstword $(shell hg -R $(MOZILLA_DIR) parent --template="{node}\n" 2>/dev/null))
-endif
 
 ###########################################################################
 # bug: 746277 - preserve existing functionality.
 # MOZILLA_DIR="": cd $(SPACE); hg # succeeds if ~/.hg exists
 ###########################################################################
 ifdef MOZ_INCLUDE_SOURCE_INFO
-ifndef MOZ_SOURCE_REPO
 MOZ_SOURCE_REPO = $(call getSourceRepo,$(MOZILLA_DIR)$(NULL) $(NULL))
 endif
-endif
 
 MOZ_SOURCESTAMP_FILE = $(DIST)/$(PKG_PATH)/$(MOZ_INFO_BASENAME).txt
 MOZ_BUILDINFO_FILE = $(DIST)/$(PKG_PATH)/$(MOZ_INFO_BASENAME).json
 MOZ_MOZINFO_FILE = $(DIST)/$(PKG_PATH)/$(MOZ_INFO_BASENAME).mozinfo.json
 MOZ_TEST_PACKAGES_FILE = $(DIST)/$(PKG_PATH)/test_packages.json
 MOZ_TEST_PACKAGES_FILE_TC = $(DIST)/$(PKG_PATH)/test_packages_tc.json
 
 # JavaScript Shell
--- a/toolkit/xre/Makefile.in
+++ b/toolkit/xre/Makefile.in
@@ -14,31 +14,23 @@ include $(topsrcdir)/config/rules.mk
 
 # Should version be optional or required ?
 TOOLKIT_EM_VERSION=$(shell $(PYTHON) $(topsrcdir)/python/mozbuild/mozbuild/milestone.py --topsrcdir=$(topsrcdir))
 $(call warnIfEmpty,TOOLKIT_EM_VERSION)
 
 # Valid if null: {warn,error}IfEmpty
 DEFINES += -DTOOLKIT_EM_VERSION='"$(TOOLKIT_EM_VERSION)"'
 
-ifdef MOZ_SOURCE_CHANGESET
-MOZ_SOURCE_STAMP = $MOZ_SOURCE_CHANGESET
-else
 MOZ_SOURCE_STAMP ?= $(firstword $(shell hg -R $(topsrcdir) parent --template='{node}\n' 2>/dev/null))
-endif
 ifdef MOZ_SOURCE_STAMP
 
   INIARGS = --sourcestamp=$(MOZ_SOURCE_STAMP)
 
   ifdef MOZ_INCLUDE_SOURCE_INFO
-    ifdef MOZ_SOURCE_REPO
-    source_repo = $MOZ_SOURCE_REPO
-    else
     source_repo := $(call getSourceRepo)
-    endif
 
     # extra sanity check for old versions of hg, no showconfig support
     ifneq (,$(filter http%,$(source_repo)))
       INIARGS += --sourcerepo=$(source_repo)
     endif
   endif
 
 endif # MOZ_SOURCE_STAMP