mirror of
https://github.com/archlinux/aur.git
synced 2026-03-14 23:16:48 +01:00
60.6.3-3
This commit is contained in:
parent
6585eb7324
commit
f4315f0094
4 changed files with 35 additions and 604 deletions
2
.SRCINFO
2
.SRCINFO
|
|
@ -60,7 +60,7 @@ pkgbase = icecat
|
|||
sha256sums = 8b37332dd205946ea95c606103b5b0e1e8498819051ea1c1bce79f04fd88ebca
|
||||
sha256sums = 08ab4293d6008524a38e20b428c750c4c55a2f7189e9a0067871ad723c1efab5
|
||||
sha256sums = cb1116c783995b8187574f84acb8365681aedaa2c76222cf060d31fedcb063c4
|
||||
sha256sums = bc424d1dfdc2f0a95c1f3d46c60eb109bc58661bbe4ac4e51e35117218ea31de
|
||||
sha256sums = 1b1b272aa01548ffbe81a7811e17bba8195e890279b16065626aba11044085c3
|
||||
|
||||
pkgname = icecat
|
||||
|
||||
|
|
|
|||
2
PKGBUILD
2
PKGBUILD
|
|
@ -34,7 +34,7 @@ sha256sums=('c329f94adaec97553865b2a5da0578bcad914063b99ab99aa18e3a4f5db66d75'
|
|||
'8b37332dd205946ea95c606103b5b0e1e8498819051ea1c1bce79f04fd88ebca'
|
||||
'08ab4293d6008524a38e20b428c750c4c55a2f7189e9a0067871ad723c1efab5'
|
||||
'cb1116c783995b8187574f84acb8365681aedaa2c76222cf060d31fedcb063c4'
|
||||
'bc424d1dfdc2f0a95c1f3d46c60eb109bc58661bbe4ac4e51e35117218ea31de')
|
||||
'1b1b272aa01548ffbe81a7811e17bba8195e890279b16065626aba11044085c3')
|
||||
|
||||
#validpgpkeys=(A57369A8BABC2542B5A0368C3C76EED7D7E04784) # Ruben Rodriguez (GNU IceCat releases key) <ruben@gnu.org>
|
||||
|
||||
|
|
|
|||
599
makeicecat
599
makeicecat
|
|
@ -1,599 +0,0 @@
|
|||
#!/bin/bash
|
||||
#
|
||||
# Copyright (C) 2014-2018 Ruben Rodriguez <ruben@gnu.org>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
#
|
||||
|
||||
set -euxo pipefail
|
||||
|
||||
FFMAJOR=60
|
||||
FFMINOR=6
|
||||
FFSUB=3
|
||||
GNUVERSION=1
|
||||
FFVERSION=$FFMAJOR.$FFMINOR.$FFSUB
|
||||
ICECATVERSION=$FFVERSION-gnu$GNUVERSION
|
||||
SOURCEDIR=icecat-$FFVERSION
|
||||
|
||||
export DEBEMAIL=ruben@gnu.org
|
||||
export DEBFULLNAME="Ruben Rodriguez"
|
||||
|
||||
DATA="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"/data
|
||||
|
||||
mkdir output
|
||||
cd output
|
||||
|
||||
###############################################################################
|
||||
# Retrieve FF source code
|
||||
###############################################################################
|
||||
|
||||
rm mozilla-esr${FFMAJOR} $SOURCEDIR -rf
|
||||
|
||||
wget -N https://ftp.mozilla.org/pub/mozilla.org/firefox/releases/${FFVERSION}esr/source/firefox-${FFVERSION}esr.source.tar.xz
|
||||
wget -N https://ftp.mozilla.org/pub/mozilla.org/firefox/releases/${FFVERSION}esr/source/firefox-${FFVERSION}esr.source.tar.xz.asc
|
||||
gpg --recv-keys --keyserver keyserver.ubuntu.com 24C6F355
|
||||
gpg --verify firefox-${FFVERSION}esr.source.tar.xz.asc
|
||||
echo -n eebf34968c64cf8c007dd0da98124edf55cdda141f8b4c653e8e00b22650833e firefox-${FFVERSION}esr.source.tar.xz |sha256sum -c -
|
||||
|
||||
echo Extracting Firefox tarball
|
||||
tar -xf firefox-${FFVERSION}esr.source.tar.xz
|
||||
|
||||
mv firefox-${FFVERSION} $SOURCEDIR
|
||||
|
||||
###############################################################################
|
||||
# Retrieve l10n
|
||||
###############################################################################
|
||||
|
||||
mkdir l10n
|
||||
cd l10n
|
||||
while read line;do
|
||||
line=$(echo $line |cut -d' ' -f1)
|
||||
#[ $line = "es-ES" ] || continue # To speed up testing
|
||||
[ $line = "en-US" ] && continue
|
||||
hg clone https://hg.mozilla.org/l10n-central/$line
|
||||
mkdir -p $line/browser/chrome/browser/preferences
|
||||
touch $line/browser/chrome/browser/preferences/advanced-scripts.dtd
|
||||
rm -rf $line/.hg*
|
||||
done < ../$SOURCEDIR/browser/locales/shipped-locales
|
||||
cd ..
|
||||
|
||||
mv l10n $SOURCEDIR
|
||||
|
||||
hg clone http://hg.mozilla.org/l10n/compare-locales/
|
||||
cd compare-locales/
|
||||
hg checkout RELEASE_3_3_0
|
||||
cd ..
|
||||
rm compare-locales/.hg* compare-locales/.git* -rf
|
||||
mv compare-locales $SOURCEDIR/l10n
|
||||
|
||||
#######################################################
|
||||
|
||||
cd $SOURCEDIR
|
||||
|
||||
#for patch in $DATA/patches/*; do
|
||||
# echo Patching with file: $patch
|
||||
# patch -p1 < $patch
|
||||
#done
|
||||
|
||||
cp $DATA/Changelog.IceCat $DATA/README.IceCat .
|
||||
cp $DATA/Changelog.IceCat $DATA/README.IceCat
|
||||
|
||||
###############################################################################
|
||||
# Functions
|
||||
###############################################################################
|
||||
|
||||
sedhelper2(){
|
||||
FILE="$1"
|
||||
EXPR="$2"";"
|
||||
|
||||
while [ 1"$EXPR" != 1 ];do
|
||||
SUBEXPR=$(cut -d\; -f 1 <<< "$EXPR")
|
||||
MD5=$(md5sum "$FILE")
|
||||
echo Running modification-aware sed: sed "$SUBEXPR" -i "$FILE"
|
||||
/bin/sed "$SUBEXPR" -i "$FILE"
|
||||
if [ "$MD5" = "$(md5sum "$FILE")" ]; then
|
||||
echo File "$FILE" was not modified, stopping.
|
||||
exit 1
|
||||
fi
|
||||
EXPR=$(cut -d\; -f 2- <<< "$EXPR" )
|
||||
echo $EXPR | egrep ';' -q || break
|
||||
done
|
||||
}
|
||||
|
||||
sedhelper(){
|
||||
FILE="$1"
|
||||
EXPR="$2"
|
||||
|
||||
MD5=$(md5sum "$FILE")
|
||||
echo Running modification-aware sed: sed "$EXPR" -i "$FILE"
|
||||
/bin/sed "$EXPR" -i "$FILE"
|
||||
if [ "$MD5" = "$(md5sum "$FILE")" ]; then
|
||||
echo File "$FILE" was not modified, stopping.
|
||||
exit 1
|
||||
fi
|
||||
}
|
||||
|
||||
sed (){
|
||||
if ! echo $@ | grep -qw '\-i'; then
|
||||
echo Running fallback sed: /bin/sed "$@"
|
||||
/bin/sed "$@"
|
||||
else
|
||||
|
||||
[ 1"$1" = "1-i" ] && shift
|
||||
|
||||
SEDEXPR="$1"
|
||||
shift
|
||||
for FILE in "$@"; do
|
||||
[ 1"$FILE" = "1-i" ] && continue
|
||||
if [ -f "$FILE" ]; then
|
||||
sedhelper "$FILE" "$SEDEXPR"
|
||||
else
|
||||
echo File "$FILE" does not exist, stopping.
|
||||
exit 1
|
||||
fi
|
||||
done
|
||||
fi
|
||||
}
|
||||
|
||||
###############################################################################
|
||||
# Set variables and build config files
|
||||
###############################################################################
|
||||
|
||||
INFOURL="www.gnu.org/software/gnuzilla/"
|
||||
LEGALINFOURL="www.gnu.org/software/gnuzilla/"
|
||||
ADDONSURL="www.gnu.org/software/gnuzilla/addons.html"
|
||||
LISTURL="lists.gnu.org/mailman/listinfo/bug-gnuzilla"
|
||||
|
||||
###############################################################################
|
||||
# Custom settings and features
|
||||
###############################################################################
|
||||
|
||||
# Disable EME
|
||||
echo "ac_add_options --disable-eme" >> build/mozconfig.common.override
|
||||
echo "ac_add_options --disable-eme" >> build/mozconfig.common
|
||||
|
||||
# Disable healthreport
|
||||
sed '/mozilla.org\/legal/d' -i toolkit/components/telemetry/healthreport-prefs.js
|
||||
cat << EOF >> toolkit/components/telemetry/healthreport-prefs.js
|
||||
pref("datareporting.healthreport.infoURL", "https://$INFOURL");
|
||||
EOF
|
||||
|
||||
# Custom privacy statement link
|
||||
sed "s%https://www.mozilla.org/legal/privacy/%https://$LEGALINFOURL%" -i ./browser/app/profile/firefox.js ./toolkit/content/aboutRights.xhtml
|
||||
|
||||
# Copy custom ddg search plugin
|
||||
find |grep -e ddg.xml -e duckduckgo.*.xml | xargs -i cp $DATA/searchplugins/duckduckgo.xml {}
|
||||
|
||||
# Sanitize lists
|
||||
for file in $(find |grep searchplugins/list.txt)
|
||||
do
|
||||
/bin/sed /^$/d -i $file
|
||||
sort -u $file > /tmp/sorttmp
|
||||
cp /tmp/sorttmp $file
|
||||
echo >> $file
|
||||
done
|
||||
|
||||
# Disable activity-stream antifeatures.
|
||||
# These are not condensed into a single sed script to make it fail on individual commands that didn't change the source
|
||||
sed '/^const DEFAULT_SITES/,/^])\;/c const DEFAULT_SITES = new Map\([[""]]\);' -i browser/extensions/activity-stream/lib/ActivityStream.jsm
|
||||
sed '/\["showSponsored/,/value/s/value: true/value: false/' -i browser/extensions/activity-stream/lib/ActivityStream.jsm
|
||||
sed '/\["disableSnippets/,/value/s/value: false/value: true/' -i browser/extensions/activity-stream/lib/ActivityStream.jsm
|
||||
sed '/\["telemetry"/,/value/s/value: true/value: false/' -i browser/extensions/activity-stream/lib/ActivityStream.jsm
|
||||
sed '/\["section.highlights.includePocket"/,/value/s/value: true/value: false/' -i browser/extensions/activity-stream/lib/ActivityStream.jsm
|
||||
sed '/\["telemetry.ping.endpoint"/,/value/s/value: .*/value: ""/' -i browser/extensions/activity-stream/lib/ActivityStream.jsm
|
||||
sed '/\["tippyTop.service.endpoint"/,/value/s/value: .*/value: ""/' -i browser/extensions/activity-stream/lib/ActivityStream.jsm
|
||||
sed 's/\(read_more_endpoint:\) .http.*/\1 "",/' -i browser/extensions/activity-stream/lib/ActivityStream.jsm
|
||||
sed 's/\(stories_endpoint:\) .http.*/\1 "",/' -i browser/extensions/activity-stream/lib/ActivityStream.jsm
|
||||
sed 's/\(stories_referrer:\) .http.*/\1 "",/' -i browser/extensions/activity-stream/lib/ActivityStream.jsm
|
||||
sed 's/\(privacy_notice_link:\) .http.*/\1 "https:\/\/trisquel.info\/legal",/' -i browser/extensions/activity-stream/lib/ActivityStream.jsm
|
||||
sed 's/\(disclaimer_link:\) .http.*/\1 "",/' -i browser/extensions/activity-stream/lib/ActivityStream.jsm
|
||||
sed 's/\(topics_endpoint:\) .http.*/\1 "",/' -i browser/extensions/activity-stream/lib/ActivityStream.jsm
|
||||
sed '/name: "snippets"/,/value/s/value: true/value: false/' -i browser/extensions/activity-stream/lib/ActivityStream.jsm
|
||||
sed '/name: "telemetry"/,/value/s/value: true/value: false/' -i browser/extensions/activity-stream/lib/ActivityStream.jsm
|
||||
sed '/name: "section.topstories"/,/return/s/return.*/return false;/' -i browser/extensions/activity-stream/lib/ActivityStream.jsm
|
||||
|
||||
|
||||
###############################################################################
|
||||
# Branding
|
||||
###############################################################################
|
||||
|
||||
# Branding files
|
||||
rm browser/branding/{official,unofficial,aurora,nightly} mobile/android/branding/* -rf
|
||||
cp -a $DATA/branding/icecat/ browser/branding/official
|
||||
cp -a $DATA/branding/icecat/ browser/branding/nightly
|
||||
cp -a $DATA/branding/icecatmobile/ mobile/android/branding/official
|
||||
cp -a $DATA/branding/icecatmobile/ mobile/android/branding/unofficial
|
||||
cp -a $DATA/branding/icecatmobile/ mobile/android/branding/nightly
|
||||
# Disable preprocessor
|
||||
sed 's/_PP//' -i browser/branding/branding-common.mozbuild
|
||||
|
||||
# Delete stuff we don't use and that may contain trademaked logos
|
||||
rm -rf ./browser/metro ./addon-sdk/source/doc/static-files/media ./b2g
|
||||
|
||||
# Custom bookmarks
|
||||
cp $DATA/bookmarks.html.in browser/locales/generic/profile/bookmarks.html.in
|
||||
|
||||
# Custom legal about pages
|
||||
|
||||
find -wholename '*/brand.dtd' |xargs /bin/sed 's/trademarkInfo.part1.*/trademarkInfo.part1 "">/' -i
|
||||
|
||||
for STRING in community.end3 community.exp.end community.start2 community.mozillaLink community.middle2 community.creditsLink community.end2 contribute.start contribute.getInvolvedLink contribute.end channel.description.start channel.description.end
|
||||
do
|
||||
find -name aboutDialog.dtd | xargs sed -i "s/ENTITY $STRING.*/ENTITY $STRING \"\">/"
|
||||
done
|
||||
|
||||
for STRING in rights.intro-point3-unbranded rights.intro-point4a-unbranded rights.intro-point4b-unbranded rights.intro-point4c-unbranded
|
||||
do
|
||||
find -name aboutRights.dtd | xargs sed -i "s/ENTITY $STRING.*/ENTITY $STRING \"\">/"
|
||||
done
|
||||
|
||||
sed '/helpus.start/d' -i browser/base/content/aboutDialog.xul
|
||||
|
||||
cp $DATA/aboutRights.xhtml toolkit/content/aboutRights.xhtml
|
||||
cp $DATA/aboutRights.xhtml toolkit/content/aboutRights-unbranded.xhtml
|
||||
|
||||
sed -i 's/<a\ href\=\"http\:\/\/www.mozilla.org\/\">Mozilla\ Project<\/a>/<a\ href\=\"http\:\/\/www.gnu.org\/\"\>GNU\ Project<\/a>/g' browser/base/content/overrides/app-license.html
|
||||
|
||||
# Custom logo for about:preferences?entrypoint=menupanel#sync
|
||||
cp $DATA/branding/sync.png browser/themes/shared/fxa/logo.png
|
||||
|
||||
# Hide mobile promo
|
||||
echo ".fxaMobilePromo { display: none !important; }" >> browser/themes/shared/incontentprefs/preferences.inc.css
|
||||
|
||||
# Hide plugindeprecation-notice
|
||||
echo "#plugindeprecation-notice { display: none !important; }" >> toolkit/mozapps/extensions/content/extensions.css
|
||||
# Hide warnings on unsigned extensions
|
||||
echo ".warning{display: none!important; } .addon[notification=warning]{background-image: none!important;}" >> toolkit/mozapps/extensions/content/extensions.css
|
||||
# Hide extra links in about box
|
||||
sed '/releaseNotes.link/d; /helpus/d' -i ./browser/base/content/aboutDialog.xul
|
||||
|
||||
###############################################################################
|
||||
# Batch rebranding
|
||||
###############################################################################
|
||||
|
||||
# Replace Firefox branding
|
||||
find -type d | grep fennec | xargs prename s/fennec/icecatmobile/
|
||||
find -type f | grep fennec | xargs prename s/fennec/icecatmobile/
|
||||
find -type f | grep Fennec | xargs prename s/Fennec/IceCatMobile/
|
||||
find -type d | grep firefox | xargs prename -f s/firefox/icecat/
|
||||
find -type f | grep firefox | xargs prename -f s/firefox/icecat/
|
||||
find -type f | grep Firefox | xargs prename -f s/Firefox/IceCat/
|
||||
|
||||
echo "Running batch rebranding"
|
||||
SEDSCRIPT="
|
||||
s|marketplace.firefox.com|f-droid.org/repository/browse|g;
|
||||
s/org.mozilla.firefox/org.gnu.icecat/g;
|
||||
s/Adobe Flash/Flash/g;
|
||||
s|addons.mozilla.org.*/mobile|directory.fsf.org/wiki/GNU_IceCat|g;
|
||||
s|addons.mozilla.org.*/android|directory.fsf.org/wiki/GNU_IceCat|g;
|
||||
s|support.mozilla.org.*/mobile|libreplanet.org/wiki/Group:IceCat/icecat-help|g;
|
||||
s|fhr.cdn.mozilla.net.*mobile|127.0.0.1|g;
|
||||
s/run-mozilla.sh/run-icecat.sh/g;
|
||||
s/Firefox Marketplace/F-droid free software repository/g;
|
||||
s|mozilla.com/plugincheck|$ADDONSURL|g;
|
||||
s|www.mozilla.com/firefox/central|$INFOURL|g;
|
||||
s|www.mozilla.*/legal/privacy.*html|$LEGALINFOURL|g;
|
||||
s|www.mozilla.*/legal/privacy|$LEGALINFOURL|g;
|
||||
|
||||
s/Mozilla Firefox/GNU IceCat/g;
|
||||
s/firefox/icecat/g;
|
||||
s/fennec/icecatmobile/g;
|
||||
s/Firefox/IceCat/g;
|
||||
s/Fennec/IceCatMobile/g;
|
||||
s/FIREFOX/ICECAT/g;
|
||||
s/FENNEC/ICECATMOBILE/g;
|
||||
s/ Mozilla / GNU /g;
|
||||
|
||||
s|PACKAGES/icecat|PACKAGES/firefox|g;
|
||||
s/GNU Public/Mozilla Public/g;
|
||||
s/GNU Foundation/Mozilla Foundation/g;
|
||||
s/GNU Corporation/Mozilla Corporation/g;
|
||||
s/icecat.com/firefox.com/g;
|
||||
s/IceCat-Spdy/Firefox-Spdy/g;
|
||||
s/icecat-accounts/firefox-accounts/g;
|
||||
s/IceCatAccountsCommand/FirefoxAccountsCommand/g;
|
||||
s|https://www.mozilla.org/icecat/?utm_source=synceol|https://www.mozilla.org/firefox/?utm_source=synceol|g;
|
||||
|
||||
s|www.gnu.org/software/gnuzilla/icecat-help|libreplanet.org/wiki/Group:IceCat/Help|g;
|
||||
"
|
||||
find . -type f -not -iregex '.*changelog.*' -not -iregex '.*copyright.*' -not -iregex '.*third_party/rust.*' -execdir /bin/sed --follow-symlinks -i "$SEDSCRIPT" '{}' ';'
|
||||
|
||||
|
||||
find l10n -type f -execdir /bin/sed --follow-symlinks -i "s/from GNU/from Mozilla/g" '{}' ';'
|
||||
|
||||
SEDSCRIPT="
|
||||
s/free and open source software/Free Software/g;
|
||||
s/free and open source/Free Software/g;
|
||||
s/Open Source/Free Software/g;
|
||||
s/open source/Free Software/g;
|
||||
s/opensourcesoftware/Free Software/g;
|
||||
s/opensource/Free Software/g;
|
||||
s/OpenSource/Free Software/g;
|
||||
"
|
||||
|
||||
for extension in dtd inc properties; do
|
||||
find . -type f -name "*$extension" -execdir /bin/sed --follow-symlinks -i "$SEDSCRIPT" '{}' ';'
|
||||
done
|
||||
|
||||
sed 's/which are both/which are/; s/free<\/a> and/Free Software<\/a>./; />open source</d; s/free and open source licenses/Free Software licenses/ ' -i toolkit/content/license.html
|
||||
|
||||
sed 's/mozilla-bin/icecat-bin/' -i build/unix/run-mozilla.sh
|
||||
|
||||
find -type f | grep run-mozilla | xargs prename s/mozilla/icecat/
|
||||
|
||||
# do not alter useragent/platform/oscpu/etc with fingerprinting countermeasure, it makes things worse
|
||||
sed '/ShouldResistFingerprinting/,/}/s/^/\/\//' -i ./netwerk/protocol/http/nsHttpHandler.cpp
|
||||
sed '/If fingerprinting resistance is on/,/}/s/^/\/\//' -i ./dom/base/Navigator.cpp
|
||||
|
||||
# Leave user agent as Firefox
|
||||
sed "/MOZILLA_UAVERSION/ s:IceCat/:Firefox/:" -i netwerk/protocol/http/nsHttpHandler.cpp
|
||||
|
||||
find . -name region.properties |xargs -i /bin/sed 's_https://www.mibbit.*__' -i {}
|
||||
|
||||
# Set migrator scripts
|
||||
cp browser/components/migration/IceCatProfileMigrator.js browser/components/migration/FirefoxProfileMigrator.js
|
||||
sed 's/IceCat/Firefox/g; s/icecat/firefox/g' -i browser/components/migration/FirefoxProfileMigrator.js
|
||||
|
||||
# Copy js settings
|
||||
cat $DATA/settings.js >> browser/app/profile/icecat.js
|
||||
|
||||
# Set spoofed useragent on the desktop version
|
||||
cat << EOF >> browser/app/profile/icecat.js
|
||||
// Set useragent to Firefox compatible
|
||||
//pref("general.useragent.compatMode.firefox",true);
|
||||
// Spoof the useragent to a generic one
|
||||
//pref("general.useragent.compatMode.icecat",true);
|
||||
// Spoof the useragent to a generic one
|
||||
//pref("general.useragent.override", "Mozilla/5.0 (Windows NT 6.1; rv:${FFMAJOR}.0) Gecko/20100101 Firefox/${FFMAJOR}.0");
|
||||
pref("general.appname.override", "Netscape");
|
||||
pref("general.appversion.override", "${FFMAJOR}.0");
|
||||
pref("general.buildID.override", "Gecko/20100101");
|
||||
pref("general.oscpu.override", "Windows NT 6.1");
|
||||
pref("general.platform.override", "Win32");
|
||||
EOF
|
||||
|
||||
cat << EOF >> browser/confvars.sh
|
||||
# IceCat settings
|
||||
MOZ_APP_UA_NAME=IceCat
|
||||
MOZ_APP_VENDOR=GNU
|
||||
MOZ_APP_VERSION=$FFVERSION
|
||||
MOZ_APP_PROFILE=mozilla/icecat
|
||||
MOZ_PAY=0
|
||||
MOZ_SERVICES_HEALTHREPORT=0
|
||||
MOZ_SERVICES_HEALTHREPORTER=0
|
||||
MOZ_SERVICES_FXACCOUNTS=0
|
||||
MOZ_SERVICES_METRICS=0
|
||||
MOZ_DATA_REPORTING=0
|
||||
MOZ_SERVICES_SYNC=0
|
||||
MOZ_DEVICES=0
|
||||
MOZ_ANDROID_GOOGLE_PLAY_SERVICES=0
|
||||
MOZ_ADDON_SIGNING=0
|
||||
EOF
|
||||
|
||||
sed 's/mozilla-esr/gnu-esr/' -i browser/confvars.sh
|
||||
|
||||
###############################################################################
|
||||
# Icons
|
||||
###############################################################################
|
||||
|
||||
favicon=$DATA/branding/icecat/icecat.ico
|
||||
jpglogo=$DATA/../artwork/icecat.jpg
|
||||
|
||||
#Firefox logo
|
||||
ff256=$DATA/branding/icecat/default256.png
|
||||
ff128=$DATA/branding/icecat/mozicon128.png
|
||||
ff64=$DATA/branding/icecat/content/icon64.png
|
||||
ff48=$DATA/branding/icecat/default48.png
|
||||
ff32=$DATA/branding/icecat/default32.png
|
||||
ff24=$DATA/branding/icecat/default24.png
|
||||
ff22=$DATA/branding/icecat/default22.png
|
||||
ff16=$DATA/branding/icecat/default16.png
|
||||
|
||||
#Grey flat logo
|
||||
gf300=$DATA/android-images/resources/drawable-xhdpi/icon_home_empty_icecat.png
|
||||
gf225=$DATA/android-images/resources/drawable-hdpi/icon_home_empty_icecat.png
|
||||
gf150=$DATA/android-images/resources/drawable-mdpi/icon_home_empty_icecat.png
|
||||
gf32=$DATA/android-images/resources/drawable-xhdpi/ic_status_logo.png
|
||||
gf24=$DATA/android-images/resources/drawable-hdpi/ic_status_logo.png
|
||||
gf16=$DATA/android-images/resources/drawable-mdpi/ic_status_logo.png
|
||||
# White flat
|
||||
wf24=$DATA/android-images/resources/drawable-mdpi-v11/ic_status_logo.png
|
||||
wf48=$DATA/android-images/resources/drawable-xhdpi-v11/ic_status_logo.png
|
||||
wf36=$DATA/android-images/resources/drawable-hdpi-v11/ic_status_logo.png
|
||||
|
||||
#Market logo
|
||||
ma50=$DATA/android-images/core/marketplace-logo.png
|
||||
ma128=$DATA/android-images/resources/drawable-mdpi/marketplace.png
|
||||
|
||||
cp $ff16 dom/canvas/test/crossorigin/image.png
|
||||
cp $ff16 image/test/unit/image1.png
|
||||
cp $jpglogo image/test/unit/image1png16x16.jpg
|
||||
cp $jpglogo image/test/unit/image1png64x64.jpg
|
||||
cp $ff16 image/test/unit/image2jpg16x16.png
|
||||
cp $ff16 image/test/unit/image2jpg16x16-win.png
|
||||
cp $ff32 image/test/unit/image2jpg32x32.png
|
||||
cp $ff32 image/test/unit/image2jpg32x32-win.png
|
||||
cp $ff16 dom/canvas/test/crossorigin/image-allow-credentials.png
|
||||
cp $ff16 dom/html/test/image-allow-credentials.png
|
||||
cp $ff16 dom/canvas/test/crossorigin/image-allow-star.png
|
||||
cp $ff16 toolkit/components/places/tests/favicons/expected-favicon-big32.jpg.png
|
||||
cp $ff16 toolkit/components/places/tests/favicons/expected-favicon-big64.png.png
|
||||
cp $jpglogo toolkit/components/places/tests/favicons/favicon-big32.jpg
|
||||
cp $ff64 toolkit/components/places/tests/favicons/favicon-big64.png
|
||||
cp $favicon image/test/unit/image4gif16x16bmp24bpp.ico
|
||||
cp $favicon image/test/unit/image4gif16x16bmp32bpp.ico
|
||||
cp $favicon image/test/unit/image4gif32x32bmp24bpp.ico
|
||||
cp $favicon image/test/unit/image4gif32x32bmp32bpp.ico
|
||||
cp $jpglogo image/test/unit/image1png16x16.jpg
|
||||
cp $jpglogo image/test/unit/image2.jpg
|
||||
cp $jpglogo image/test/unit/image2jpg16x16cropped.jpg
|
||||
cp $jpglogo image/test/unit/image2jpg16x16cropped2.jpg
|
||||
cp $jpglogo image/test/unit/image2jpg16x32cropped3.jpg
|
||||
cp $jpglogo image/test/unit/image2jpg16x32scaled.jpg
|
||||
cp $jpglogo image/test/unit/image2jpg32x16cropped4.jpg
|
||||
cp $jpglogo image/test/unit/image2jpg32x16scaled.jpg
|
||||
cp $jpglogo image/test/unit/image2jpg32x32.jpg
|
||||
cp $ff32 image/test/unit/image2jpg32x32.png
|
||||
cp $ff32 image/test/unit/image2jpg32x32-win.png
|
||||
|
||||
###############################################################################
|
||||
# Mobile
|
||||
###############################################################################
|
||||
|
||||
echo "-dontwarn android.support.**" >> mobile/android/config/proguard/proguard.cfg
|
||||
echo "-dontwarn android.support.**" >> mobile/android/config/proguard/strip-libs.cfg
|
||||
|
||||
cat << EOF >> mobile/android/confvars.sh
|
||||
# IceCat settings
|
||||
MOZ_APP_VENDOR=GNU
|
||||
MOZ_APP_VERSION=$FFVERSION
|
||||
MOZ_PAY=0
|
||||
MOZ_SERVICES_HEALTHREPORT=0
|
||||
MOZ_SERVICES_HEALTHREPORTER=0
|
||||
MOZ_SERVICES_FXACCOUNTS=0
|
||||
MOZ_SERVICES_METRICS=0
|
||||
MOZ_DATA_REPORTING=0
|
||||
MOZ_SERVICES_SYNC=0
|
||||
MOZ_DEVICES=0
|
||||
MOZ_ANDROID_GOOGLE_PLAY_SERVICES=0
|
||||
MOZ_ADDON_SIGNING=0
|
||||
EOF
|
||||
|
||||
rm -R mobile/android/gradle/
|
||||
sed -i '/gradle/d' mobile/android/base/Makefile.in
|
||||
|
||||
cat $DATA/settings.js >> mobile/android/app/mobile.js
|
||||
cat $DATA/settings-android.js >> mobile/android/app/mobile.js
|
||||
|
||||
cat << EOF > mobile/locales/en-US/chrome/region.properties
|
||||
browser.search.defaultenginename=DuckDuckGo
|
||||
browser.search.order.1=DuckDuckGo
|
||||
browser.search.order.2=Google
|
||||
browser.search.order.3=Yahoo
|
||||
EOF
|
||||
|
||||
cp $DATA/preferences_vendor.xml ./mobile/android/app/src/main/res/xml/preferences_vendor.xml
|
||||
|
||||
sed '/public static void checkAndNotifyPolicy/ s/{/{ if(true) return;/; /private static void notifyDataPolicy/ s/{/{ if(true) return;/ ' -i mobile/android/base/java/org/mozilla/gecko/DataReportingNotification.java
|
||||
|
||||
cp -a $DATA/android-images/core/* mobile/android/themes/core/images/
|
||||
cp -a $DATA/android-images/resources mobile/android/base
|
||||
|
||||
sed '/aboutDetails/,/div/d; /privacyURL/d' mobile/android/chrome/content/about.xhtml -i
|
||||
|
||||
sed '/SENDERID/d' -i mobile/android/app/mobile.js
|
||||
|
||||
cat $DATA/mobile.dupes >> mobile/android/installer/allowed-dupes.mn
|
||||
|
||||
###############################################################################
|
||||
# Macos packaging
|
||||
###############################################################################
|
||||
|
||||
cat << EOF > ./build/package/mac_osx/pkg-dmg
|
||||
#!/bin/sh
|
||||
set -e
|
||||
export LC_ALL=C
|
||||
|
||||
cd \$2
|
||||
DMGFILE=\$4
|
||||
|
||||
# We need group readability for some Macs to be able to handle /Applications
|
||||
# installation. Still unclear exactly why this is -- it is not dependent on
|
||||
# OSX version...
|
||||
find . -executable -exec chmod 750 {} \;
|
||||
find . ! -executable -exec chmod 640 {} \;
|
||||
|
||||
find . -type f | sed -e 's/^\.\///' | sort | xargs -i echo "{}={}" > /tmp/filelist.txt
|
||||
find . -type l | sed -e 's/^\.\///' | sort | xargs -i echo "{}={}" >> /tmp/filelist.txt
|
||||
|
||||
mkisofs -D -V "\$6" -no-pad -R -apple -o /tmp/icecat-uncompressed.dmg -path-list /tmp/filelist.txt -graft-points -gid 20 -dir-mode 0750 -new-dir-mode 0750
|
||||
|
||||
|
||||
dmg dmg /tmp/icecat-uncompressed.dmg \$4
|
||||
rm /tmp/icecat-uncompressed.dmg
|
||||
|
||||
find . -executable -exec chmod 755 {} \;
|
||||
find . ! -executable -exec chmod 644 {} \;
|
||||
find . -type d -exec chmod 755 {} \;
|
||||
EOF
|
||||
|
||||
###############################################################################
|
||||
# Extensions
|
||||
###############################################################################
|
||||
|
||||
# Disable search field at extensions panel
|
||||
#sed '/header-search/d; /search.placeholder/d' -i toolkit/mozapps/extensions/content/extensions.xul
|
||||
cat << EOF >> toolkit/mozapps/extensions/content/extensions.css
|
||||
#header-search {
|
||||
display:none;
|
||||
}
|
||||
EOF
|
||||
|
||||
# Add extensions to manifest
|
||||
for EXTENSION in $(ls $DATA/extensions/); do
|
||||
sed "/Browser Chrome Files/s%$%\n@BINPATH@/browser/extensions/$EXTENSION/*%" -i browser/installer/package-manifest.in
|
||||
sed "/Browser Chrome Files/s%$%\n@BINPATH@/extensions/$EXTENSION/*%" -i mobile/android/installer/package-manifest.in
|
||||
#echo "DIRS += ['$EXTENSION']" >> browser/app/profile/extensions/moz.build
|
||||
#touch browser/app/profile/extensions/$EXTENSION/moz.build
|
||||
done
|
||||
|
||||
cp $DATA/extensions/ extensions/gnu -a
|
||||
|
||||
cat << EOF >> browser/app/Makefile.in
|
||||
libs::
|
||||
cp -a \$(topsrcdir)/extensions/gnu/* \$(DIST)/bin/browser/extensions
|
||||
mkdir -p \$(DIST)/icecat/browser/extensions/
|
||||
cp -a \$(topsrcdir)/extensions/gnu/* \$(DIST)/icecat/browser/extensions/
|
||||
EOF
|
||||
|
||||
|
||||
cat << EOF >> mobile/android/app/Makefile.in
|
||||
libs::
|
||||
mkdir -p \$(DIST)/bin/distribution
|
||||
cp -a \$(topsrcdir)/extensions/gnu/ \$(DIST)/bin/distribution/extensions
|
||||
EOF
|
||||
|
||||
#sed '/^make-package-internal:/ s%$%\n\tcp $(topsrcdir)/extensions.gnu/* $(DIST)/icecat/browser/extensions -a%' -i toolkit/mozapps/installer/packager.mk
|
||||
|
||||
# Add extensions to allowed-dupes.mn
|
||||
cat << EOF >> ./browser/installer/allowed-dupes.mn
|
||||
# IceCat extras
|
||||
browser/chrome/browser/content/browser/aboutaccounts/images/fox.png
|
||||
EOF
|
||||
find extensions/gnu/ | sed s=extensions/gnu=browser/extensions= >> ./browser/installer/allowed-dupes.mn
|
||||
find extensions/gnu/ | sed s=extensions/gnu=distribution/extensions= >> mobile/android/installer/allowed-dupes.mn
|
||||
|
||||
# Onboarding
|
||||
|
||||
sed 's/.Ubuntu., //' -i browser/extensions/activity-stream/css/activity-stream*.css
|
||||
cp $DATA/onboarding/bootstrap.js browser/extensions/onboarding
|
||||
cp $DATA/onboarding/onboarding.js browser/extensions/onboarding/content
|
||||
cp $DATA/onboarding/onboarding.properties browser/extensions/onboarding/locales/en-US
|
||||
for locale in $(ls -1 $DATA/onboarding/locales/); do
|
||||
mkdir -p l10n/$locale/browser/extensions/onboarding || true
|
||||
cp $DATA/onboarding/locales/$locale/onboarding.properties l10n/$locale/browser/extensions/onboarding
|
||||
done
|
||||
|
||||
# Fix CVE-2009-4029
|
||||
sed 's/777/755/;' -i toolkit/crashreporter/google-breakpad/Makefile.in
|
||||
#(cd toolkit/crashreporter/google-breakpad; aclocal)
|
||||
#(cd toolkit/crashreporter/google-breakpad; automake)
|
||||
|
||||
# Fix CVE-2012-3386
|
||||
/bin/sed 's/chmod a+w/chmod u+w/' -i ./js/src/ctypes/libffi/Makefile.in ./toolkit/crashreporter/google-breakpad/Makefile.in ./toolkit/crashreporter/google-breakpad/src/third_party/glog/Makefile.in || true
|
||||
|
||||
cd ..
|
||||
echo Packaging tarball
|
||||
tar cfj icecat-$ICECATVERSION.tar.bz2 $SOURCEDIR
|
||||
|
|
@ -1,6 +1,36 @@
|
|||
--- a/makeicecat 2019-05-13 13:13:15.000000000 +0200
|
||||
+++ b/makeicecat 2019-05-13 13:12:41.338936305 +0200
|
||||
@@ -449,87 +449,6 @@
|
||||
+++ b/makeicecat 2019-05-13 13:20:40.551626940 +0200
|
||||
@@ -264,9 +264,6 @@
|
||||
###############################################################################
|
||||
|
||||
# Replace Firefox branding
|
||||
-find -type d | grep fennec | xargs prename s/fennec/icecatmobile/
|
||||
-find -type f | grep fennec | xargs prename s/fennec/icecatmobile/
|
||||
-find -type f | grep Fennec | xargs prename s/Fennec/IceCatMobile/
|
||||
find -type d | grep firefox | xargs prename -f s/firefox/icecat/
|
||||
find -type f | grep firefox | xargs prename -f s/firefox/icecat/
|
||||
find -type f | grep Firefox | xargs prename -f s/Firefox/IceCat/
|
||||
@@ -289,11 +286,8 @@
|
||||
|
||||
s/Mozilla Firefox/GNU IceCat/g;
|
||||
s/firefox/icecat/g;
|
||||
-s/fennec/icecatmobile/g;
|
||||
s/Firefox/IceCat/g;
|
||||
-s/Fennec/IceCatMobile/g;
|
||||
s/FIREFOX/ICECAT/g;
|
||||
-s/FENNEC/ICECATMOBILE/g;
|
||||
s/ Mozilla / GNU /g;
|
||||
|
||||
s|PACKAGES/icecat|PACKAGES/firefox|g;
|
||||
@@ -378,7 +372,6 @@
|
||||
MOZ_DATA_REPORTING=0
|
||||
MOZ_SERVICES_SYNC=0
|
||||
MOZ_DEVICES=0
|
||||
-MOZ_ANDROID_GOOGLE_PLAY_SERVICES=0
|
||||
MOZ_ADDON_SIGNING=0
|
||||
EOF
|
||||
|
||||
@@ -449,87 +442,6 @@
|
||||
cp $ff32 image/test/unit/image2jpg32x32-win.png
|
||||
|
||||
###############################################################################
|
||||
|
|
@ -88,7 +118,7 @@
|
|||
# Extensions
|
||||
###############################################################################
|
||||
|
||||
@@ -594,6 +513,3 @@
|
||||
@@ -594,6 +506,3 @@
|
||||
# Fix CVE-2012-3386
|
||||
/bin/sed 's/chmod a+w/chmod u+w/' -i ./js/src/ctypes/libffi/Makefile.in ./toolkit/crashreporter/google-breakpad/Makefile.in ./toolkit/crashreporter/google-breakpad/src/third_party/glog/Makefile.in || true
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue