chore: Update alpha-build.sh script to handle xvfb-run not found and enable LTO only when not cross-compiling

This commit is contained in:
Mauro Balades
2024-07-19 22:01:55 +02:00
parent 16f7b06cec
commit 93ba4e0638
3 changed files with 13 additions and 8 deletions

View File

@@ -3,8 +3,9 @@ export ZEN_RELEASE=1
# Check if xfvb is installed
if ! command -v xvfb-run &> /dev/null
then
echo "xvfb-run could not be found, running without it"
pnpm build
echo "xvfb-run could not be found, running without it"
pnpm build
else
export DISPLAY=:2
xvfb-run -s "-screen 0 1920x1080x24 -nolisten local" pnpm build
fi

View File

@@ -61,9 +61,11 @@ if test "$ZEN_RELEASE"; then
ac_add_options --disable-profiling
ac_add_options --disable-rust-tests
export MOZ_LTO=full
ac_add_options MOZ_LTO=full
ac_add_options --enable-lto=full
if ! test "$ZEN_CROSS_COMPILING"; then
export MOZ_LTO=full
ac_add_options MOZ_LTO=full
ac_add_options --enable-lto=full
fi
mk_add_options MOZILLA_OFFICIAL=1
@@ -77,9 +79,6 @@ if test "$ZEN_RELEASE"; then
ac_add_options OPT_LEVEL="3"
export RUSTC_OPT_LEVEL="3"
ac_add_options RUSTC_OPT_LEVEL="3"
export MOZ_PGO=1
ac_add_options MOZ_PGO=1
fi
ac_add_options --enable-unverified-updates

View File

@@ -19,6 +19,11 @@ if ! test "$ZEN_CROSS_COMPILING"; then
export STRIP_FLAGS="--strip-debug --strip-unneeded"
fi
if test "$ZEN_RELEASE"; then
export MOZ_PGO=1
ac_add_options MOZ_PGO=1
fi
# Disable telemetry and tracking
mk_add_options MOZ_TELEMETRY_REPORTING=
mk_add_options MOZ_DATA_REPORTING=