[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[tor-commits] [torbrowser/master] LIN: update Makefiles and config files with FF17+torbutton changes
commit e20e6326c240a96b83fbea922df70b6e35c82490
Author: Erinn Clark <erinn@xxxxxxxxxxxxxx>
Date: Tue Feb 12 18:31:22 2013 +0100
LIN: update Makefiles and config files with FF17+torbutton changes
---
build-scripts/config/torrc-linux | 4 +-
build-scripts/config/vidalia.conf.ff-linux | 3 +-
build-scripts/linux.mk | 87 ++++++++++++++++++++--------
build-scripts/osx.mk | 2 +-
4 files changed, 66 insertions(+), 30 deletions(-)
diff --git a/build-scripts/config/torrc-linux b/build-scripts/config/torrc-linux
index 05f5345..7d11921 100644
--- a/build-scripts/config/torrc-linux
+++ b/build-scripts/config/torrc-linux
@@ -8,6 +8,6 @@ GeoIPFile ./Data/Tor/geoip
Log notice stdout
# Bind to this address to listen to connections from SOCKS-speaking
# applications.
-SocksPort auto
SocksListenAddress 127.0.0.1
-ControlPort auto
+SocksPort 9150
+ControlPort 9151
diff --git a/build-scripts/config/vidalia.conf.ff-linux b/build-scripts/config/vidalia.conf.ff-linux
index 26c66be..d0274e6 100644
--- a/build-scripts/config/vidalia.conf.ff-linux
+++ b/build-scripts/config/vidalia.conf.ff-linux
@@ -9,8 +9,7 @@ PluginsDirectory=../../Data/profile/extensions
DefaultPluginsDirectory=./extensions
[Tor]
-ControlPort=9051
+ControlPort=9151
TorExecutable=./tor
Torrc=../Data/Tor/torrc
-AutoControl=true
DataDirectory=../Data/Tor
diff --git a/build-scripts/linux.mk b/build-scripts/linux.mk
index cda9b7e..29af4a3 100644
--- a/build-scripts/linux.mk
+++ b/build-scripts/linux.mk
@@ -55,7 +55,7 @@ build-openssl: build-zlib $(OPENSSL_DIR)
cd $(OPENSSL_DIR) && make install_sw
touch $(STAMP_DIR)/build-openssl
-QT_BUILD_PREFS=-system-zlib -confirm-license -opensource -openssl-linked -no-webkit -no-qt3support -fast -release -nomake demos -nomake examples
+QT_BUILD_PREFS=-system-zlib -confirm-license -opensource -openssl-linked -no-qt3support -fast -release -nomake demos -nomake examples
QT_OPTS=$(QT_BUILD_PREFS) -prefix $(BUILT_DIR) -I $(BUILT_DIR)/include -I $(BUILT_DIR)/include/openssl/ -L$(BUILT_DIR)/lib
build-qt: build-zlib build-openssl $(QT_DIR)
cd $(QT_DIR) && ./configure $(QT_OPTS)
@@ -290,11 +290,32 @@ endif
## Configure Firefox, Vidalia, and Tor
configure-apps:
- ## Configure Firefox preferences
+ ## Configure Firefox bookmarks
mkdir -p $(DEST)/Data/profile/extensions
cp -R config/firefox-profiles.ini $(DEST)/Data/profiles.ini
cp config/bookmarks.html $(DEST)/Data/profile
- cp config/prefs.js $(DEST)/Data/profile/prefs.js
+
+ ## Override Firefox extension preferences
+ mkdir -p $(DEST)/Data/profile/preferences
+ cp config/extension-overrides.js $(DEST)/Data/profile/preferences
+
+ ## Patch Firefox default home page and omnibox
+ LC="en-US"; \
+ PFILE="omni.ja"; \
+ FFDIR=$(APPDIR)/Firefox/; \
+ CHROMEDIR="$$FFDIR/chrome/"; \
+ mkdir -p "$$CHROMEDIR/$$LC/locale/branding"; \
+ mkdir -p "$$CHROMEDIR/$$LC/locale/browser-region"; \
+ cp config/region.properties \
+ "$$CHROMEDIR/$$LC/locale/browser-region/"; \
+ sed -e "s/SHPONKA/$$LC/g" config/browserconfig.properties \
+ > "$$CHROMEDIR/$$LC/locale/branding/browserconfig.properties"; \
+ (cd "$$FFDIR"; \
+ zip -u "$$PFILE" "chrome/$$LC/locale/branding/browserconfig.properties" \
+ "chrome/$$LC/locale/browser-region/region.properties"); \
+ rm -rf "$$CHROMEDIR"
+
+# Configure Firefox, Vidalia, and Tor
## Configure Pidgin
ifeq ($(USE_PIDGIN),1)
mkdir -p $(DEST)/PidginPortable/Data/settings/.purple
@@ -336,8 +357,7 @@ compressed-bundle_%:
LANGCODE=$* make -f linux.mk compressed-bundle-localized
bundle-localized_%.stamp:
- make -f linux.mk copy-files_$* install-extensions install-torbutton install-lang-extensions patch-vidalia-language patch-firefox-language \
- patch-pidgin-language update-extension-pref write-tbb-version
+ make -f linux.mk copy-files_$* install-extensions install-torbutton install-lang-extensions patch-vidalia-language patch-firefox-config
touch $(STAMP_DIR)/bundle-localized_$*.stamp
bundle-localized: bundle-localized_$(LANGCODE).stamp
@@ -345,8 +365,8 @@ bundle-localized: bundle-localized_$(LANGCODE).stamp
compressed-bundle-localized: bundle-localized_$(LANGCODE).stamp
-rm -f $(DISTDIR)/$(COMPRESSED_NAME)_$(LANGCODE).tar.gz
-mkdir $(DISTDIR)
- tar -cvf - $(NAME)_$(LANGCODE) |tardy -unu 0 -una root -gnu 0 -gna wheel |gzip -c9 >$(DISTDIR)/$(DEFAULT_COMPRESSED_BASENAME)$(LANGCODE).tar.gz
- rm *.zip *.xpi
+ tar -cvf - $(NAME)_$(LANGCODE) |tardy -unu 0 -una root -gnu 0 -gna wheel |gzip -c9 >$(DISTDIR)/$(COMPRESSED_NAME)$(LANGCODE).tar.gz
+ rm -f *.zip *.xpi
copy-files_%: generic-bundle.stamp
rm -fr $(NAME)_$*
@@ -370,13 +390,28 @@ install-extensions: $(DEFAULT_EXTENSIONS)
install-torbutton: torbutton.xpi
mkdir -p $(BUNDLE)/Data/profile/extensions/
- cp torbutton.xpi $(BUNDLE)/Data/profile/extensions/{e0204bd5-9d31-402b-a99d-a6aa8ffebdca}.xpi
+ cp torbutton.xpi $(BUNDLE)/Data/profile/extensions/torbutton@xxxxxxxxxxxxxxxxxx
## Language extensions need to be handled differently from other extensions
install-lang-extensions: $(filter-out langpack_en-US.xpi,langpack_$(LANGCODE).xpi)
ifneq ($(LANGCODE), en-US)
mkdir -p $(BUNDLE)/Data/profile/extensions
cp langpack_$(LANGCODE).xpi $(BUNDLE)/Data/profile/extensions/langpack-$(LANGCODE)@firefox.mozilla.org.xpi
+ ## Patch Firefox default home page within language pack
+ LC=$(LANGCODE); \
+ PFILE=langpack-$(LANGCODE)@firefox.mozilla.org.xpi; \
+ FFDIR=$(BUNDLE)/Data/profile/extensions/; \
+ CHROMEDIR="$$FFDIR/chrome/"; \
+ mkdir -p "$$CHROMEDIR/$$LC/locale/branding"; \
+ mkdir -p "$$CHROMEDIR/$$LC/locale/browser-region"; \
+ cp config/region.properties \
+ "$$CHROMEDIR/$$LC/locale/browser-region/"; \
+ sed -e "s/SHPONKA/$$LC/g" config/browserconfig.properties \
+ > "$$CHROMEDIR/$$LC/locale/branding/browserconfig.properties"; \
+ (cd "$$FFDIR"; \
+ zip -u "$$PFILE" "chrome/$$LC/locale/branding/browserconfig.properties" \
+ "chrome/$$LC/locale/browser-region/region.properties"); \
+ rm -rf "$$CHROMEDIR"
endif
## Set the language for Vidalia
@@ -393,26 +428,28 @@ ifeq ($(USE_PIDGIN),1)
$(BUNDLE)/PidginPortable/App/GTK/share/locale
endif
-patch-firefox-language:
- ## Patch the default Firefox prefs.js
+patch-firefox-config:
+ ## Patch Firefox default preferences by adding a patched #tor.js file:
+ PREFSDIR=$(BUNDLE)/App/Firefox/defaults/preferences; \
+ mkdir -p "$$PREFSDIR"; \
+ sed -e "s/SHPONKA/$(LANGCODE)/g" config/pound_tor.js \
+ > "$$PREFSDIR/#tor.js"; \
+ ./patch-firefox-language.sh "$$PREFSDIR/#tor.js" $(LANGCODE) -e; \
+ printf 'pref("torbrowser.version", "%s");\n' \
+ "$(RELEASE_VER)-$(BUILD_NUM)-$(PLATFORM)" \
+ >> "$$PREFSDIR/#tor.js"; \
+ (cd $(BUNDLE)/App/Firefox; zip -u omni.ja defaults/preferences/#tor.js);\
+ rm -rf "$$PREFSDIR"
+ ##
+ ## Copy other Firefox configuration files into our bundle
## Don't use {} because they aren't always interpreted correctly. Thanks, sh.
- mkdir -p $(BUNDLE)/App/Firefox/defaults/profile/
+ mkdir -p $(BUNDLE)/App/Firefox/defaults/profile/preferences
cp config/bookmarks.html $(BUNDLE)/App/Firefox/defaults/profile/
- cp config/prefs.js $(BUNDLE)/App/Firefox/defaults/profile/prefs.js
+ cp config/extension-overrides.js \
+ $(BUNDLE)/App/Firefox/defaults/profile/preferences
+ mkdir -p $(BUNDLE)/Data/profile/preferences
cp config/bookmarks.html $(BUNDLE)/Data/profile
- cp config/prefs.js $(BUNDLE)/Data/profile/prefs.js
- ./patch-firefox-language.sh $(BUNDLE)/App/Firefox/defaults/profile/prefs.js $(LANGCODE) -e
- ./patch-firefox-language.sh $(BUNDLE)/Data/profile/prefs.js $(LANGCODE) -e
-
-## Fix prefs.js since extensions.checkCompatibility, false doesn't work
-update-extension-pref:
- sed -i -e "s/SHPONKA/$(LANGCODE)/g" $(BUNDLE)/Data/profile/prefs.js
- sed -i -e "s/SHPONKA/$(LANGCODE)/g" $(BUNDLE)/App/Firefox/defaults/profile/prefs.js
+ cp config/extension-overrides.js $(BUNDLE)/Data/profile/preferences
print-version:
@echo $(RELEASE_VER)-$(BUILD_NUM)
-
-write-tbb-version:
- printf 'user_pref("torbrowser.version", "%s");\n' "$(RELEASE_VER)-$(BUILD_NUM)-$(PLATFORM)-$(ARCH_TYPE)" >> $(BUNDLE)/App/Firefox/defaults/profile/prefs.js
- printf 'user_pref("torbrowser.version", "%s");\n' "$(RELEASE_VER)-$(BUILD_NUM)-$(PLATFORM)-$(ARCH_TYPE)" >> $(BUNDLE)/Data/profile/prefs.js
-
diff --git a/build-scripts/osx.mk b/build-scripts/osx.mk
index 757b9f3..7f71786 100644
--- a/build-scripts/osx.mk
+++ b/build-scripts/osx.mk
@@ -67,7 +67,7 @@ endif
QT_BUILD_PREFS=-system-zlib -confirm-license -opensource -openssl-linked -no-qt3support \
- -fast -release -no-webkit -no-framework -nomake demos -nomake examples $(SDK) -arch $(ARCH_TYPE)
+ -fast -release -no-framework -nomake demos -nomake examples $(SDK) -arch $(ARCH_TYPE)
QT_OPTS=$(QT_BUILD_PREFS) -prefix $(BUILT_DIR) -I $(BUILT_DIR)/include -I $(BUILT_DIR)/include/openssl/ -L $(BUILT_DIR)/lib
build-qt: build-zlib build-openssl $(QT_DIR)
cd $(QT_DIR) && ./configure $(QT_OPTS)
_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits