Bug 196178 - Build failure with gstreamer 1.12.5 if USE_GSTREAMER_GL is enabled
Summary: Build failure with gstreamer 1.12.5 if USE_GSTREAMER_GL is enabled
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKitGTK (show other bugs)
Version: WebKit Local Build
Hardware: Unspecified Linux
: P2 Normal
Assignee: Philippe Normand
URL:
Keywords:
: 195800 (view as bug list)
Depends on: 196257
Blocks:
  Show dependency treegraph
 
Reported: 2019-03-23 08:57 PDT by Mike Gorse
Modified: 2019-05-21 13:08 PDT (History)
7 users (show)

See Also:


Attachments
Patch. (1.41 KB, patch)
2019-03-23 09:06 PDT, Mike Gorse
no flags Details | Formatted Diff | Diff
Patch (2.08 KB, patch)
2019-03-27 05:09 PDT, Philippe Normand
calvaris: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Mike Gorse 2019-03-23 08:57:18 PDT
I'm getting a build failure trying to build webkitgtk 2.24.0 on openSUSE Leap 15.0, similar to bug 159562:

In file included from ../Source/WebCore/platform/graphics/ANGLEWebKitBridge.h:56:0,
                 from ../Source/WebCore/platform/graphics/GraphicsContext3D.h:28,
                 from ../Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:32:
../Source/WebCore/platform/graphics/OpenGLShims.h:259:67: error: expected type-specifier before 'glActiveTexture'
 #define glActiveTexture                        LOOKUP_GL_FUNCTION(glActiveTexture)
followed by many other errors. It seems to be somehow related to the version of gstreamer-plugins-base installed; if I upgrade from 1.12.5 to 1.14.4, then I no longer get the errors.
Comment 1 Mike Gorse 2019-03-23 09:06:55 PDT
Created attachment 365815 [details]
Patch.
Comment 2 WebKit Commit Bot 2019-03-26 06:11:38 PDT
Comment on attachment 365815 [details]
Patch.

Clearing flags on attachment: 365815

Committed r243493: <https://trac.webkit.org/changeset/243493>
Comment 3 WebKit Commit Bot 2019-03-26 06:11:40 PDT
All reviewed patches have been landed.  Closing bug.
Comment 4 Philippe Normand 2019-03-26 06:18:22 PDT
*** Bug 195800 has been marked as a duplicate of this bug. ***
Comment 5 Philippe Normand 2019-03-26 09:23:24 PDT
Nice, this patch triggered another build error:

FAILED: Source/WebCore/CMakeFiles/WebCore.dir/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp.o 
/usr/lib/ccache/c++   -DBUILDING_GTK__=1 -DBUILDING_WEBKIT -DBUILDING_WITH_CMAKE=1 -DBUILDING_WebCore -DBWRAP_EXECUTABLE=\"/usr/bin/bwrap\" -DDBUS_PROXY_EXECUTABLE=\"/usr/bin/xdg-dbus-proxy\" -DGETTEXT_PACKAGE=\"WebKit2GTK-4.0\" -DHAVE_CONFIG_H=1 -DJSC_GLIB_API_ENABLED -DSTATICALLY_LINKED_WITH_PAL=1 -DWEBKITGTK_API_VERSION_STRING=\"4.0\" -I. -I../../Source/WebCore -I../../Source/WebCore/Modules/airplay -I../../Source/WebCore/Modules/applepay -I../../Source/WebCore/Modules/applepay/paymentrequest -I../../Source/WebCore/Modules/applicationmanifest -I../../Source/WebCore/Modules/beacon -I../../Source/WebCore/Modules/cache -I../../Source/WebCore/Modules/credentialmanagement -I../../Source/WebCore/Modules/encryptedmedia -I../../Source/WebCore/Modules/encryptedmedia/legacy -I../../Source/WebCore/Modules/entriesapi -I../../Source/WebCore/Modules/fetch -I../../Source/WebCore/Modules/geolocation -I../../Source/WebCore/Modules/indexeddb -I../../Source/WebCore/Modules/indexeddb/client -I../../Source/WebCore/Modules/indexeddb/server -I../../Source/WebCore/Modules/indexeddb/shared -I../../Source/WebCore/Modules/mediacapabilities -I../../Source/WebCore/Modules/mediacontrols -I../../Source/WebCore/Modules/mediarecorder -I../../Source/WebCore/Modules/mediasession -I../../Source/WebCore/Modules/mediasource -I../../Source/WebCore/Modules/mediastream -I../../Source/WebCore/Modules/mediastream/libwebrtc -I../../Source/WebCore/Modules/navigatorcontentutils -I../../Source/WebCore/Modules/notifications -I../../Source/WebCore/Modules/paymentrequest -I../../Source/WebCore/Modules/plugins -I../../Source/WebCore/Modules/quota -I../../Source/WebCore/Modules/speech -I../../Source/WebCore/Modules/streams -I../../Source/WebCore/Modules/webaudio -I../../Source/WebCore/Modules/webauthn -I../../Source/WebCore/Modules/webauthn/cbor -I../../Source/WebCore/Modules/webauthn/fido -I../../Source/WebCore/Modules/webdatabase -I../../Source/WebCore/Modules/webdriver -I../../Source/WebCore/Modules/webgpu -I../../Source/WebCore/Modules/websockets -I../../Source/WebCore/Modules/webvr -I../../Source/WebCore/accessibility -I../../Source/WebCore/accessibility/isolatedtree -I../../Source/WebCore/animation -I../../Source/WebCore/bindings -I../../Source/WebCore/bindings/js -I../../Source/WebCore/bridge -I../../Source/WebCore/bridge/c -I../../Source/WebCore/bridge/jsc -I../../Source/WebCore/contentextensions -I../../Source/WebCore/crypto -I../../Source/WebCore/crypto/algorithms -I../../Source/WebCore/crypto/keys -I../../Source/WebCore/crypto/parameters -I../../Source/WebCore/css -I../../Source/WebCore/css/parser -I../../Source/WebCore/css/typedom -I../../Source/WebCore/cssjit -I../../Source/WebCore/dom -I../../Source/WebCore/dom/messageports -I../../Source/WebCore/domjit -I../../Source/WebCore/editing -I../../Source/WebCore/fileapi -I../../Source/WebCore/history -I../../Source/WebCore/html -I../../Source/WebCore/html/canvas -I../../Source/WebCore/html/forms -I../../Source/WebCore/html/parser -I../../Source/WebCore/html/shadow -I../../Source/WebCore/html/track -I../../Source/WebCore/inspector -I../../Source/WebCore/inspector/agents -I../../Source/WebCore/inspector/agents/page -I../../Source/WebCore/inspector/agents/worker -I../../Source/WebCore/layout -I../../Source/WebCore/layout/blockformatting -I../../Source/WebCore/layout/displaytree -I../../Source/WebCore/layout/floats -I../../Source/WebCore/layout/inlineformatting -I../../Source/WebCore/layout/inlineformatting/text -I../../Source/WebCore/layout/layouttree -I../../Source/WebCore/loader -I../../Source/WebCore/loader/appcache -I../../Source/WebCore/loader/archive -I../../Source/WebCore/loader/archive/mhtml -I../../Source/WebCore/loader/cache -I../../Source/WebCore/loader/icon -I../../Source/WebCore/mathml -I../../Source/WebCore/page -I../../Source/WebCore/page/animation -I../../Source/WebCore/page/csp -I../../Source/WebCore/page/scrolling -I../../Source/WebCore/platform -I../../Source/WebCore/platform/animation -I../../Source/WebCore/platform/audio -I../../Source/WebCore/platform/encryptedmedia -I../../Source/WebCore/platform/gamepad -I../../Source/WebCore/platform/graphics -I../../Source/WebCore/platform/graphics/cpu/arm -I../../Source/WebCore/platform/graphics/cpu/arm/filters -I../../Source/WebCore/platform/graphics/displaylists -I../../Source/WebCore/platform/graphics/filters -I../../Source/WebCore/platform/graphics/iso -I../../Source/WebCore/platform/graphics/opentype -I../../Source/WebCore/platform/graphics/transforms -I../../Source/WebCore/platform/mediacapabilities -I../../Source/WebCore/platform/mediarecorder -I../../Source/WebCore/platform/mediasession -I../../Source/WebCore/platform/mediastream -I../../Source/WebCore/platform/mediastream/libwebrtc -I../../Source/WebCore/platform/mock -I../../Source/WebCore/platform/mock/mediasource -I../../Source/WebCore/platform/network -I../../Source/WebCore/platform/sql -I../../Source/WebCore/platform/text -I../../Source/WebCore/platform/vr -I../../Source/WebCore/plugins -I../../Source/WebCore/rendering -I../../Source/WebCore/rendering/line -I../../Source/WebCore/rendering/mathml -I../../Source/WebCore/rendering/shapes -I../../Source/WebCore/rendering/style -I../../Source/WebCore/rendering/svg -I../../Source/WebCore/rendering/updating -I../../Source/WebCore/replay -I../../Source/WebCore/storage -I../../Source/WebCore/style -I../../Source/WebCore/svg -I../../Source/WebCore/svg/animation -I../../Source/WebCore/svg/graphics -I../../Source/WebCore/svg/graphics/filters -I../../Source/WebCore/svg/properties -I../../Source/WebCore/websockets -I../../Source/WebCore/workers -I../../Source/WebCore/workers/service -I../../Source/WebCore/workers/service/context -I../../Source/WebCore/workers/service/server -I../../Source/WebCore/worklets -I../../Source/WebCore/xml -I../../Source/WebCore/xml/parser -IDerivedSources/WebCore -IDerivedSources/ForwardingHeaders/ANGLE -I../../Source/WebCore/platform/graphics/gpu -I../../Source/ThirdParty/xdgmime/src -I../../Source/WebCore/platform/graphics/cairo -I../../Source/WebCore/platform/graphics/freetype -I../../Source/WebCore/platform/graphics/harfbuzz -I../../Source/WebCore/platform/graphics/harfbuzz/ng -I../../Source/WebCore/platform/graphics/gstreamer -I../../Source/WebCore/platform/graphics/gstreamer/mse -I../../Source/WebCore/platform/graphics/gstreamer/eme -I../../Source/WebCore/platform/audio/gstreamer -I../../Source/WebCore/platform/image-decoders -I../../Source/WebCore/platform/image-decoders/bmp -I../../Source/WebCore/platform/image-decoders/gif -I../../Source/WebCore/platform/image-decoders/ico -I../../Source/WebCore/platform/image-decoders/jpeg -I../../Source/WebCore/platform/image-decoders/jpeg2000 -I../../Source/WebCore/platform/image-decoders/png -I../../Source/WebCore/platform/image-decoders/webp -I../../Source/WebCore/platform/graphics/texmap -I../../Source/WebCore/page/scrolling/nicosia -I../../Source/WebCore/platform/graphics/texmap/coordinated -I../../Source/WebCore/platform/graphics/nicosia -I../../Source/WebCore/platform/graphics/nicosia/cairo -I../../Source/WebCore/platform/graphics/nicosia/texmap -I../../Source/ThirdParty/ANGLE -I../../Source/ThirdParty/ANGLE/include/KHR -I../../Source/WebCore/accessibility/atk -I../../Source/WebCore/editing/atk -I../../Source/WebCore/page/gtk -I../../Source/WebCore/platform/generic -I../../Source/WebCore/platform/gtk -I../../Source/WebCore/platform/graphics/egl -I../../Source/WebCore/platform/graphics/glx -I../../Source/WebCore/platform/graphics/gtk -I../../Source/WebCore/platform/graphics/opengl -I../../Source/WebCore/platform/graphics/wayland -I../../Source/WebCore/platform/graphics/x11 -I../../Source/WebCore/platform/mediastream/gtk -I../../Source/WebCore/platform/mediastream/gstreamer -I../../Source/WebCore/platform/network/gtk -I../../Source/WebCore/platform/network/soup -I../../Source/WebCore/platform/text/gtk -I../../Source/WebCore/bindings/gobject -isystem /usr/include/libxml2 -isystem /usr/include/cairo -isystem /usr/include/freetype2 -isystem /usr/include/harfbuzz -isystem /usr/include/gstreamer-1.0 -isystem /usr/include/glib-2.0 -isystem /usr/lib/x86_64-linux-gnu/glib-2.0/include -isystem /usr/include/atk-1.0 -isystem /usr/include/enchant -isystem /usr/include/gio-unix-2.0 -isystem /usr/include/libsecret-1 -isystem /usr/include/libsoup-2.4 -IDerivedSources/ForwardingHeaders -I../../Source/bmalloc -IDerivedSources -I../../Source/ThirdParty -fdiagnostics-color=always -Wextra -Wall -Wno-attributes -Wno-psabi -Wno-maybe-uninitialized -Wwrite-strings -Wundef -Wpointer-arith -Wmissing-format-attribute -Wformat-security -Wcast-align  -fno-strict-aliasing -fno-exceptions -fno-rtti -std=c++14 -O3 -DNDEBUG -fPIC -MD -MT Source/WebCore/CMakeFiles/WebCore.dir/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp.o -MF Source/WebCore/CMakeFiles/WebCore.dir/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp.o.d -o Source/WebCore/CMakeFiles/WebCore.dir/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp.o -c /home/buildbot/webkitgtk/gtk-linux-64-release-debian/build/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp
/home/buildbot/webkitgtk/gtk-linux-64-release-debian/build/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp: In constructor ‘WebCore::GstVideoFrameHolder::GstVideoFrameHolder(GstSample*, WebCore::TextureMapperGL::Flags, bool)’:
/home/buildbot/webkitgtk/gtk-linux-64-release-debian/build/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:175:76: warning: unused parameter ‘flags’ [-Wunused-parameter]
     explicit GstVideoFrameHolder(GstSample* sample, TextureMapperGL::Flags flags, bool gstGLEnabled)
                                                                            ^~~~~
/home/buildbot/webkitgtk/gtk-linux-64-release-debian/build/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:175:88: warning: unused parameter ‘gstGLEnabled’ [-Wunused-parameter]
     explicit GstVideoFrameHolder(GstSample* sample, TextureMapperGL::Flags flags, bool gstGLEnabled)
                                                                                        ^~~~~~~~~~~~
/home/buildbot/webkitgtk/gtk-linux-64-release-debian/build/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp: In lambda function:
/home/buildbot/webkitgtk/gtk-linux-64-release-debian/build/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:738:136: error: incomplete type ‘WebCore::GraphicsContext3D’ used in nested name specifier
                 layerBuffer = std::make_unique<TextureMapperPlatformLayerBuffer>(textureID, frameHolder->size(), frameHolder->flags(), GraphicsContext3D::RGBA);
                                                                                                                                        ^~~~~~~~~~~~~~~~~


(gst-gl disabled on that bot)
Comment 6 Philippe Normand 2019-03-26 09:33:09 PDT
Can you try this?

diff --git a/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp b/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp
index 6d5c7384a2c..9ea5d81e64d 100644
--- a/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp
+++ b/Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp
@@ -85,7 +85,6 @@
 #include <gst/gl/gl.h>
 #undef GST_USE_UNSTABLE_API
 
-#include "GraphicsContext3D.h"
 #include "GLContext.h"
 #if USE(GLX)
 #include "GLContextGLX.h"
@@ -118,6 +117,7 @@
 #if USE(TEXTURE_MAPPER_GL)
 #include "BitmapTextureGL.h"
 #include "BitmapTexturePool.h"
+#include "GraphicsContext3D.h"
 #include "TextureMapperContextAttributes.h"
 #include "TextureMapperGL.h"
 #include "TextureMapperPlatformLayerBuffer.h"
@@ -192,6 +192,9 @@ public:
             if (m_isMapped)
                 m_textureID = *reinterpret_cast<GLuint*>(m_videoFrame.data[0]);
         } else
+#else
+        UNUSED_PARAM(gstGLEnabled);
+        UNUSED_PARAM(flags);
 #endif // USE(GSTREAMER_GL)
 
         {


Meanwhile I will rollout this patch because I can't test the build with GStreamer 1.12.
Comment 7 WebKit Commit Bot 2019-03-26 09:34:02 PDT
Re-opened since this is blocked by bug 196257
Comment 8 Mike Gorse 2019-03-26 10:21:08 PDT
(In reply to Philippe Normand from comment #6)
> Can you try this?

Thanks, Philippe. Builds for me. (My cmakeconfig.h has USE_TEXTURE_MAPPER_GL defined to 1)
Comment 9 Philippe Normand 2019-03-27 05:09:47 PDT
Created attachment 366066 [details]
Patch
Comment 10 Philippe Normand 2019-03-27 05:14:28 PDT
Committed r243538: <https://trac.webkit.org/changeset/243538>
Comment 11 Alberto Garcia 2019-05-17 07:50:27 PDT
This is happening again in 2.24.2:

In file included from Source/WebCore/platform/graphics/texmap/TextureMapperGLHeaders.h:34:0,
                 from Source/WebCore/platform/graphics/texmap/TextureMapperGL.h:31,
                 from Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.h:41,
                 from Source/WebCore/platform/graphics/gstreamer/MediaPlayerPrivateGStreamerBase.cpp:26:
Source/WebCore/platform/graphics/OpenGLShims.h:259:67: error: expected type-specifier before 'glActiveTexture'
 #define glActiveTexture                        LOOKUP_GL_FUNCTION(glActiveTexture)
                                                                   ^
I think the culprit is this commit:

https://trac.webkit.org/changeset/245119/webkit
Comment 12 Mike Gorse 2019-05-21 08:21:23 PDT
Yeah, I just tested trunk, and it is still happening there. Should we re-open this bug, or do we need to create a new one?
Comment 13 Alberto Garcia 2019-05-21 08:49:39 PDT
(In reply to Mike Gorse from comment #12)
> Yeah, I just tested trunk, and it is still happening there. Should we
> re-open this bug, or do we need to create a new one?

I would file a new bug. If you can do it please go ahead and put me in Cc. Else I'll try to do it later this week.
Comment 14 Mike Gorse 2019-05-21 13:08:30 PDT
https://bugs.webkit.org/show_bug.cgi?id=198080