summaryrefslogtreecommitdiff
path: root/gnu/packages/patches/qtwebengine-fix-system-libvpx.patch
diff options
context:
space:
mode:
Diffstat (limited to 'gnu/packages/patches/qtwebengine-fix-system-libvpx.patch')
-rw-r--r--gnu/packages/patches/qtwebengine-fix-system-libvpx.patch58
1 files changed, 58 insertions, 0 deletions
diff --git a/gnu/packages/patches/qtwebengine-fix-system-libvpx.patch b/gnu/packages/patches/qtwebengine-fix-system-libvpx.patch
new file mode 100644
index 0000000000..c102fee01e
--- /dev/null
+++ b/gnu/packages/patches/qtwebengine-fix-system-libvpx.patch
@@ -0,0 +1,58 @@
+From c4aa5cc8c87f301a7c3b208fb017468a88836d42 Mon Sep 17 00:00:00 2001
+From: Martin Negyokru <negyokru@inf.u-szeged.hu>
+Date: Fri, 17 Jan 2025 15:55:25 +0100
+Subject: [PATCH] Fix building with system libvpx
+
+Disable code path which depends on internal api.
+According to the upstream change it is only needed
+for logging. See https://crrev.com/c/chromium/src/+/5116580
+
+Fixes: QTBUG-129955
+Change-Id: I5f396fcd8b22402af71a9e557f9f2f7f177a8114
+Reviewed-on: https://codereview.qt-project.org/c/qt/qtwebengine-chromium/+/617894
+Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
+Reviewed-by: Moss Heim <moss.heim@qt.io>
+(cherry picked from commit 30e6fccd654e43b016637d25466b00d3897da0f9)
+Reviewed-on: https://codereview.qt-project.org/c/qt/qtwebengine-chromium/+/621129
+Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
+---
+
+diff --git a/src/3rdparty/chromium/media/base/libvpx_thread_wrapper.cc b/src/3rdparty/chromium/media/base/libvpx_thread_wrapper.cc
+index 5566c8e..4821c0c 100644
+--- a/src/3rdparty/chromium/media/base/libvpx_thread_wrapper.cc
++++ b/src/3rdparty/chromium/media/base/libvpx_thread_wrapper.cc
+@@ -5,11 +5,14 @@
+ #include "media/base/libvpx_thread_wrapper.h"
+
+ #include "media/base/codec_worker_impl.h"
++#if !BUILDFLAG(IS_QTWEBENGINE) || !defined(USE_SYSTEM_LIBVPX)
+ #include "third_party/libvpx/source/libvpx/vpx_util/vpx_thread.h"
++#endif
+
+ namespace media {
+
+ void InitLibVpxThreadWrapper() {
++#if !BUILDFLAG(IS_QTWEBENGINE) || !defined(USE_SYSTEM_LIBVPX)
+ const VPxWorkerInterface interface =
+ CodecWorkerImpl<VPxWorkerInterface, VPxWorkerImpl, VPxWorker,
+ VPxWorkerStatus, VPX_WORKER_STATUS_NOT_OK,
+@@ -17,6 +20,7 @@
+ VPX_WORKER_STATUS_WORKING>::GetCodecWorkerInterface();
+
+ CHECK(vpx_set_worker_interface(&interface));
++#endif
+ }
+
+ } // namespace media
+diff --git a/src/3rdparty/chromium/third_party/libvpx/BUILD.gn b/src/3rdparty/chromium/third_party/libvpx/BUILD.gn
+index 6aedb08..2933bf4 100644
+--- a/src/3rdparty/chromium/third_party/libvpx/BUILD.gn
++++ b/src/3rdparty/chromium/third_party/libvpx/BUILD.gn
+@@ -634,6 +634,7 @@
+ if (use_system_libvpx) {
+ pkg_config("system_libvpx") {
+ packages = [ "vpx" ]
++ defines = ["USE_SYSTEM_LIBVPX=true"]
+ }
+ }
+