webkit gtk 2.2.3 stable tarball compilation error
authorzandobersek@gmail.com <zandobersek@gmail.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 23 Dec 2013 16:28:48 +0000 (16:28 +0000)
committerzandobersek@gmail.com <zandobersek@gmail.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 23 Dec 2013 16:28:48 +0000 (16:28 +0000)
https://bugs.webkit.org/show_bug.cgi?id=125987

Reviewed by Gustavo Noronha Silva.

Only try including <gdk/gdkwayland.h> and using GDK_IS_WAYLAND_DISPLAY if the Wayland support has been
enabled and when not compiling with GTK+ 2 (which occurs when building for libPlatformGtk2).

* platform/graphics/GLContext.cpp:
(WebCore::GLContext::createContextForWindow):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@160997 268f45cc-cd09-0410-ab3c-d52691b4dbfc

Source/WebCore/ChangeLog
Source/WebCore/platform/graphics/GLContext.cpp

index 0b5a2b5..7eeb792 100644 (file)
@@ -1,3 +1,16 @@
+2013-12-23  Zan Dobersek  <zdobersek@igalia.com>
+
+        webkit gtk 2.2.3 stable tarball compilation error
+        https://bugs.webkit.org/show_bug.cgi?id=125987
+
+        Reviewed by Gustavo Noronha Silva.
+
+        Only try including <gdk/gdkwayland.h> and using GDK_IS_WAYLAND_DISPLAY if the Wayland support has been
+        enabled and when not compiling with GTK+ 2 (which occurs when building for libPlatformGtk2).
+
+        * platform/graphics/GLContext.cpp:
+        (WebCore::GLContext::createContextForWindow):
+
 2013-12-23  Piotr Grad  <p.grad@samsung.com>
 
         [GStreamer] video/audio seeking is not unified.
index 0ede7ff..16993a1 100644 (file)
 
 #if PLATFORM(GTK)
 #include <gdk/gdk.h>
-#ifndef GTK_API_VERSION_2
-#ifdef GDK_WINDOWING_WAYLAND
+#if PLATFORM(WAYLAND) && !defined(GTK_API_VERSION_2) && defined(GDK_WINDOWING_WAYLAND)
 #include <gdk/gdkwayland.h>
 #endif
 #endif
-#endif
 
 using WTF::ThreadSpecific;
 
@@ -146,7 +144,7 @@ void GLContext::cleanupActiveContextsAtExit()
 
 PassOwnPtr<GLContext> GLContext::createContextForWindow(GLNativeWindowType windowHandle, GLContext* sharingContext)
 {
-#if PLATFORM(GTK) && defined(GDK_WINDOWING_WAYLAND) && USE(EGL)
+#if PLATFORM(GTK) && PLATFORM(WAYLAND) && !defined(GTK_API_VERSION_2) && defined(GDK_WINDOWING_WAYLAND) && USE(EGL)
     GdkDisplay* display = gdk_display_manager_get_default_display(gdk_display_manager_get());
 
     if (GDK_IS_WAYLAND_DISPLAY(display)) {