From 79bcff3f012204c3f36705875bc025751b4e1e51 Mon Sep 17 00:00:00 2001 From: coolbean Date: Fri, 9 Sep 2022 06:34:26 +0200 Subject: [PATCH 1/3] add no gstreamer plugin dependency patch --- srcpkgs/webkit2gtk/patches/nogstbad.patch | 29 +++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 srcpkgs/webkit2gtk/patches/nogstbad.patch diff --git a/srcpkgs/webkit2gtk/patches/nogstbad.patch b/srcpkgs/webkit2gtk/patches/nogstbad.patch new file mode 100644 index 000000000000..d5a69ddba9e6 --- /dev/null +++ b/srcpkgs/webkit2gtk/patches/nogstbad.patch @@ -0,0 +1,29 @@ +From c9fa538715b7a40a24ed187d14995ee67a04b718 Mon Sep 17 00:00:00 2001 +From: coolbean +Date: Fri, 9 Sep 2022 05:22:55 +0200 +Subject: [PATCH] apply patch + +--- + .../graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp | 6 ++++++ + 1 file changed, 6 insertions(+) + +diff --git a/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp b/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp +index 3237520e..d612c10a 100644 +--- a/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp ++++ b/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp +@@ -3402,6 +3402,12 @@ GstElement* MediaPlayerPrivateGStreamer::createVideoSink() + + if (!m_player->isVideoPlayer()) { + m_videoSink = makeGStreamerElement("fakevideosink", nullptr); ++ if (!m_videoSink) { ++ GST_DEBUG_OBJECT(m_pipeline.get(), "Falling back to fakesink for video rendering"); ++ m_videoSink = gst_element_factory_make("fakesink", nullptr); ++ g_object_set(m_videoSink.get(), "sync", TRUE, nullptr); ++ } ++ + return m_videoSink.get(); + } + +-- +2.37.3 + From cecbeb50f76ea035f0b4044419822c291c53f5a7 Mon Sep 17 00:00:00 2001 From: coolbean Date: Fri, 9 Sep 2022 06:54:40 +0200 Subject: [PATCH 2/3] bump revision number --- srcpkgs/webkit2gtk/template | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/srcpkgs/webkit2gtk/template b/srcpkgs/webkit2gtk/template index e103f2ce06c8..3dd8e1255916 100644 --- a/srcpkgs/webkit2gtk/template +++ b/srcpkgs/webkit2gtk/template @@ -2,7 +2,7 @@ # ping q66 before touching this pkgname=webkit2gtk version=2.34.6 -revision=2 +revision=3 wrksrc="webkitgtk-${version}" build_style=cmake build_helper="gir" From d663daa69cc09ccd2cc15a68e18bfc3092c02417 Mon Sep 17 00:00:00 2001 From: coolbean Date: Fri, 9 Sep 2022 08:24:35 +0200 Subject: [PATCH 3/3] adding the actual full patch --- srcpkgs/webkit2gtk/patches/nogstbad.patch | 36 +++++++++++++++-------- 1 file changed, 24 insertions(+), 12 deletions(-) diff --git a/srcpkgs/webkit2gtk/patches/nogstbad.patch b/srcpkgs/webkit2gtk/patches/nogstbad.patch index d5a69ddba9e6..b0eeaf432788 100644 --- a/srcpkgs/webkit2gtk/patches/nogstbad.patch +++ b/srcpkgs/webkit2gtk/patches/nogstbad.patch @@ -1,12 +1,27 @@ -From c9fa538715b7a40a24ed187d14995ee67a04b718 Mon Sep 17 00:00:00 2001 -From: coolbean -Date: Fri, 9 Sep 2022 05:22:55 +0200 -Subject: [PATCH] apply patch - ---- - .../graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp | 6 ++++++ - 1 file changed, 6 insertions(+) - +diff --git a/Source/WebCore/platform/graphics/gstreamer/GStreamerCommon.cpp b/Source/WebCore/platform/graphics/gstreamer/GStreamerCommon.cpp +index abaa20d4..26c68ea9 100644 +--- a/Source/WebCore/platform/graphics/gstreamer/GStreamerCommon.cpp ++++ b/Source/WebCore/platform/graphics/gstreamer/GStreamerCommon.cpp +@@ -526,7 +526,8 @@ GstBuffer* gstBufferNewWrappedFast(void* data, size_t length) + GstElement* makeGStreamerElement(const char* factoryName, const char* name) + { + auto* element = gst_element_factory_make(factoryName, name); +- RELEASE_ASSERT_WITH_MESSAGE(element, "GStreamer element %s not found. Please install it", factoryName); ++ if (!element) ++ WTFLogAlways("GStreamer element %s not found. Please install it", factoryName); + return element; + } + +@@ -534,7 +535,8 @@ GstElement* makeGStreamerBin(const char* description, bool ghostUnlinkedPads) + { + GUniqueOutPtr error; + auto* bin = gst_parse_bin_from_description(description, ghostUnlinkedPads, &error.outPtr()); +- RELEASE_ASSERT_WITH_MESSAGE(bin, "Unable to create bin for description: \"%s\". Error: %s", description, error->message); ++ if (!bin) ++ WTFLogAlways("Unable to create bin for description: \"%s\". Error: %s", description, error->message); + return bin; + } + diff --git a/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp b/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp index 3237520e..d612c10a 100644 --- a/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp @@ -24,6 +39,3 @@ index 3237520e..d612c10a 100644 return m_videoSink.get(); } --- -2.37.3 -