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>
|
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)
|
# upstream default is clang (to use gcc for large parts set to 0)
|
||||||
%define clang_build 0
|
%define clang_build 0
|
||||||
|
|
||||||
# PIE, full relro
|
|
||||||
%define build_hardened 1
|
|
||||||
|
|
||||||
%bcond_with only_print_mozconfig
|
%bcond_with only_print_mozconfig
|
||||||
|
|
||||||
# define if ccache should be used or not
|
# define if ccache should be used or not
|
||||||
%define useccache 1
|
%define useccache 0
|
||||||
|
|
||||||
# SLE-12 doesn't have this macro
|
# SLE-12 doesn't have this macro
|
||||||
%{!?_rpmmacrodir: %global _rpmmacrodir %{_rpmconfigdir}/macros.d}
|
%{!?_rpmmacrodir: %global _rpmmacrodir %{_rpmconfigdir}/macros.d}
|
||||||
@ -326,32 +323,7 @@ fi
|
|||||||
%setup -q -n %{srcname}-%{orig_version}
|
%setup -q -n %{srcname}-%{orig_version}
|
||||||
%endif
|
%endif
|
||||||
cd $RPM_BUILD_DIR/%{srcname}-%{orig_version}
|
cd $RPM_BUILD_DIR/%{srcname}-%{orig_version}
|
||||||
%patch1 -p1
|
%autopatch -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
|
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%build
|
%build
|
||||||
@ -410,9 +382,7 @@ export CFLAGS="$CFLAGS -fimplicit-constexpr"
|
|||||||
# Limit RAM usage during link
|
# Limit RAM usage during link
|
||||||
export LDFLAGS="${LDFLAGS} -Wl,--no-keep-memory -Wl,--reduce-memory-overheads"
|
export LDFLAGS="${LDFLAGS} -Wl,--no-keep-memory -Wl,--reduce-memory-overheads"
|
||||||
%endif
|
%endif
|
||||||
%if 0%{?build_hardened}
|
|
||||||
export LDFLAGS="${LDFLAGS} -fPIC -Wl,-z,relro,-z,now"
|
export LDFLAGS="${LDFLAGS} -fPIC -Wl,-z,relro,-z,now"
|
||||||
%endif
|
|
||||||
%ifarch ppc64 ppc64le
|
%ifarch ppc64 ppc64le
|
||||||
%if 0%{?clang_build} == 0
|
%if 0%{?clang_build} == 0
|
||||||
export CFLAGS="$CFLAGS -mminimal-toc"
|
export CFLAGS="$CFLAGS -mminimal-toc"
|
||||||
@ -438,8 +408,8 @@ echo "export MOZ_TELEMETRY_REPORTING=1"
|
|||||||
echo ""
|
echo ""
|
||||||
cat << EOF
|
cat << EOF
|
||||||
%else
|
%else
|
||||||
%ifarch aarch64 %arm ppc64 ppc64le
|
%ifarch aarch64 ppc64 ppc64le x86_64
|
||||||
%limit_build -m 2000
|
%limit_build -m 2048
|
||||||
%endif
|
%endif
|
||||||
cat << EOF > $MOZCONFIG
|
cat << EOF > $MOZCONFIG
|
||||||
%endif
|
%endif
|
||||||
@ -462,7 +432,8 @@ ac_add_options --enable-default-toolkit=cairo-gtk3
|
|||||||
%ifarch %ix86 %arm
|
%ifarch %ix86 %arm
|
||||||
ac_add_options --disable-debug-symbols
|
ac_add_options --disable-debug-symbols
|
||||||
%else
|
%else
|
||||||
ac_add_options --enable-debug-symbols
|
ac_add_options --enable-debug-symbols=-g1
|
||||||
|
ac_add_options --disable-install-strip
|
||||||
%endif
|
%endif
|
||||||
# building with elf-hack started to fail everywhere with FF73
|
# building with elf-hack started to fail everywhere with FF73
|
||||||
#%if 0%{?suse_version} > 1549
|
#%if 0%{?suse_version} > 1549
|
||||||
@ -485,7 +456,6 @@ ac_add_options --disable-updater
|
|||||||
ac_add_options --disable-tests
|
ac_add_options --disable-tests
|
||||||
ac_add_options --enable-alsa
|
ac_add_options --enable-alsa
|
||||||
ac_add_options --disable-debug
|
ac_add_options --disable-debug
|
||||||
#ac_add_options --enable-chrome-format=jar
|
|
||||||
ac_add_options --enable-update-channel=%{update_channel}
|
ac_add_options --enable-update-channel=%{update_channel}
|
||||||
ac_add_options --with-mozilla-api-keyfile=%{SOURCE18}
|
ac_add_options --with-mozilla-api-keyfile=%{SOURCE18}
|
||||||
# Google-service currently not available for free anymore
|
# 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
|
ac_add_options --allow-addon-sideload
|
||||||
# at least temporary until the "wasi-sysroot" issue is solved
|
# at least temporary until the "wasi-sysroot" issue is solved
|
||||||
ac_add_options --without-wasm-sandboxed-libraries
|
ac_add_options --without-wasm-sandboxed-libraries
|
||||||
|
%ifarch x86_64 aarch64
|
||||||
|
ac_add_options --enable-rust-simd
|
||||||
|
%endif
|
||||||
%if %branding
|
%if %branding
|
||||||
ac_add_options --enable-official-branding
|
ac_add_options --enable-official-branding
|
||||||
%endif
|
%endif
|
||||||
|
60
_constraints
60
_constraints
@ -1,15 +1,16 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
<constraints>
|
<constraints>
|
||||||
<hardware>
|
<hardware>
|
||||||
|
<jobs>4</jobs>
|
||||||
<disk>
|
<disk>
|
||||||
<size unit="G">36</size>
|
<size unit="G">24</size>
|
||||||
</disk>
|
</disk>
|
||||||
<memory>
|
<physicalmemory>
|
||||||
<size unit="G">8</size>
|
<size unit="G">8</size>
|
||||||
</memory>
|
</physicalmemory>
|
||||||
<memoryperjob>
|
<memoryperjob>
|
||||||
<size unit="M">2000</size>
|
<size unit="M">1536</size>
|
||||||
</memoryperjob>
|
</memoryperjob>
|
||||||
</hardware>
|
</hardware>
|
||||||
<overwrite>
|
<overwrite>
|
||||||
<conditions>
|
<conditions>
|
||||||
@ -17,9 +18,6 @@
|
|||||||
<arch>armv7l</arch>
|
<arch>armv7l</arch>
|
||||||
</conditions>
|
</conditions>
|
||||||
<hardware>
|
<hardware>
|
||||||
<memoryperjob>
|
|
||||||
<size unit="M">1000</size>
|
|
||||||
</memoryperjob>
|
|
||||||
<disk>
|
<disk>
|
||||||
<size unit="G">12</size>
|
<size unit="G">12</size>
|
||||||
</disk>
|
</disk>
|
||||||
@ -28,48 +26,4 @@
|
|||||||
</physicalmemory>
|
</physicalmemory>
|
||||||
</hardware>
|
</hardware>
|
||||||
</overwrite>
|
</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>
|
</constraints>
|
||||||
|
Loading…
Reference in New Issue
Block a user