From 35e6001e2e95ca941a5afd0ccc3d87e68dd1a673 Mon Sep 17 00:00:00 2001 From: Adam Williamson Date: Wed, 4 Oct 2023 10:47:03 -0700 Subject: [PATCH 1/3] Limit cores used for find-debuginfo (thanks kalev) As suggested by Kalev Lember: https://lists.fedoraproject.org/archives/list/devel@lists.fedoraproject.org/message/7CX676QRC2QVZATX34WTCF2GL26AAWCL/ try using %limit_build to use only one CPU core per 32G of RAM for find-debuginfo, to try and avoid builds failing due to lack of memory: https://bugzilla.redhat.com/show_bug.cgi?id=2241690 --- firefox.spec | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/firefox.spec b/firefox.spec index 9fa0894..b35deb4 100644 --- a/firefox.spec +++ b/firefox.spec @@ -450,7 +450,7 @@ and translations langpack add-ons. %global uname_m %(uname -m) %global symbols_file_name %{name}-%{version}.en-US.%{_os}-%{uname_m}.crashreporter-symbols.zip %global symbols_file_path %{moz_debug_dir}/%{symbols_file_name} -%global _find_debuginfo_opts -p %{symbols_file_path} -o debugcrashreporter.list +%global _find_debuginfo_opts %{limit_build -m 32768} -p %{symbols_file_path} -o debugcrashreporter.list %global crashreporter_pkg_name mozilla-crashreporter-%{name}-debuginfo %package -n %{crashreporter_pkg_name} Summary: Debugging symbols used by Mozilla's crash reporter servers From a5727f905469ce48416077e38a0fcdc02fa01817 Mon Sep 17 00:00:00 2001 From: Adam Williamson Date: Wed, 4 Oct 2023 17:26:43 -0700 Subject: [PATCH 2/3] Always apply the find-debuginfo opts from previous commit Whoops, missed that this was in a conditional. Signed-off-by: Adam Williamson --- firefox.spec | 2 ++ 1 file changed, 2 insertions(+) diff --git a/firefox.spec b/firefox.spec index b35deb4..761d241 100644 --- a/firefox.spec +++ b/firefox.spec @@ -459,6 +459,8 @@ This package provides debug information for Firefox, for use by Mozilla's crash reporter servers. If you are trying to locally debug %{name}, you want to install %{name}-debuginfo instead. %files -n %{crashreporter_pkg_name} -f debugcrashreporter.list +%else +%global _find_debuginfo_opts %{limit_build -m 32768} %endif %package x11 From 66f31e3216c790695cd7daa54b7f99d08984fb4c Mon Sep 17 00:00:00 2001 From: Kalev Lember Date: Thu, 5 Oct 2023 18:43:55 +0200 Subject: [PATCH 3/3] Fix flatpak build Don't assume libclang is going to be in the same prefix as firefox - in flatpak builds, libclang is in /usr and firefox is in /app. As a fix, use 'llvm-config --libdir' to find out the actual libclang path during the build. --- firefox.spec | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/firefox.spec b/firefox.spec index 761d241..309c3d5 100644 --- a/firefox.spec +++ b/firefox.spec @@ -169,7 +169,7 @@ ExcludeArch: i686 Summary: Mozilla Firefox Web browser Name: firefox Version: 118.0.1 -Release: 4%{?pre_tag}%{?dist} +Release: 5%{?pre_tag}%{?dist} URL: https://www.mozilla.org/firefox/ License: MPLv1.1 or GPLv2+ or LGPLv2+ Source0: https://archive.mozilla.org/pub/firefox/releases/%{version}%{?pre_version}/source/firefox-%{version}%{?pre_version}.source.tar.xz @@ -661,7 +661,7 @@ echo "ac_add_options --with-google-safebrowsing-api-keyfile=`pwd`/google-api-key # https://bugzilla.redhat.com/show_bug.cgi?id=2239046 # with clang 17 upstream's detection fails, so let's just tell it # where to look -echo "ac_add_options --with-libclang-path=%{_libdir}" >> .mozconfig +echo "ac_add_options --with-libclang-path=`llvm-config --libdir`" >> .mozconfig echo 'export NODEJS="%{_buildrootdir}/bin/node-stdout-nonblocking-wrapper"' >> .mozconfig @@ -1119,6 +1119,9 @@ fi #--------------------------------------------------------------------- %changelog +* Thu Oct 05 2023 Kalev Lember - 118.0.1-5 +- Fix flatpak build + * Mon Oct 2 2023 Martin Stransky - 118.0.1-4 - Updated man page