bug 494498 - comm-central apps should supply mercurial changeset in application.ini, r=dmose
authorRobert Kaiser <kairo@kairo.at>
Sat, 23 May 2009 01:12:27 +0200
changeset 2686 1a25ea0c83587a3cc9e9f5d113f33b8edd14ab9e
parent 2685 630f852d04bcebf007c8cf1ca515852671cfdf4a
child 2687 f93a4c73151982e4fc954727ea0f3aceca6c456b
push idunknown
push userunknown
push dateunknown
reviewersdmose
bugs494498
bug 494498 - comm-central apps should supply mercurial changeset in application.ini, r=dmose
calendar/sunbird/app/Makefile.in
calendar/sunbird/app/application.ini
mail/app/Makefile.in
mail/app/application.ini
suite/app/Makefile.in
suite/app/application.ini
--- a/calendar/sunbird/app/Makefile.in
+++ b/calendar/sunbird/app/Makefile.in
@@ -63,16 +63,26 @@ APP_UA_NAME = $(shell echo $(MOZ_APP_DIS
 DEFINES += -DAPP_UA_NAME="$(APP_UA_NAME)"
 
 DIST_FILES = application.ini
 
 GRE_MILESTONE = $(shell $(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py $(LIBXUL_DIST)/bin/platform.ini Build Milestone)
 GRE_BUILDID = $(shell $(PYTHON) $(MOZILLA_SRCDIR)/config/printconfigsetting.py $(LIBXUL_DIST)/bin/platform.ini Build BuildID)
  
 DEFINES += -DGRE_MILESTONE=$(GRE_MILESTONE) -DGRE_BUILDID=$(GRE_BUILDID)
+
+SOURCE_STAMP := $(shell cd $(topsrcdir) ; hg identify -i 2>/dev/null | cut -f1 -d' ')
+ifdef SOURCE_STAMP
+DEFINES += -DMOZ_SOURCE_STAMP="$(SOURCE_STAMP)"
+endif
+
+SOURCE_REPO := $(shell hg -R $(topsrcdir) showconfig paths.default 2>/dev/null | sed s/^ssh:/http:/)
+ifdef SOURCE_REPO
+DEFINES += -DMOZ_SOURCE_REPO="$(SOURCE_REPO)"
+endif
  
 ifndef LIBXUL_SDK
 # Build a binary bootstrapping with XRE_main
 
 MOZILLA_INTERNAL_API = 1
 
 ifeq ($(USE_SHORT_LIBNAME), 1)
 PROGRAM = sunbird$(BIN_SUFFIX)
--- a/calendar/sunbird/app/application.ini
+++ b/calendar/sunbird/app/application.ini
@@ -37,16 +37,22 @@
 ; ***** END LICENSE BLOCK *****
 
 #filter substitution
 [App]
 Vendor=Mozilla
 Name=Sunbird
 Version=@APP_VERSION@
 BuildID=@GRE_BUILDID@
+#ifdef MOZ_SOURCE_REPO
+SourceRepository=@MOZ_SOURCE_REPO@
+#endif
+#ifdef MOZ_SOURCE_STAMP
+SourceStamp=@MOZ_SOURCE_STAMP@
+#endif
 Copyright=Copyright (c) 1998 - 2009 mozilla.org
 ID={718e30fb-e89b-41dd-9da7-e25a45638b28}
 
 [Gecko]
 MinVersion=@GRE_MILESTONE@
 MaxVersion=@GRE_MILESTONE@
 
 [XRE]
--- a/mail/app/Makefile.in
+++ b/mail/app/Makefile.in
@@ -55,16 +55,26 @@ MAIL_APP_LICENSE_FILE = $(srcdir)/app-li
 DEFINES += \
   -DTHUNDERBIRD_ICO=\"$(DIST)/branding/thunderbird.ico\" \
   -DAB_CD=$(AB_CD) \
   -DGRE_MILESTONE=$(GRE_MILESTONE) \
   -DGRE_BUILDID=$(GRE_BUILDID) \
   -DAPP_EULA_BLOCK=$(MAIL_APP_LICENSE_FILE) \
    $(NULL)
 
+SOURCE_STAMP := $(shell cd $(topsrcdir) ; hg identify -i 2>/dev/null | cut -f1 -d' ')
+ifdef SOURCE_STAMP
+DEFINES += -DMOZ_SOURCE_STAMP="$(SOURCE_STAMP)"
+endif
+
+SOURCE_REPO := $(shell hg -R $(topsrcdir) showconfig paths.default 2>/dev/null | sed s/^ssh:/http:/)
+ifdef SOURCE_REPO
+DEFINES += -DMOZ_SOURCE_REPO="$(SOURCE_REPO)"
+endif
+
 ifneq (,$(BUILD_OFFICIAL)$(MOZILLA_OFFICIAL))
 DEFINES += -DOFFICIAL_BUILD=1
 endif
 
 DIRS		= profile
 
 GARBAGE += \
 	$(MAIL_LICENSE_HTML_FILE) \
--- a/mail/app/application.ini
+++ b/mail/app/application.ini
@@ -35,16 +35,22 @@
 ;
 ; ***** END LICENSE BLOCK *****
 
 #filter substitution
 [App]
 Name=Thunderbird
 Version=@APP_VERSION@
 BuildID=@GRE_BUILDID@
+#ifdef MOZ_SOURCE_REPO
+SourceRepository=@MOZ_SOURCE_REPO@
+#endif
+#ifdef MOZ_SOURCE_STAMP
+SourceStamp=@MOZ_SOURCE_STAMP@
+#endif
 Copyright=Copyright (c) 1998-2009 mozilla.org
 ID={3550f703-e582-4d05-9a08-453d09bdfdc6}
 
 [Gecko]
 MinVersion=@GRE_MILESTONE@
 MaxVersion=@GRE_MILESTONE@
 
 [XRE]
--- a/suite/app/Makefile.in
+++ b/suite/app/Makefile.in
@@ -49,16 +49,26 @@ GRE_BUILDID = $(shell $(PYTHON) $(MOZILL
 
 DEFINES += \
 	-DAB_CD=$(AB_CD) \
 	-DAPP_VERSION="$(MOZ_APP_VERSION)" \
 	-DGRE_MILESTONE=$(GRE_MILESTONE) \
 	-DGRE_BUILDID=$(GRE_BUILDID) \
 	$(NULL)
 
+SOURCE_STAMP := $(shell cd $(topsrcdir) ; hg identify -i 2>/dev/null | cut -f1 -d' ')
+ifdef SOURCE_STAMP
+DEFINES += -DMOZ_SOURCE_STAMP="$(SOURCE_STAMP)"
+endif
+
+SOURCE_REPO := $(shell hg -R $(topsrcdir) showconfig paths.default 2>/dev/null | sed s/^ssh:/http:/)
+ifdef SOURCE_REPO
+DEFINES += -DMOZ_SOURCE_REPO="$(SOURCE_REPO)"
+endif
+
 ifeq ($(USE_SHORT_LIBNAME), 1)
 PROGRAM = $(MOZ_APP_NAME)$(BIN_SUFFIX)
 else
 PROGRAM = $(MOZ_APP_NAME)-bin$(BIN_SUFFIX)
 endif
 
 REQUIRES = \
 	xpcom \
--- a/suite/app/application.ini
+++ b/suite/app/application.ini
@@ -36,16 +36,22 @@
 ; ***** END LICENSE BLOCK *****
 
 #filter substitution
 [App]
 Vendor=Mozilla
 Name=SeaMonkey
 Version=@APP_VERSION@
 BuildID=@GRE_BUILDID@
+#ifdef MOZ_SOURCE_REPO
+SourceRepository=@MOZ_SOURCE_REPO@
+#endif
+#ifdef MOZ_SOURCE_STAMP
+SourceStamp=@MOZ_SOURCE_STAMP@
+#endif
 Copyright=Copyright (c) 1998-2009 mozilla.org
 ID={92650c4d-4b8e-4d2a-b7eb-24ecf4f6b63a}
 
 [Gecko]
 MinVersion=@GRE_MILESTONE@
 MaxVersion=@GRE_MILESTONE@
 
 [XRE]