diff --git a/MozillaFirefox.changes b/MozillaFirefox.changes index 8b84b60..d92ac10 100644 --- a/MozillaFirefox.changes +++ b/MozillaFirefox.changes @@ -24,6 +24,10 @@ Sun Oct 16 20:08:21 UTC 2022 - Wolfgang Rosenauer Username saved to a plaintext file on disk * CVE-2022-42932 (bmo#1789729, bmo#1791363, bmo#1792041) Memory safety bugs fixed in Firefox +- added -msse2 flag to fix i386 build and workaround bmo#1795993 +- fixed used buildflags +- renamed mozilla-i686-build.patch to mozilla-buildfixes.patch + as it was extended with changes for other archs ------------------------------------------------------------------- Sat Oct 8 13:41:12 UTC 2022 - Andreas Stieger diff --git a/MozillaFirefox.spec b/MozillaFirefox.spec index c98352a..1d01faf 100644 --- a/MozillaFirefox.spec +++ b/MozillaFirefox.spec @@ -54,8 +54,10 @@ %ifarch %ix86 ExclusiveArch: i586 i686 BuildArch: i686 -%{expand:%%global optflags %(echo "%optflags"|sed -e s/i586/i686/) -march=i686 -mtune=generic} +%{expand:%%global optflags %(echo "%optflags"|sed -e s/i586/i686/) -march=i686 -mtune=generic -msse2} %endif +%{expand:%%global optflags %(echo "%optflags"|sed -e s/-Werror=return-type//) } +%{expand:%%global optflags %(echo "%optflags"|sed -e s/-flto=auto//) } # general build definitions %define progname firefox @@ -224,7 +226,7 @@ Patch22: mozilla-silence-no-return-type.patch Patch23: mozilla-bmo531915.patch Patch25: one_swizzle_to_rule_them_all.patch Patch26: svg-rendering.patch -Patch27: mozilla-i686-build.patch +Patch27: mozilla-buildfixes.patch # Firefox/browser Patch101: firefox-kde.patch Patch102: firefox-branded-icons.patch @@ -362,15 +364,16 @@ echo "" > .obsenv.sh cat >> .obsenv.sh <= 12 -export CFLAGS="$CFLAGS -fimplicit-constexpr" +export CFLAGS="\$CFLAGS -fimplicit-constexpr" %endif %endif %endif %ifarch %arm %ix86 # 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" # A lie to prevent -Wl,--gc-sections being set which requires more memory than 32bit can offer export GC_SECTIONS_BREAKS_DEBUG_RANGES=yes %endif -export LDFLAGS="${LDFLAGS} -fPIC -Wl,-z,relro,-z,now" +export LDFLAGS="\$LDFLAGS -fPIC -Wl,-z,relro,-z,now" %ifarch ppc64 ppc64le %if 0%{?clang_build} == 0 -export CFLAGS="$CFLAGS -mminimal-toc" +export CFLAGS="\$CFLAGS -mminimal-toc" %endif %endif -export CXXFLAGS="$CFLAGS" +export CXXFLAGS="\$CFLAGS" export MOZCONFIG=$RPM_BUILD_DIR/mozconfig EOF # Done with env-variables. diff --git a/mozilla-i686-build.patch b/mozilla-buildfixes.patch similarity index 67% rename from mozilla-i686-build.patch rename to mozilla-buildfixes.patch index 7a56e00..d62995c 100644 --- a/mozilla-i686-build.patch +++ b/mozilla-buildfixes.patch @@ -1,6 +1,6 @@ # HG changeset patch # User Wolfgang Rosenauer -# Parent 63af48397aee6985bb8d711bd918a201e5c8c282 +# Parent 39a0846a4f2df1c4669273933d74567a8774e1da # References: bmo#1792159 - Add missing includes to AtomicOperationsGenerated.h diff --git a/js/src/jit/GenerateAtomicOperations.py b/js/src/jit/GenerateAtomicOperations.py @@ -25,6 +25,28 @@ diff --git a/js/src/jit/GenerateAtomicOperations.py b/js/src/jit/GenerateAtomicO } // namespace jit } // namespace js +diff --git a/media/ffvpx/config_unix_aarch64.h b/media/ffvpx/config_unix_aarch64.h +--- a/media/ffvpx/config_unix_aarch64.h ++++ b/media/ffvpx/config_unix_aarch64.h +@@ -324,17 +324,17 @@ + #define HAVE_SETCONSOLETEXTATTRIBUTE 0 + #define HAVE_SETCONSOLECTRLHANDLER 0 + #define HAVE_SETDLLDIRECTORY 0 + #define HAVE_SETMODE 0 + #define HAVE_SETRLIMIT 1 + #define HAVE_SLEEP 0 + #define HAVE_STRERROR_R 1 + #define HAVE_SYSCONF 1 +-#define HAVE_SYSCTL 1 ++#define HAVE_SYSCTL 0 + #define HAVE_USLEEP 1 + #define HAVE_UTGETOSTYPEFROMSTRING 0 + #define HAVE_VIRTUALALLOC 0 + #define HAVE_WGLGETPROCADDRESS 0 + #define HAVE_BCRYPT 0 + #define HAVE_VAAPI_DRM 0 + #define HAVE_VAAPI_X11 0 + #define HAVE_VDPAU_X11 0 diff --git a/mozglue/misc/SIMD_avx2.cpp b/mozglue/misc/SIMD_avx2.cpp --- a/mozglue/misc/SIMD_avx2.cpp +++ b/mozglue/misc/SIMD_avx2.cpp diff --git a/mozilla-silence-no-return-type.patch b/mozilla-silence-no-return-type.patch index 74dd62b..893fd16 100644 --- a/mozilla-silence-no-return-type.patch +++ b/mozilla-silence-no-return-type.patch @@ -1,5 +1,5 @@ # HG changeset patch -# Parent 96aba92106c841f0e722456e5b5f23c7fafbc04c +# Parent ccd8f974707cba440cffeb0c66b5bcc0cda73c63 diff --git a/Cargo.lock b/Cargo.lock --- a/Cargo.lock @@ -1982,6 +1982,28 @@ diff --git a/third_party/libwebrtc/api/rtp_parameters.cc b/third_party/libwebrtc RtcpFeedback::RtcpFeedback(RtcpFeedbackType type) : type(type) {} RtcpFeedback::RtcpFeedback(RtcpFeedbackType type, RtcpFeedbackMessageType message_type) +diff --git a/third_party/libwebrtc/api/video/video_frame_buffer.cc b/third_party/libwebrtc/api/video/video_frame_buffer.cc +--- a/third_party/libwebrtc/api/video/video_frame_buffer.cc ++++ b/third_party/libwebrtc/api/video/video_frame_buffer.cc +@@ -87,16 +87,18 @@ const char* VideoFrameBufferTypeToString + return "kI422"; + case VideoFrameBuffer::Type::kI010: + return "kI010"; + case VideoFrameBuffer::Type::kNV12: + return "kNV12"; + default: + RTC_DCHECK_NOTREACHED(); + } ++ RTC_DCHECK_NOTREACHED(); ++ return nullptr; + } + + int I420BufferInterface::ChromaWidth() const { + return (width() + 1) / 2; + } + + int I420BufferInterface::ChromaHeight() const { + return (height() + 1) / 2; diff --git a/third_party/libwebrtc/api/video_codecs/video_codec.cc b/third_party/libwebrtc/api/video_codecs/video_codec.cc --- a/third_party/libwebrtc/api/video_codecs/video_codec.cc +++ b/third_party/libwebrtc/api/video_codecs/video_codec.cc @@ -2160,6 +2182,44 @@ diff --git a/third_party/libwebrtc/call/video_send_stream.cc b/third_party/libwe VideoSendStream::StreamStats::~StreamStats() = default; std::string VideoSendStream::StreamStats::ToString() const { +diff --git a/third_party/libwebrtc/modules/audio_processing/agc/clipping_predictor.cc b/third_party/libwebrtc/modules/audio_processing/agc/clipping_predictor.cc +--- a/third_party/libwebrtc/modules/audio_processing/agc/clipping_predictor.cc ++++ b/third_party/libwebrtc/modules/audio_processing/agc/clipping_predictor.cc +@@ -373,11 +373,12 @@ std::unique_ptr Creat + /*adaptive_step_estimation=*/true); + case ClippingPredictorMode::kFixedStepClippingPeakPrediction: + return std::make_unique( + num_channels, config.window_length, config.reference_window_length, + config.reference_window_delay, config.clipping_threshold, + /*adaptive_step_estimation=*/false); + } + RTC_DCHECK_NOTREACHED(); ++ return nullptr; + } + + } // namespace webrtc +diff --git a/third_party/libwebrtc/modules/audio_processing/agc2/rnn_vad/rnn_fc.cc b/third_party/libwebrtc/modules/audio_processing/agc2/rnn_vad/rnn_fc.cc +--- a/third_party/libwebrtc/modules/audio_processing/agc2/rnn_vad/rnn_fc.cc ++++ b/third_party/libwebrtc/modules/audio_processing/agc2/rnn_vad/rnn_fc.cc +@@ -54,16 +54,18 @@ std::vector PreprocessWeights(rtc + rtc::FunctionView GetActivationFunction( + ActivationFunction activation_function) { + switch (activation_function) { + case ActivationFunction::kTansigApproximated: + return ::rnnoise::TansigApproximated; + case ActivationFunction::kSigmoidApproximated: + return ::rnnoise::SigmoidApproximated; + } ++ // supposed to be never reached apparently therefore returning bogus ++ return ::rnnoise::TansigApproximated; + } + + } // namespace + + FullyConnectedLayer::FullyConnectedLayer( + const int input_size, + const int output_size, + const rtc::ArrayView bias, diff --git a/third_party/libwebrtc/modules/audio_processing/audio_processing_impl.cc b/third_party/libwebrtc/modules/audio_processing/audio_processing_impl.cc --- a/third_party/libwebrtc/modules/audio_processing/audio_processing_impl.cc +++ b/third_party/libwebrtc/modules/audio_processing/audio_processing_impl.cc