Skip to content

Commit

Permalink
Merge r225051 - [WPE] GLContextEGLWPE.cpp:44:96: error: invalid cast …
Browse files Browse the repository at this point in the history
…from type ‘GLNativeWindowType {aka long long unsigned int}’ to type ‘EGLNativeWindowType {aka unsigned int}

https://bugs.webkit.org/show_bug.cgi?id=179511

Reviewed by Žan Doberšek.

r217208 changed the definition of GLNativeWindowType from EGLNativeWindowType to uint64_t for platform WPE.
This built fine on a 64-bit platform since uint64_t matches the size of a pointer, but fails on 32-bits.

This switches back the definition to EGLNativeWindowType.
And we need to include <EGL/eglplatform.h> first in order to get a definition for EGLNativeWindowType itself.

This commit pretty much reverts the changes r217208 did on platform/graphics/GLContext.h

No new tests, it is a build fix.

* platform/graphics/GLContext.h:
  • Loading branch information
clopez authored and carlosgcampos committed Dec 19, 2017
1 parent ff12cf4 commit ef690d0
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 2 deletions.
19 changes: 19 additions & 0 deletions Source/WebCore/ChangeLog
@@ -1,3 +1,22 @@
2017-11-20 Carlos Alberto Lopez Perez <clopez@igalia.com>

[WPE] GLContextEGLWPE.cpp:44:96: error: invalid cast from type ‘GLNativeWindowType {aka long long unsigned int}’ to type ‘EGLNativeWindowType {aka unsigned int}
https://bugs.webkit.org/show_bug.cgi?id=179511

Reviewed by Žan Doberšek.

r217208 changed the definition of GLNativeWindowType from EGLNativeWindowType to uint64_t for platform WPE.
This built fine on a 64-bit platform since uint64_t matches the size of a pointer, but fails on 32-bits.

This switches back the definition to EGLNativeWindowType.
And we need to include <EGL/eglplatform.h> first in order to get a definition for EGLNativeWindowType itself.

This commit pretty much reverts the changes r217208 did on platform/graphics/GLContext.h

No new tests, it is a build fix.

* platform/graphics/GLContext.h:

2017-11-11 Helmut Grohne <helmut@subdivi.de>

[GTK] PlatformGTK.cmake: use the PKG_CONFIG_EXECUTABLE variable
Expand Down
11 changes: 9 additions & 2 deletions Source/WebCore/platform/graphics/GLContext.h
Expand Up @@ -24,10 +24,17 @@
#include "PlatformDisplay.h"
#include <wtf/Noncopyable.h>

#if USE(EGL) && !PLATFORM(GTK) && !PLATFORM(WPE)
#if USE(EGL) && !PLATFORM(GTK)
#if PLATFORM(WPE)
// FIXME: For now default to the GBM EGL platform, but this should really be
// somehow deducible from the build configuration.
#define __GBM__ 1
#include <EGL/eglplatform.h>
#else
#include "eglplatform.h"
#endif // PLATFORM(WPE)
typedef EGLNativeWindowType GLNativeWindowType;
#else
#else // !USE(EGL) || PLATFORM(GTK)
typedef uint64_t GLNativeWindowType;
#endif

Expand Down

0 comments on commit ef690d0

Please sign in to comment.