forked from pool/MozillaFirefox
Accepting request 951346 from home:dirkmueller:branches:mozilla:Factory
- disable ccache, this adds about 1 minute of build time and over 2 GB of disk space usage without benefit on OBS builds - build with rust-simd like upstream does - use -g1 for debuginfo generation as this is what upstream does as well and it saves ~ 2GB of writes - use %limit on x86_64 to scale down to less capable workers - disable install stripping so that debuginfo is useful - use autopatch - cleanup constraints to specify only jobs, physicalmemory and memoryperjob to be more flexible on which host to build on OBS-URL: https://build.opensuse.org/request/show/951346 OBS-URL: https://build.opensuse.org/package/show/mozilla:Factory/MozillaFirefox?expand=0&rev=956
This commit is contained in:
parent
f2fb960d33
commit
9162c87eb4
@ -1,3 +1,18 @@
|
||||
-------------------------------------------------------------------
|
||||
Sun Jan 30 23:58:34 UTC 2022 - Dirk Müller <dmueller@suse.com>
|
||||
|
||||
- disable ccache, this adds about 1 minute of build time and
|
||||
over 2 GB of disk space usage without benefit on OBS builds
|
||||
- build with rust-simd like upstream does
|
||||
- use -g1 for debuginfo generation as this is what upstream
|
||||
does as well and it saves ~ 2GB of writes
|
||||
- use %limit on x86_64 to scale down to less capable workers
|
||||
- disable install stripping so that debuginfo is useful
|
||||
- use autopatch
|
||||
- cleanup constraints to specify only jobs, physicalmemory
|
||||
and memoryperjob to be more flexible on which host to build
|
||||
on
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Jan 28 15:26:45 UTC 2022 - Wolfgang Rosenauer <wr@rosenauer.org>
|
||||
|
||||
|
@ -42,13 +42,10 @@
|
||||
# upstream default is clang (to use gcc for large parts set to 0)
|
||||
%define clang_build 0
|
||||
|
||||
# PIE, full relro
|
||||
%define build_hardened 1
|
||||
|
||||
%bcond_with only_print_mozconfig
|
||||
|
||||
# define if ccache should be used or not
|
||||
%define useccache 1
|
||||
%define useccache 0
|
||||
|
||||
# SLE-12 doesn't have this macro
|
||||
%{!?_rpmmacrodir: %global _rpmmacrodir %{_rpmconfigdir}/macros.d}
|
||||
@ -326,32 +323,7 @@ fi
|
||||
%setup -q -n %{srcname}-%{orig_version}
|
||||
%endif
|
||||
cd $RPM_BUILD_DIR/%{srcname}-%{orig_version}
|
||||
%patch1 -p1
|
||||
%patch2 -p1
|
||||
%patch3 -p1
|
||||
%patch4 -p1
|
||||
%patch5 -p1
|
||||
%patch6 -p1
|
||||
%patch7 -p1
|
||||
%patch8 -p1
|
||||
%patch9 -p1
|
||||
%patch10 -p1
|
||||
%patch11 -p1
|
||||
%patch12 -p1
|
||||
%patch13 -p1
|
||||
%patch14 -p1
|
||||
%patch15 -p1
|
||||
%patch16 -p1
|
||||
%patch17 -p1
|
||||
%patch18 -p1
|
||||
%patch19 -p1
|
||||
%patch20 -p1
|
||||
%patch21 -p1
|
||||
%patch22 -p1
|
||||
%patch23 -p1
|
||||
# Firefox
|
||||
%patch101 -p1
|
||||
%patch102 -p1
|
||||
%autopatch -p1
|
||||
%endif
|
||||
|
||||
%build
|
||||
@ -410,9 +382,7 @@ export CFLAGS="$CFLAGS -fimplicit-constexpr"
|
||||
# Limit RAM usage during link
|
||||
export LDFLAGS="${LDFLAGS} -Wl,--no-keep-memory -Wl,--reduce-memory-overheads"
|
||||
%endif
|
||||
%if 0%{?build_hardened}
|
||||
export LDFLAGS="${LDFLAGS} -fPIC -Wl,-z,relro,-z,now"
|
||||
%endif
|
||||
%ifarch ppc64 ppc64le
|
||||
%if 0%{?clang_build} == 0
|
||||
export CFLAGS="$CFLAGS -mminimal-toc"
|
||||
@ -438,8 +408,8 @@ echo "export MOZ_TELEMETRY_REPORTING=1"
|
||||
echo ""
|
||||
cat << EOF
|
||||
%else
|
||||
%ifarch aarch64 %arm ppc64 ppc64le
|
||||
%limit_build -m 2000
|
||||
%ifarch aarch64 ppc64 ppc64le x86_64
|
||||
%limit_build -m 2048
|
||||
%endif
|
||||
cat << EOF > $MOZCONFIG
|
||||
%endif
|
||||
@ -462,7 +432,8 @@ ac_add_options --enable-default-toolkit=cairo-gtk3
|
||||
%ifarch %ix86 %arm
|
||||
ac_add_options --disable-debug-symbols
|
||||
%else
|
||||
ac_add_options --enable-debug-symbols
|
||||
ac_add_options --enable-debug-symbols=-g1
|
||||
ac_add_options --disable-install-strip
|
||||
%endif
|
||||
# building with elf-hack started to fail everywhere with FF73
|
||||
#%if 0%{?suse_version} > 1549
|
||||
@ -485,7 +456,6 @@ ac_add_options --disable-updater
|
||||
ac_add_options --disable-tests
|
||||
ac_add_options --enable-alsa
|
||||
ac_add_options --disable-debug
|
||||
#ac_add_options --enable-chrome-format=jar
|
||||
ac_add_options --enable-update-channel=%{update_channel}
|
||||
ac_add_options --with-mozilla-api-keyfile=%{SOURCE18}
|
||||
# Google-service currently not available for free anymore
|
||||
@ -495,6 +465,9 @@ ac_add_options --with-unsigned-addon-scopes=app
|
||||
ac_add_options --allow-addon-sideload
|
||||
# at least temporary until the "wasi-sysroot" issue is solved
|
||||
ac_add_options --without-wasm-sandboxed-libraries
|
||||
%ifarch x86_64 aarch64
|
||||
ac_add_options --enable-rust-simd
|
||||
%endif
|
||||
%if %branding
|
||||
ac_add_options --enable-official-branding
|
||||
%endif
|
||||
|
60
_constraints
60
_constraints
@ -1,15 +1,16 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<constraints>
|
||||
<hardware>
|
||||
<jobs>4</jobs>
|
||||
<disk>
|
||||
<size unit="G">36</size>
|
||||
<size unit="G">24</size>
|
||||
</disk>
|
||||
<memory>
|
||||
<physicalmemory>
|
||||
<size unit="G">8</size>
|
||||
</memory>
|
||||
<memoryperjob>
|
||||
<size unit="M">2000</size>
|
||||
</memoryperjob>
|
||||
</physicalmemory>
|
||||
<memoryperjob>
|
||||
<size unit="M">1536</size>
|
||||
</memoryperjob>
|
||||
</hardware>
|
||||
<overwrite>
|
||||
<conditions>
|
||||
@ -17,9 +18,6 @@
|
||||
<arch>armv7l</arch>
|
||||
</conditions>
|
||||
<hardware>
|
||||
<memoryperjob>
|
||||
<size unit="M">1000</size>
|
||||
</memoryperjob>
|
||||
<disk>
|
||||
<size unit="G">12</size>
|
||||
</disk>
|
||||
@ -28,48 +26,4 @@
|
||||
</physicalmemory>
|
||||
</hardware>
|
||||
</overwrite>
|
||||
<overwrite>
|
||||
<conditions>
|
||||
<arch>aarch64</arch>
|
||||
</conditions>
|
||||
<hardware>
|
||||
<processors>4</processors>
|
||||
<disk>
|
||||
<size unit="G">36</size>
|
||||
</disk>
|
||||
<memoryperjob>
|
||||
<size unit="M">1000</size>
|
||||
</memoryperjob>
|
||||
<physicalmemory>
|
||||
<size unit="G">12</size>
|
||||
</physicalmemory>
|
||||
</hardware>
|
||||
</overwrite>
|
||||
<overwrite>
|
||||
<conditions>
|
||||
<arch>x86_64</arch>
|
||||
</conditions>
|
||||
<hardware>
|
||||
<memory>
|
||||
<size unit="G">18</size>
|
||||
</memory>
|
||||
</hardware>
|
||||
</overwrite>
|
||||
<overwrite>
|
||||
<conditions>
|
||||
<arch>ppc64</arch>
|
||||
<arch>ppc64le</arch>
|
||||
</conditions>
|
||||
<hardware>
|
||||
<disk>
|
||||
<size unit="G">36</size>
|
||||
</disk>
|
||||
<physicalmemory>
|
||||
<size unit="G">11</size>
|
||||
</physicalmemory>
|
||||
<memoryperjob>
|
||||
<size unit="M">2500</size>
|
||||
</memoryperjob>
|
||||
</hardware>
|
||||
</overwrite>
|
||||
</constraints>
|
||||
|
Loading…
Reference in New Issue
Block a user