diff -urN mozilla.orig/browser/confvars.sh mozilla/browser/confvars.sh --- mozilla.orig/browser/confvars.sh 2010-02-04 15:47:13.000000000 +0100 +++ mozilla/browser/confvars.sh 2010-02-04 15:48:50.000000000 +0100 @@ -36,8 +36,8 @@ # # ***** END LICENSE BLOCK ***** -MOZ_APP_BASENAME=Firefox -MOZ_APP_VENDOR=Mozilla +MOZ_APP_BASENAME=Iceweasel +MOZ_APP_VENDOR= MOZ_UPDATER=1 MOZ_PHOENIX=1 From: Mike Hommey Date: Thu, 1 Apr 2010 15:34:59 +0200 Subject: Determine which phishing shavar to use depending on MOZ_OFFICIAL_BRANDING --- browser/app/Makefile.in | 4 ++++ browser/app/profile/firefox.js | 4 ++++ browser/components/safebrowsing/Makefile.in | 4 ++++ browser/components/safebrowsing/SafeBrowsing.jsm | 4 ++++ 4 files changed, 16 insertions(+) diff --git a/browser/app/Makefile.in b/browser/app/Makefile.in index 5f891ca..e337ef4 100644 --- a/browser/app/Makefile.in +++ b/browser/app/Makefile.in @@ -132,6 +132,10 @@ endif endif #} LIBXUL_SDK +ifdef MOZ_OFFICIAL_BRANDING +DEFINES += -DMOZ_OFFICIAL_BRANDING +endif + ifeq ($(MOZ_WIDGET_TOOLKIT),gtk2) libs:: $(INSTALL) $(IFLAGS1) $(DIST)/branding/mozicon128.png $(DIST)/bin/icons diff --git a/browser/app/profile/firefox.js b/browser/app/profile/firefox.js index d02a1b1..2b0b9fd 100644 --- a/browser/app/profile/firefox.js +++ b/browser/app/profile/firefox.js @@ -742,7 +742,11 @@ pref("urlclassifier.gethashnoise", 4); pref("urlclassifier.randomizeclient", false); // The list of tables that use the gethash request to confirm partial results. +#ifdef MOZ_OFFICIAL_BRANDING pref("urlclassifier.gethashtables", "goog-phish-shavar,goog-malware-shavar"); +#else +pref("urlclassifier.gethashtables", "googpub-phish-shavar,goog-malware-shavar"); +#endif // If an urlclassifier table has not been updated in this number of seconds, // a gethash request will be forced to check that the result is still in diff --git a/browser/components/safebrowsing/Makefile.in b/browser/components/safebrowsing/Makefile.in index 8585a34..3aceb9f 100644 --- a/browser/components/safebrowsing/Makefile.in +++ b/browser/components/safebrowsing/Makefile.in @@ -24,4 +24,8 @@ EXTRA_PP_JS_MODULES = \ SafeBrowsing.jsm \ $(NULL) +ifdef MOZ_OFFICIAL_BRANDING +DEFINES += -DMOZ_OFFICIAL_BRANDING +endif + include $(topsrcdir)/config/rules.mk diff --git a/browser/components/safebrowsing/SafeBrowsing.jsm b/browser/components/safebrowsing/SafeBrowsing.jsm index 313ac48..ba9b6f4 100644 --- a/browser/components/safebrowsing/SafeBrowsing.jsm +++ b/browser/components/safebrowsing/SafeBrowsing.jsm @@ -10,7 +10,11 @@ const Cu = Components.utils; Cu.import("resource://gre/modules/Services.jsm"); +#ifdef MOZ_OFFICIAL_BRANDING const phishingList = "goog-phish-shavar"; +#else +const phishingList = "googpub-phish-shavar"; +#endif const malwareList = "goog-malware-shavar"; var debug = false; From: Mike Hommey Date: Sat, 19 Feb 2011 11:04:53 +0100 Subject: Modify search plugins depending on MOZ_APP_NAME --- browser/locales/Makefile.in | 1 + browser/locales/en-US/searchplugins/answers.xml | 2 +- browser/locales/en-US/searchplugins/google.xml | 5 +++++ 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/browser/locales/Makefile.in b/browser/locales/Makefile.in index 340bb5f..dd0761f 100644 --- a/browser/locales/Makefile.in +++ b/browser/locales/Makefile.in @@ -167,6 +167,7 @@ libs:: $(addsuffix .xml,$(SEARCH_PLUGINS)) for SEARCH_PLUGIN in $^; do\ SEARCH_PLUGIN_BASE=`basename $$SEARCH_PLUGIN`;\ $(PYTHON) $(topsrcdir)/config/Preprocessor.py $(DEFINES) $(ACDEFINES) \ + -DMOZ_APP_NAME=$(MOZ_APP_NAME) \ $$SEARCH_PLUGIN > $(FINAL_TARGET)/searchplugins/$$SEARCH_PLUGIN_BASE; \ done diff --git a/browser/locales/en-US/searchplugins/answers.xml b/browser/locales/en-US/searchplugins/answers.xml index ea32303..2da83aa 100644 --- a/browser/locales/en-US/searchplugins/answers.xml +++ b/browser/locales/en-US/searchplugins/answers.xml @@ -8,6 +8,6 @@ +#expand template="http://www.answers.com/main/startswith?output=json&client=__MOZ_APP_NAME__&s={searchTerms}"/> http://www.answers.com/ diff --git a/browser/locales/en-US/searchplugins/google.xml b/browser/locales/en-US/searchplugins/google.xml index 1ccd459..b87c867 100644 --- a/browser/locales/en-US/searchplugins/google.xml +++ b/browser/locales/en-US/searchplugins/google.xml @@ -1,7 +1,9 @@ - License, v. 2.0. If a copy of the MPL was not distributed with this - file, You can obtain one at http://mozilla.org/MPL/2.0/. --> +#filter substitution #define GOOGLE_PARAMS +#if MOZ_APP_NAME==firefox #if MOZ_UPDATE_CHANNEL == beta #define GOOGLE_CLIENT_PARAM #elif MOZ_UPDATE_CHANNEL == aurora @@ -8,6 +10,9 @@ #else #define GOOGLE_CLIENT_PARAM #endif +#else +#define GOOGLE_CLIENT_PARAM +#endif Google Google Search From: Mike Hommey Date: Sat, 19 Feb 2011 11:02:30 +0100 Subject: Use MOZ_APP_DISPLAYNAME to fill appstrings.properties --- browser/locales/Makefile.in | 2 ++ .../en-US/chrome/overrides/appstrings.properties | 20 ++++++++++---------- 2 files changed, 12 insertions(+), 10 deletions(-) diff --git a/browser/locales/Makefile.in b/browser/locales/Makefile.in index c5a09d2..340bb5f 100644 --- a/browser/locales/Makefile.in +++ b/browser/locales/Makefile.in @@ -69,6 +69,8 @@ SUBMAKEFILES += \ $(DEPTH)/$(MOZ_BRANDING_DIRECTORY)/locales/Makefile \ $(NULL) +DEFINES += -DMOZ_APP_DISPLAYNAME=$(MOZ_APP_DISPLAYNAME) + # This makefile uses variable overrides from the libs-% target to # build non-default locales to non-default dist/ locations. Be aware! diff --git a/browser/locales/en-US/chrome/overrides/appstrings.properties b/browser/locales/en-US/chrome/overrides/appstrings.properties index 87e9538..ac979f9 100644 --- a/browser/locales/en-US/chrome/overrides/appstrings.properties +++ b/browser/locales/en-US/chrome/overrides/appstrings.properties @@ -35,24 +35,24 @@ # ***** END LICENSE BLOCK ***** malformedURI=The URL is not valid and cannot be loaded. -fileNotFound=Firefox can't find the file at %S. -dnsNotFound=Firefox can't find the server at %S. -protocolNotFound=Firefox doesn't know how to open this address, because the protocol (%S) isn't associated with any program. -connectionFailure=Firefox can't establish a connection to the server at %S. +#expand fileNotFound=__MOZ_APP_DISPLAYNAME__ can't find the file at %S. +#expand dnsNotFound=__MOZ_APP_DISPLAYNAME__ can't find the server at %S. +#expand protocolNotFound=__MOZ_APP_DISPLAYNAME__ doesn't know how to open this address, because the protocol (%S) isn't associated with any program. +#expand connectionFailure=__MOZ_APP_DISPLAYNAME__ can't establish a connection to the server at %S. netInterrupt=The connection to %S was interrupted while the page was loading. netTimeout=The server at %S is taking too long to respond. -redirectLoop=Firefox has detected that the server is redirecting the request for this address in a way that will never complete. +#expand redirectLoop=__MOZ_APP_DISPLAYNAME__ has detected that the server is redirecting the request for this address in a way that will never complete. ## LOCALIZATION NOTE (confirmRepostPrompt): In this item, don't translate "%S" confirmRepostPrompt=To display this page, %S must send information that will repeat any action (such as a search or order confirmation) that was performed earlier. resendButton.label=Resend -unknownSocketType=Firefox doesn't know how to communicate with the server. +#expand unknownSocketType=__MOZ_APP_DISPLAYNAME__ doesn't know how to communicate with the server. netReset=The connection to the server was reset while the page was loading. notCached=This document is no longer available. -netOffline=Firefox is currently in offline mode and can't browse the Web. +#expand netOffline=__MOZ_APP_DISPLAYNAME__ is currently in offline mode and can't browse the Web. isprinting=The document cannot change while Printing or in Print Preview. -deniedPortAccess=This address uses a network port which is normally used for purposes other than Web browsing. Firefox has canceled the request for your protection. -proxyResolveFailure=Firefox is configured to use a proxy server that can't be found. -proxyConnectFailure=Firefox is configured to use a proxy server that is refusing connections. +#expand deniedPortAccess=This address uses a network port which is normally used for purposes other than Web browsing. __MOZ_APP_DISPLAYNAME__ has canceled the request for your protection. +#expand proxyResolveFailure=__MOZ_APP_DISPLAYNAME__ is configured to use a proxy server that can't be found. +#expand proxyConnectFailure=__MOZ_APP_DISPLAYNAME__ is configured to use a proxy server that is refusing connections. contentEncodingError=The page you are trying to view cannot be shown because it uses an invalid or unsupported form of compression. unsafeContentType=The page you are trying to view cannot be shown because it is contained in a file type that may not be safe to open. Please contact the website owners to inform them of this problem. externalProtocolTitle=External Protocol Request