[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [tor-browser-build/master] Remove search engines from language packs



commit 4a632f8ac10f5d01ac9ef075fc698bd7454ab6cb
Author: Nicolas Vigier <boklm@xxxxxxxxxxxxxx>
Date:   Mon Aug 5 10:36:18 2019 +0200

    Remove search engines from language packs
    
    With https://bugzilla.mozilla.org/show_bug.cgi?id=1437942 search engines
    are removed from language packs.
---
 projects/tor-browser/build | 53 +++++++++++++++++++++-------------------------
 1 file changed, 24 insertions(+), 29 deletions(-)

diff --git a/projects/tor-browser/build b/projects/tor-browser/build
index 1f155d1..71084f2 100644
--- a/projects/tor-browser/build
+++ b/projects/tor-browser/build
@@ -169,10 +169,6 @@ fi
 
 
 pushd "$TBDIR[% IF c("var/osx") %]/Contents/Resources[% END %]/browser/"
-# For the proper search engines in our language packs
-unzip omni.ja chrome/en-US/locale/browser/searchplugins* || [ $? -lt 3 ]
-mv chrome/en-US/locale/browser/searchplugins $rootdir
-rm -rf chrome/en-US
 unzip omni.ja defaults/preferences/000-tor-browser.js || [ $? -lt 3 ]
 # Append our built extension-overrides.js to 000-tor-browser.js
 cat "$GENERATEDPREFSPATH" >> defaults/preferences/000-tor-browser.js
@@ -194,32 +190,31 @@ rm -rf defaults
 echo '{"version":"[% c("var/torbrowser_version") %]","architecture":"[% c("var/mar_osname") %]","channel":"[% c("var/channel") %]","locale":"en-US"}' > ../tbb_version.json
 popd
 
-# Prepare our language packs for using the proper search engines and embed
-# our default bookmarks. See bugs 18915 and 21879 for more details.
-[% SET locales = c("var/testbuild") ? [] : c("var/locales") -%]
-[% FOREACH lang = locales %]
-[% SET lang = tmpl(lang);
-   SET xpi = '$rootdir/' _ c('input_files_by_name/firefox-langpacks') _ '/' _ lang _ '.xpi';
-   %]
-  unzip -d prep_[% lang %] [% xpi %]
-  search_plugins_path=prep_[% lang %]/browser/chrome/[% lang %]/locale/browser
-  rm -rf $search_plugins_path/searchplugins
-  cp -rf $rootdir/searchplugins $search_plugins_path
-  [% IF c("var/osx") -%]
-    cp $rootdir/bookmarks.html prep_[% lang %]/browser/chrome/[% lang %]/locale/browser/
-  [% END -%]
-  rm [% xpi %]
-  cd prep_[% lang %]
-  [% c('zip', {
-          zip_src => [ '.' ],
-          zip_args => xpi,
-      }) %]
-  # If we are building a multi-lingual package, add all of the language packs.
-  [% IF c("var/multi_lingual") %]
-    cp [% xpi %] "$TBDIR/$EXTSPATH/langpack-[% lang %]@firefox.mozilla.org.xpi"
+[% IF c("var/osx") || c("var/multi_lingual") -%]
+  # Prepare our language packs to embed our default bookmarks.
+  # See bug 21879 for more details.
+  [% SET locales = c("var/testbuild") ? [] : c("var/locales") -%]
+  [% FOREACH lang = locales %]
+  [% SET lang = tmpl(lang);
+     SET xpi = '$rootdir/' _ c('input_files_by_name/firefox-langpacks') _ '/' _ lang _ '.xpi';
+     %]
+    [% IF c("var/osx") -%]
+      unzip -d prep_[% lang %] [% xpi %]
+      cp $rootdir/bookmarks.html prep_[% lang %]/browser/chrome/[% lang %]/locale/browser/
+      rm [% xpi %]
+      cd prep_[% lang %]
+      [% c('zip', {
+              zip_src => [ '.' ],
+              zip_args => xpi,
+          }) %]
+    [% END -%]
+    # If we are building a multi-lingual package, add all of the language packs.
+    [% IF c("var/multi_lingual") %]
+      cp [% xpi %] "$TBDIR/$EXTSPATH/langpack-[% lang %]@firefox.mozilla.org.xpi"
+    [% END %]
+    cd ..
+    rm -rf prep_[% lang %]
   [% END %]
-  cd ..
-  rm -rf prep_[% lang %]
 [% END %]
 
 [% IF c("var/multi_lingual") %]

_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits