[Buildroot] [git commit branch/2022.02.x] package/qt5/qt5webkit: backport upstream fix for GStreamer 1.19.x compatibility

Peter Korsgaard peter at korsgaard.com
Tue Aug 16 20:59:41 UTC 2022


commit: https://git.buildroot.net/buildroot/commit/?id=f3fc07e421a7bb479d2b872f87985b8f37ed931c
branch: https://git.buildroot.net/buildroot/commit/?id=refs/heads/2022.02.x

In GStreamer commit 0a657d6db5ba912b13092a907ea507638cd01cf9, merged
in Gstreamer 1.19.x, the GstAppSinkCallbacks structure was extended
with another field calle new_event. This requires an update in the
WebKit code, without which we have a build failure:

    platform/audio/gstreamer/AudioFileReaderGStreamer.cpp:234:5: error: braces around scalar initializer for type ‘gboolean (*)(GstAppSink*, gpointer) {aka int (*)(_GstAppSink*, void*)}’

There are no autobuilder failures, but the issue could be reproduced
using the following defconfig:

BR2_arm=y
BR2_cortex_a8=y
BR2_TOOLCHAIN_EXTERNAL=y
BR2_TOOLCHAIN_EXTERNAL_LINARO_ARM=y
BR2_PACKAGE_QT5=y
BR2_PACKAGE_QT5WEBKIT=y

Signed-off-by: Nicolas Carrier <nicolas.carrier at orolia.com>
[Thomas: find the actual upstream fix and use that, improve the
explanation about the issue in the commit message]
Signed-off-by: Thomas Petazzoni <thomas.petazzoni at bootlin.com>
(cherry picked from commit bb50b821702841fdc75bf8151555cd401f764f07)
Signed-off-by: Peter Korsgaard <peter at korsgaard.com>
---
 ...e-to-AppSinkCallbacks-struct-growth-https.patch | 39 ++++++++++++++++++++++
 1 file changed, 39 insertions(+)

diff --git a/package/qt5/qt5webkit/0006-Warnings-due-to-AppSinkCallbacks-struct-growth-https.patch b/package/qt5/qt5webkit/0006-Warnings-due-to-AppSinkCallbacks-struct-growth-https.patch
new file mode 100644
index 0000000000..610d99e35d
--- /dev/null
+++ b/package/qt5/qt5webkit/0006-Warnings-due-to-AppSinkCallbacks-struct-growth-https.patch
@@ -0,0 +1,39 @@
+From 53d5bbf4d597a2fcb26149fab3185a3db09529af Mon Sep 17 00:00:00 2001
+From: Philippe Normand <pnormand at igalia.com>
+Date: Fri, 23 Jul 2021 15:38:29 +0000
+Subject: [PATCH] Warnings due to AppSinkCallbacks struct growth
+ https://bugs.webkit.org/show_bug.cgi?id=228229
+
+Patch by Philippe Normand <pnormand at igalia.com> on 2021-07-23
+Reviewed by Xabier Rodriguez-Calvar.
+
+A new callback was added, for event notifications.
+
+Canonical link: https://commits.webkit.org/239911@main
+git-svn-id: https://svn.webkit.org/repository/webkit/trunk@280243268f45cc-cd09-0410-ab3c-d52691b4dbfc
+[Thomas: backported from upstream, only the part touching
+Source/WebCore/platform/audio/gstreamer/AudioFileReaderGStreamer.cpp
+as other parts are not relevant]
+Signed-off-by: Thomas Petazzoni <thomas.petazzoni at bootlin.com>
+---
+ .../platform/audio/gstreamer/AudioFileReaderGStreamer.cpp     | 4 ++++
+ 1 file changed, 4 insertions(+)
+
+diff --git a/Source/WebCore/platform/audio/gstreamer/AudioFileReaderGStreamer.cpp b/Source/WebCore/platform/audio/gstreamer/AudioFileReaderGStreamer.cpp
+index 2f24c0cf5..dd9d91cf3 100644
+--- a/Source/WebCore/platform/audio/gstreamer/AudioFileReaderGStreamer.cpp
++++ b/Source/WebCore/platform/audio/gstreamer/AudioFileReaderGStreamer.cpp
+@@ -230,6 +230,10 @@ void AudioFileReader::handleNewDeinterleavePad(GstPad* pad)
+         [](GstAppSink* sink, gpointer userData) -> GstFlowReturn {
+             return static_cast<AudioFileReader*>(userData)->handleSample(sink);
+         },
++#if GST_CHECK_VERSION(1, 19, 1)
++        // new_event
++        nullptr,
++#endif
+         { nullptr }
+     };
+     gst_app_sink_set_callbacks(GST_APP_SINK(sink), &callbacks, this, 0);
+-- 
+2.37.1
+



More information about the buildroot mailing list