Include English browser searchplugins for non-English
Originally created by @anonym on #9950 (Redmine)
Before the switch to Disconnect.me and the new browser localization system in tails 1.4, we had the Startpage plugin both in the locale’s language and in English. Since then both Startpage and Disconnect.me are only available in the locale’s language, which could be seen as a regression.
The following patch should fix it:
--- a/config/chroot_local-hooks/11-localize_browser
+++ b/config/chroot_local-hooks/11-localize_browser
@@ -141,11 +141,16 @@ while IFS=: read MOZILLA_LOCALE LOCATION LOCALIZED_LANG STARTPAGE_LANG STARTPAGE
fi
done < "${DESCRIPTIONS_FILE}"
+cp "${TBB_LOCALIZED_SEACHPLUGINS_DIR}/en-US/*.xml" \
+ "${TBB_DEFAULT_SEARCHPLUGINS_DIR}"
+
# This directory is not needed after build time.
rm -r "${BROWSER_LOCALIZATION_DIR}"
# All generated files must be world-readable.
-chmod -R a+rX "${TBB_LOCALIZED_SEACHPLUGINS_DIR}" "${BRANDING_DIR}"
+chmod -R a+rX "${TBB_DEFAULT_SEARCHPLUGINS_DIR}" \
+ "${TBB_LOCALIZED_SEACHPLUGINS_DIR}" \
+ "${BRANDING_DIR}"
# Remove unwanted browser search plugins bundled in the Tor Browser.
rm "${TBB_DEFAULT_SEARCHPLUGINS_DIR}"/yahoo*.xml