Kubuntu wily (dev) Kdenlive 15.04.2 On Ubuntu, QtOpenGL5 is build against OpenGLES on armhf but kdenlive only looks for OpenGL. As you can't use both at the same time the build fails: In file included from /usr/include/GL/gl.h:2055:0, from /usr/include/GL/glu.h:38, from ../../src/monitor/videoglwidget.cpp:26: /usr/include/GL/glext.h:468:19: error: conflicting declaration 'typedef ptrdiff_t GLsizeiptr' typedef ptrdiff_t GLsizeiptr; ^ In file included from /usr/include/arm-linux-gnueabihf/qt5/QtGui/qopengl.h:97:0, from /usr/include/arm-linux-gnueabihf/qt5/QtOpenGL/qgl.h:39, from /usr/include/arm-linux-gnueabihf/qt5/QtOpenGL/QGLWidget:1, from ../../src/monitor/videoglwidget.h:24, from ../../src/monitor/videoglwidget.cpp:21: /usr/include/GLES3/gl3.h:69:25: note: previous declaration as 'typedef khronos_ssize_t GLsizeiptr' typedef khronos_ssize_t GLsizeiptr; ^ In file included from /usr/include/GL/gl.h:2055:0, from /usr/include/GL/glu.h:38, from ../../src/monitor/videoglwidget.cpp:26: /usr/include/GL/glext.h:469:19: error: conflicting declaration 'typedef ptrdiff_t GLintptr' typedef ptrdiff_t GLintptr; ^ In file included from /usr/include/arm-linux-gnueabihf/qt5/QtGui/qopengl.h:97:0, from /usr/include/arm-linux-gnueabihf/qt5/QtOpenGL/qgl.h:39, from /usr/include/arm-linux-gnueabihf/qt5/QtOpenGL/QGLWidget:1, from ../../src/monitor/videoglwidget.h:24, from ../../src/monitor/videoglwidget.cpp:21: /usr/include/GLES3/gl3.h:70:26: note: previous declaration as 'typedef khronos_intptr_t GLintptr' typedef khronos_intptr_t GLintptr; Reproducible: Always Steps to Reproduce: Build on ubuntu armhf
Created attachment 93538 [details] build with OpenGLES on armhf cmake file taken from plasma-desktop
FWIW it might be worth sticking the finder into ECM at this point. apparently kinfocenter and plasma-desktop also have a copy. alternatively I think kwin gets away with not looking for GL at all by using libepoxy, so maybe that would be a worthwhile thing to look into. also this patch should go on reviewboard :P
This bug hit me with a different compiler error message on Gentoo amd64 architecture and qtgui (and everything else qt) built with the "gles2" USE flag. See https://bugs.gentoo.org/show_bug.cgi?id=558356 (kdenlive 15.08.0). It compiled fine after I removed the gles2 USE-flag and rebuilt Qt5.
Created attachment 94284 [details] kdenlive-15.08.0-fix-opengles.patch I adapted attachment #93538 [details] to apply to Kdenlive 15.08.0. However, as kripton mentioned in comment #3, this does not fix Gentoo-bug #558356.
Git commit 92a25020e706537aec4d3ec7cf1ab5282b159989 by Vincent Pinon, on behalf of Jonathan Riddell. Committed on 04/09/2015 at 20:53. Pushed by vpinon into branch 'Applications/15.08'. link with OpenGLES if Qt uses that REVIEW: 125002 Signed-off-by: Vincent Pinon <vpinon@kde.org> M +17 -1 src/CMakeLists.txt http://commits.kde.org/kdenlive/92a25020e706537aec4d3ec7cf1ab5282b159989
Git commit 146e66c534b7d10871b6abb6ff5d11b41f623e80 by Jonathan Riddell. Committed on 23/09/2015 at 12:24. Pushed by jriddell into branch 'Applications/15.08'. Add missing FindOpenGLES cmake file REVIEW: 125002 A +52 -0 cmake/modules/FindOpenGLES.cmake http://commits.kde.org/kdenlive/146e66c534b7d10871b6abb6ff5d11b41f623e80
Git commit 5c2e8538b680eca0067f156f63855dc449614fd6 by Jonathan Riddell. Committed on 23/09/2015 at 12:27. Pushed by jriddell into branch 'master'. Add missing FindOpenGLES cmake file REVIEW: 125002 A +52 -0 cmake/modules/FindOpenGLES.cmake http://commits.kde.org/kdenlive/5c2e8538b680eca0067f156f63855dc449614fd6
It still fails: https://bugs.gentoo.org/show_bug.cgi?id=558356#c18 (Also confirmed by Michael "kensington" Palimaka.)
Created attachment 95474 [details] build.log kdenlive-15.08.3 still fails with the same error. Please reopen. /var/tmp/portage/kde-apps/kdenlive-15.08.3/work/kdenlive-15.08.3/src/monitor/glwidget.cpp: In function ‘void uploadTextures(QOpenGLContext*, SharedFrame&, GLuint*)’: /var/tmp/portage/kde-apps/kdenlive-15.08.3/work/kdenlive-15.08.3/src/monitor/glwidget.cpp:315:22: error: ‘GL_UNPACK_ROW_LENGTH’ was not declared in this scope f->glPixelStorei(GL_UNPACK_ROW_LENGTH, width); ^ /var/tmp/portage/kde-apps/kdenlive-15.08.3/work/kdenlive-15.08.3/src/monitor/glwidget.cpp: In member function ‘void GLWidget::paintGL()’: /var/tmp/portage/kde-apps/kdenlive-15.08.3/work/kdenlive-15.08.3/src/monitor/glwidget.cpp:363:23: warning: unused variable ‘f’ [-Wunused-variable] QOpenGLFunctions* f = openglContext()->functions(); ^ /var/tmp/portage/kde-apps/kdenlive-15.08.3/work/kdenlive-15.08.3/src/monitor/glwidget.cpp: In destructor ‘virtual FrameRenderer::~FrameRenderer()’: /var/tmp/portage/kde-apps/kdenlive-15.08.3/work/kdenlive-15.08.3/src/monitor/glwidget.cpp:1168:12: warning: possible problem detected in invocation of delete operator: [-Wdelete-incomplete] delete m_gl32; ^ /var/tmp/portage/kde-apps/kdenlive-15.08.3/work/kdenlive-15.08.3/src/monitor/glwidget.cpp:1168:12: warning: invalid use of incomplete type ‘class QOpenGLFunctions_3_2_Core’ In file included from /var/tmp/portage/kde-apps/kdenlive-15.08.3/work/kdenlive-15.08.3/src/monitor/glwidget.cpp:29:0: /var/tmp/portage/kde-apps/kdenlive-15.08.3/work/kdenlive-15.08.3/src/monitor/glwidget.h:36:7: warning: forward declaration of ‘class QOpenGLFunctions_3_2_Core’ class QOpenGLFunctions_3_2_Core; ^ /var/tmp/portage/kde-apps/kdenlive-15.08.3/work/kdenlive-15.08.3/src/monitor/glwidget.cpp:1168:12: note: neither the destructor nor the class-specific operator delete will be called, even if they are declared when the class is defined delete m_gl32; ^ src/CMakeFiles/kdenlive.dir/build.make:3047: recipe for target 'src/CMakeFiles/kdenlive.dir/monitor/glwidget.cpp.o' failed
Created attachment 95494 [details] kdenlive-15.08.3-define-gl-unpack-row-length-if-missing.patch
Created attachment 95495 [details] kdenlive-15.08.3-only-delete-opengl-3.2-core-functions-on-windows.patch The last two patches fix all serious warnings in the glwidget.cpp file and make kdenlive-15.08.3 compile. GL_UNPACK_ROW_LENGTH is part of OpenGL ES 3.2 (https://www.khronos.org/registry/gles/specs/3.2/es_spec_3.2.pdf), but not of OpenGL ES 2.0 (https://www.khronos.org/registry/gles/specs/2.0/es_full_spec_2.0.25.pdf). This it is defined in different headers (gl3.h) in OpenGL ES 3.2 and as an extension with _EXT suffix (gl2ext.h) to OpenGL ES 2.0. I chose the route to fallback to the _EXT definition, in case the regular one is unavailable. The other patch fixes a warning about calling operator delete on QOpenGLFunctions_3_2_Core (its class definition is incomplete). It is only ever instantiated on Windows anyway, so I took the liberty to also guard the deletion with Q_OS_WIN. Please reopen.
Any chance of seeing the last patch bundled in the upstream code? This bug should be reopened because the build is still broken,
Git commit f9c12b96228ca397e59dc07ce8f7fbe4d70055c4 by Vincent Pinon, on behalf of Dennis Schridde. Committed on 11/12/2015 at 07:24. Pushed by vpinon into branch 'Applications/15.12'. Allow building on ubuntu armhf (OpenGL!=OpenGLES) applying: kdenlive-15.08.3-define-gl-unpack-row-length-if-missing.patch kdenlive-15.08.3-only-delete-opengl-3.2-core-functions-on-windows.patch The two patches fix all serious warnings in the glwidget.cpp file and make kdenlive-15.08.3 compile. GL_UNPACK_ROW_LENGTH is part of OpenGL ES 3.2, but not of OpenGL ES 2.0. This it is defined in different headers (gl3.h) in OpenGL ES 3.2 and as an extension with _EXT suffix (gl2ext.h) to OpenGL ES 2.0. I chose the route to fallback to the _EXT definition, in case the regular one is unavailable. The other patch fixes a warning about calling operator delete on QOpenGLFunctions_3_2_Core (its class definition is incomplete). It is only ever instantiated on Windows anyway, so I took the liberty to also guard the deletion with Q_OS_WIN. M +11 -0 src/monitor/glwidget.cpp http://commits.kde.org/kdenlive/f9c12b96228ca397e59dc07ce8f7fbe4d70055c4
Many thanks for analyzing the problem, provinding the patch, and reminding me of it ;) Hope everything is fine now...