I'm building QtWebKit with Qt5 and OpenGLES2. There are two build errors : 1) In file included from /home/loic/src/webkit/Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLES.cpp:41:0: /home/loic/src/webkit/Source/WebCore/platform/graphics/OpenGLESShims.h:57:0: error: "GL_MAX_SAMPLES_EXT" redefined [-Werror] In file included from /home/loic/src/webkit/Source/WebCore/platform/graphics/opengl/Extensions3DOpenGLES.h:33:0, from /home/loic/src/webkit/Source/WebCore/platform/graphics/opengl/GraphicsContext3DOpenGLES.cpp:34: /home/loic/src/webkit/Source/ThirdParty/ANGLE/include/GLES2/gl2ext.h:335:0: note: this is the location of the previous definition 2) In file included from /home/loic/src/webkit/Source/WebCore/platform/graphics/surfaces/qt/GraphicsSurfaceGLX.cpp:31:0: /usr/include/GL/glext.h:7557:81: error: ‘GLclampd’ does not name a type /usr/include/GL/glext.h:7558:61: error: ‘GLclampd’ has not been declared /usr/include/GL/glext.h:7558:73: error: ‘GLclampd’ has not been declared ...
First error is due to a define added in r122586 : - in Source/WebCore/platform/Graphics/OpenGLESShims.h : #define GL_MAX_SAMPLES_EXT 0x8D57 - in Source/ThirdParty/ANGLE/include/GLES2/gl2ext.h : #define GL_MAX_SAMPLES_EXT 0x9135 Should the OpenGLESShims.h value be used only for Blackberry ? For the second error, GLX should only be used with OpenGL, we could modify features.prf : haveQt(5):linux-*:config_glx:!contains(QT_CONFIG, opengles2): DEFINES += HAVE_GLX=1
I wonder why GL_MAX_SAMPLES_EXT is in OpenGLESShims.h, as it's only used in GraphicsContext3DOpenGL.cpp, which is not used in OpenGLES2 configuration of QtWebKit and in Blackberry port.
Created attachment 157218 [details] Patch
Comment on attachment 157218 [details] Patch Clearing flags on attachment: 157218 Committed r125039: <http://trac.webkit.org/changeset/125039>
All reviewed patches have been landed. Closing bug.