firefox: clean up

This commit is contained in:
Dylan Araps 2019-10-06 03:04:01 +03:00
parent 047e48cf8b
commit cfe7929d9e
No known key found for this signature in database
GPG Key ID: 46D62DD9F1DE636E

View File

@ -4,7 +4,11 @@
# See: https://bugzilla.mozilla.org/show_bug.cgi?id=104642
(
cd autoconf2.13
./configure --prefix="$PWD/../autoconf" --program-suffix=-2.13
./configure \
--prefix="$PWD/../autoconf" \
--program-suffix=-2.13
make
make install
)
@ -16,24 +20,20 @@ export MOZ_NOSPAM=1
cd firefox
# Fix OOM errors.
cores=$(nproc)
printf '%s\n' "mk_add_options MOZ_MAKE_FLAGS=\"-j$cores -l$cores\"" >> mozconfig
for patch in *.patch; do
patch -p1 < "$patch"
done
./mach build
./mach -j "$(nproc)" -l "$(nproc)" build
DESTDIR="$1" ./mach install
rm -rf "$1/usr/include"
rm -rf "$1/usr/lib/firefox-devel"
rm -rf "$1/usr/share/idl"
rm -rf "$1/usr/lib/firefox/gtk2"
rm -f "$1/usr/lib/firefox/browser/features/fxmonitor@mozilla.org.xpi"
rm -f "$1/usr/lib/firefox/browser/features/screenshots@mozilla.org.xpi"
rm -f "$1/usr/lib/firefox/browser/features/webcompat-reporter@mozilla.org.xpi"
rm -f "$1/usr/lib/firefox/browser/features/webcompat@mozilla.org.xpi"
rm -f "$1/usr/lib/firefox/browser/features/fxmonitor@mozilla.org.xpi"
rm -f "$1/usr/lib/firefox/browser/features/screenshots@mozilla.org.xpi"
rm -f "$1/usr/lib/firefox/browser/features/webcompat-reporter@mozilla.org.xpi"
rm -f "$1/usr/lib/firefox/browser/features/webcompat@mozilla.org.xpi"
install -D vendor.js "$1/usr/lib/firefox/browser/defaults/preferences/vendor.js"