summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libre/iceweasel/PKGBUILD22
1 files changed, 16 insertions, 6 deletions
diff --git a/libre/iceweasel/PKGBUILD b/libre/iceweasel/PKGBUILD
index 9ae5e7d04..55bcbc971 100644
--- a/libre/iceweasel/PKGBUILD
+++ b/libre/iceweasel/PKGBUILD
@@ -127,14 +127,24 @@ END
if [[ $CARCH = arm* ]]; then
sed -i '/--enable-linker=gold/d' .mozconfig
- cat >> .mozconfig <<- END
- ac_add_options --enable-optimize="-g -O2 -fno-schedule-insns"
- END
+ cat >> .mozconfig <<END
+ac_add_options --enable-optimize="-g -O2 -fno-schedule-insns"
+END
fi # end [[ $CARCH = arm* ]]
if [[ $CARCH = i686 ]]; then
+ msg "disabling LTO for i686 build (phase 1/2)"
+ cat >> .mozconfig <<END
+ac_add_options --disable-lto
+export CC=gcc
+export CXX=g++
+export AR=gcc-ar
+export NM=gcc-nm
+export RANLIB=gcc-ranlib
+END
sed -i '/--enable-linker=gold/d' .mozconfig
- fi # Because gold linker is alergic to some of the compile options set below to limit memory use.
+ sed -i '/export MOZ_PGO/d' .mozconfig
+ fi
## Rebranding
local brandingdir="$srcdir/$pkgname-$_brandingver"
@@ -190,10 +200,10 @@ build() {
export MOZBUILD_STATE_PATH="$srcdir/mozbuild"
if [[ $CARCH = i686 ]]; then
+ msg "disabling LTO for i686 build (phase 2/2)"
export RUSTFLAGS+=" -Cdebuginfo=0 -Clto=off"
export LDFLAGS+=" -Wl,--no-keep-memory -Wl,--reduce-memory-overheads"
- echo "Fixing x32 memory limits"
- fi #Fix Memory issue
+ fi
# LTO needs more open files
ulimit -n 4096