]> git.pld-linux.org Git - packages/firefox.git/commitdiff
- parallel build for non-clang (from fc)
authorArkadiusz Miśkiewicz <arekm@maven.pl>
Sun, 26 Jan 2020 00:51:15 +0000 (01:51 +0100)
committerArkadiusz Miśkiewicz <arekm@maven.pl>
Sun, 26 Jan 2020 00:51:15 +0000 (01:51 +0100)
firefox.spec

index 2932e7f60f2f3544b8ade3e6189565a028fcc309..5a46da9e486558737addd4b0c61461a959ef92ff 100644 (file)
@@ -2127,7 +2127,16 @@ ac_add_options --with-system-zlib
 ac_add_options BINDGEN_CFLAGS="$(pkg-config nspr pixman-1 --cflags)"
 EOF
 
-%{!?with_clang:export MOZ_MAKE_FLAGS="-j1"}
+# On x86_64 architectures, Mozilla can build up to 4 jobs at once in parallel,
+# however builds tend to fail on other arches when building in parallel.
+RPM_BUILD_NR_THREADS=$(echo %{_smp_mflags} | cut -dj -f2)
+%ifarch %{x8864}
+[ -n "RPM_BUILD_NR_THREADS" -a "$RPM_BUILD_NR_THREADS" -gt 4 ] && RPM_BUILD_NR_THREADS=4
+%else
+RPM_BUILD_NR_THREADS=1
+%endif
+export MOZ_MAKE_FLAGS="-j${RPM_BUILD_NR_THREADS}"
+
 export MOZ_SERVICES_SYNC="1"
 %if %{with pgo}
 D=$(( RANDOM % (200 - 100 + 1 ) + 5 ))
This page took 0.316471 seconds and 4 git commands to generate.