From 6c4b3aa6f9c5506529f1037b3d65d2d86e6bcaee Mon Sep 17 00:00:00 2001 From: Mauro Balades Date: Thu, 1 Aug 2024 19:51:37 +0200 Subject: [PATCH] chore: Update build configurations to enable install strip and strip debug symbols --- configs/common/mozconfig | 7 ------- configs/linux/mozconfig | 11 +++++++++-- configs/macos/mozconfig | 4 ++++ 3 files changed, 13 insertions(+), 9 deletions(-) diff --git a/configs/common/mozconfig b/configs/common/mozconfig index 7f0e0fb32..951261840 100644 --- a/configs/common/mozconfig +++ b/configs/common/mozconfig @@ -33,13 +33,6 @@ if test "$ZEN_RELEASE"; then ac_add_options --disable-tests ac_add_options --disable-jprof - if ! test "$ZEN_CROSS_COMPILING"; then - # TODO: Should actually be "not on windows" - ac_add_options --enable-install-strip - ac_add_options --enable-strip - export STRIP_FLAGS="--strip-debug --strip-unneeded" - fi - ac_add_options --enable-rust-simd mk_add_options MOZ_PARALLEL_COMPILE=1 diff --git a/configs/linux/mozconfig b/configs/linux/mozconfig index 0093098b4..e43e0189e 100644 --- a/configs/linux/mozconfig +++ b/configs/linux/mozconfig @@ -8,13 +8,15 @@ else fi if test "$ZEN_RELEASE"; then - export MOZ_PGO=1 - ac_add_options MOZ_PGO=1 ac_add_options --disable-dmd ac_add_options --enable-linker=lld ac_add_options --disable-elf-hack + ac_add_options --enable-install-strip + ac_add_options --enable-strip + export STRIP_FLAGS="--strip-debug --strip-unneeded" + if [ -f /home/runner/.mozbuild/sccache/sccache ]; then mk_add_options 'export RUSTC_WRAPPER=/home/runner/.mozbuild/sccache/sccache' mk_add_options 'export CCACHE_CPP2=yes' @@ -26,6 +28,11 @@ fi if test "$SURFER_COMPAT" = "true"; then # Build for linux-i686 ac_add_options --target=i686-pc-linux +else + # Note: we dont do PGO for i686 because we need to figure out about: + # "libgtk-3.so.0: cannot open shared object file: No such file or directory" + export MOZ_PGO=1 + ac_add_options MOZ_PGO=1 fi # Build for linux-x86_64 diff --git a/configs/macos/mozconfig b/configs/macos/mozconfig index 47095d2ba..34e3b76ff 100644 --- a/configs/macos/mozconfig +++ b/configs/macos/mozconfig @@ -12,4 +12,8 @@ if test "$SURFER_COMPAT" = "true"; then ac_add_options --target=x86_64-apple-darwin else ac_add_options --target=aarch64-apple-darwin + + ac_add_options --enable-install-strip + ac_add_options --enable-strip + export STRIP_FLAGS="--strip-debug --strip-unneeded" fi