Bug 517086: Set Fennec user agent [r=gavin.sharp]
authorMark Finkle <mark.finkle@gmail.com>
Mon, 26 Oct 2009 12:11:20 -0400
changeset 65718 cd0b8621f383d3679e092a5f7efd810be855c9a5
parent 65717 0eae5642de9cae1bfa7baefb4cd956aa8ca11da3
child 65719 743aee66edc0e9891efa5f19a4d1e466dc8f7881
push id1
push userroot
push dateTue, 26 Apr 2011 22:38:44 +0000
treeherdermozilla-beta@bfdb6e623a36 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersgavin
bugs517086
Bug 517086: Set Fennec user agent [r=gavin.sharp]
mobile/app/Makefile.in
mobile/app/mobile.js
mobile/branding/nightly/configure.sh
mobile/branding/official/configure.sh
--- a/mobile/app/Makefile.in
+++ b/mobile/app/Makefile.in
@@ -49,17 +49,25 @@ include $(topsrcdir)/config/rules.mk
 
 GRE_MILESTONE = $(shell $(PYTHON) $(topsrcdir)/config/printconfigsetting.py $(LIBXUL_DIST)/bin/platform.ini Build Milestone)
 GRE_BUILDID = $(shell $(PYTHON) $(topsrcdir)/config/printconfigsetting.py $(LIBXUL_DIST)/bin/platform.ini Build BuildID)
 APP_BUILDID = $(shell $(PYTHON) $(topsrcdir)/toolkit/xre/make-platformini.py --print-buildid)
 APP_UA_NAME = $(shell echo $(MOZ_APP_DISPLAYNAME) | sed -e's/[^A-Za-z]//g')
 APP_ICON = mobile
 APP_SPLASH = splash
 
-DEFINES += -DGRE_MILESTONE=$(GRE_MILESTONE) -DGRE_BUILDID=$(GRE_BUILDID) -DAPP_BUILDID=$(APP_BUILDID) -DAPP_NAME=$(MOZ_APP_DISPLAYNAME) -DAPP_VERSION=$(MOZ_APP_VERSION) -DAPP_UA_NAME=$(APP_UA_NAME)
+DEFINES += -DGRE_MILESTONE=$(GRE_MILESTONE) \
+           -DGRE_BUILDID=$(GRE_BUILDID) \
+           -DAPP_BUILDID=$(APP_BUILDID) \
+           -DAPP_NAME=$(MOZ_APP_DISPLAYNAME) \
+           -DAPP_VERSION=$(MOZ_APP_VERSION) \
+           -DAPP_UA_NAME=$(APP_UA_NAME) \
+           -DAPP_UA_NAME_EXTRA=$(MOZ_APP_UA_EXTRA) \
+           -DAPP_VERSION_EXTRA=$(FIREFOX_VERSION) \
+           $(NULL)
 
 SOURCE_STAMP := $(shell cd $(srcdir)/.. && hg identify 2>/dev/null | cut -f1 -d' ')
 ifdef SOURCE_STAMP
 DEFINES += -DMOZ_SOURCE_STAMP="$(SOURCE_STAMP)"
 endif
 
 # strip a trailing slash from the repo URL because it's not always present,
 # and we want to construct a working URL in buildconfig.html
--- a/mobile/app/mobile.js
+++ b/mobile/app/mobile.js
@@ -32,17 +32,17 @@
  * the provisions above, a recipient may use your version of this file under
  * the terms of any one of the MPL, the GPL or the LGPL.
  *
  * ***** END LICENSE BLOCK ***** */
 
 #filter substitution
 
 pref("toolkit.defaultChromeURI", "chrome://browser/content/browser.xul");
-pref("general.useragent.extra.mobile", "@APP_UA_NAME@/@APP_VERSION@");
+pref("general.useragent.extra.mobile", "@APP_UA_NAME_EXTRA@/@APP_VERSION_EXTRA@ @APP_UA_NAME@/@APP_VERSION@");
 pref("browser.chromeURL", "chrome://browser/content/");
 
 pref("browser.startup.homepage", "about:firstrun");
 
 #if MOZ_PLATFORM_HILDON
 pref("browser.ui.cursor", false);
 #elifdef WINCE
 pref("browser.ui.cursor", false);
--- a/mobile/branding/nightly/configure.sh
+++ b/mobile/branding/nightly/configure.sh
@@ -1,1 +1,2 @@
 MOZ_APP_DISPLAYNAME=Fennec
+MOZ_APP_UA_EXTRA=Namoroka
--- a/mobile/branding/official/configure.sh
+++ b/mobile/branding/official/configure.sh
@@ -1,1 +1,2 @@
 MOZ_APP_DISPLAYNAME=Fennec
+MOZ_APP_UA_EXTRA=Firefox