[packages/firefox52-esr] - fixed build with recent clang

qboosh qboosh at pld-linux.org
Sun Aug 25 12:12:33 CEST 2024


commit c30ac71978162336a2b87d9e716cf3e3bcaf369b
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Sun Aug 25 11:15:01 2024 +0200

    - fixed build with recent clang

 firefox-includes.patch | 23 +++++++++++++++++++++++
 firefox52-esr.spec     |  9 +++++++++
 2 files changed, 32 insertions(+)
---
diff --git a/firefox52-esr.spec b/firefox52-esr.spec
index 7cf1a81..95d68aa 100644
--- a/firefox52-esr.spec
+++ b/firefox52-esr.spec
@@ -52,6 +52,7 @@ Patch9:		%{srcname}-Disable-Firefox-Health-Report.patch
 Patch10:	%{srcname}-nss.patch
 Patch11:	xulrunner-pc.patch
 Patch12:	glibc.patch
+Patch13:	%{srcname}-includes.patch
 URL:		https://www.mozilla.org/firefox/
 BuildRequires:	OpenGL-devel
 BuildRequires:	alsa-lib-devel
@@ -236,6 +237,7 @@ echo 'LOCAL_INCLUDES += $(MOZ_HUNSPELL_CFLAGS)' >> extensions/spellcheck/src/Mak
 %patch10 -p1
 %patch11 -p1
 %patch12 -p1
+%patch13 -p1
 
 %{__sed} -i -e '1s,/usr/bin/env python,%{__python},' xpcom/typelib/xpt/tools/xpt.py xpcom/idl-parser/xpidl/xpidl.py
 
@@ -244,6 +246,13 @@ echo 'LOCAL_INCLUDES += $(MOZ_HUNSPELL_CFLAGS)' >> extensions/spellcheck/src/Mak
 %endif
 
 %build
+# autoconf2.13 wasn't fully C99-compliant, fails with recent clang - hack output files
+# (need to generate js/src/old-configure first)
+cd js/src
+autoconf2_13 --localdir . old-configure.in > old-configure
+cd ../..
+%{__sed} -i -e 's/^main()/int &/' old-configure js/src/old-configure
+
 cp -p %{_datadir}/automake/config.* build/autoconf
 
 cat << 'EOF' > .mozconfig
diff --git a/firefox-includes.patch b/firefox-includes.patch
new file mode 100644
index 0000000..1aa6306
--- /dev/null
+++ b/firefox-includes.patch
@@ -0,0 +1,23 @@
+--- firefox-52.9.0esr/gfx/2d/BaseRect.h.orig	2017-04-11 04:13:04.000000000 +0200
++++ firefox-52.9.0esr/gfx/2d/BaseRect.h	2024-08-24 19:58:34.282296752 +0200
+@@ -8,6 +8,8 @@
+ 
+ #include <algorithm>
+ #include <cmath>
++#include <cstdint>
++#include <limits>
+ #include <ostream>
+ 
+ #include "mozilla/Assertions.h"
+--- firefox-52.9.0esr/media/webrtc/trunk/webrtc/modules/audio_coding/codecs/opus/audio_encoder_opus.cc.orig	2017-04-11 04:13:15.000000000 +0200
++++ firefox-52.9.0esr/media/webrtc/trunk/webrtc/modules/audio_coding/codecs/opus/audio_encoder_opus.cc	2024-08-24 21:26:32.327036464 +0200
+@@ -8,6 +8,9 @@
+  *  be found in the AUTHORS file in the root of the source tree.
+  */
+ 
++#include <cstdint>
++#include <limits>
++
+ #include "webrtc/modules/audio_coding/codecs/opus/interface/audio_encoder_opus.h"
+ 
+ #include "webrtc/base/checks.h"
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/firefox52-esr.git/commitdiff/c30ac71978162336a2b87d9e716cf3e3bcaf369b



More information about the pld-cvs-commit mailing list