[Qt-interest] Compilation Error While compiling with Third party API

Sajjad dosto.walla at gmail.com
Tue Feb 14 16:50:09 CET 2012


Hello forum,

I am trying to create UI for a third party API - H3D and while doing
it i am getting the following error:

/////////////////////////////////////////////////////////////////////////////
0-Source/HAPI/include -I/usr/X11R6/include -I. -I. -o H3DGLCanvas.o
H3DGLCanvas.cpp
In file included from /usr/local/include/H3D/H3DDisplayListObject.h:32,
                 from /usr/local/include/H3D/X3DAppearanceNode.h:33,
                 from /usr/local/include/H3D/Appearance.h:32,
                 from /usr/local/include/H3D/DefaultAppearance.h:33,
                 from /usr/local/include/H3D/H3DWindowNode.h:35,
                 from MyH3DCanvasWindow.h:4,
                 from H3DGLCanvas.cpp:3:
/usr/include/GL/glew.h:84:2: error: #error gl.h included before glew.h
/usr/include/GL/glew.h:87:2: error: #error glext.h included before glew.h
In file included from /usr/local/include/H3D/H3DDisplayListObject.h:32,
                 from /usr/local/include/H3D/X3DAppearanceNode.h:33,
                 from /usr/local/include/H3D/Appearance.h:32,
                 from /usr/local/include/H3D/DefaultAppearance.h:33,
                 from /usr/local/include/H3D/H3DWindowNode.h:35,
                 from MyH3DCanvasWindow.h:4,
                 from H3DGLCanvas.cpp:3:
/usr/include/GL/glew.h:8422: error: conflicting declaration ‘typedef
void (* PFNGLFRAGMENTLIGHTMODELFVSGIXPROC)(GLenum, GLfloat*)’
/usr/include/GL/glext.h:5570: error:
‘PFNGLFRAGMENTLIGHTMODELFVSGIXPROC’ has a previous declaration as
‘typedef void (* PFNGLFRAGMENTLIGHTMODELFVSGIXPROC)(GLenum, const
GLfloat*)’
/usr/include/GL/glew.h:8424: error: conflicting declaration ‘typedef
void (* PFNGLFRAGMENTLIGHTMODELIVSGIXPROC)(GLenum, GLint*)’
/usr/include/GL/glext.h:5572: error:
‘PFNGLFRAGMENTLIGHTMODELIVSGIXPROC’ has a previous declaration as
‘typedef void (* PFNGLFRAGMENTLIGHTMODELIVSGIXPROC)(GLenum, const
GLint*)’
/usr/include/GL/glew.h:8426: error: conflicting declaration ‘typedef
void (* PFNGLFRAGMENTLIGHTFVSGIXPROC)(GLenum, GLenum, GLfloat*)’
/usr/include/GL/glext.h:5566: error: ‘PFNGLFRAGMENTLIGHTFVSGIXPROC’
has a previous declaration as ‘typedef void (*
PFNGLFRAGMENTLIGHTFVSGIXPROC)(GLenum, GLenum, const GLfloat*)’
/usr/include/GL/glew.h:8428: error: conflicting declaration ‘typedef
void (* PFNGLFRAGMENTLIGHTIVSGIXPROC)(GLenum, GLenum, GLint*)’
/usr/include/GL/glext.h:5568: error: ‘PFNGLFRAGMENTLIGHTIVSGIXPROC’
has a previous declaration as ‘typedef void (*
PFNGLFRAGMENTLIGHTIVSGIXPROC)(GLenum, GLenum, const GLint*)’
/usr/include/GL/glew.h:8435: error: conflicting declaration ‘typedef
void (* PFNGLGETFRAGMENTMATERIALFVSGIXPROC)(GLenum, GLenum, const
GLfloat*)’
/usr/include/GL/glext.h:5579: error:
‘PFNGLGETFRAGMENTMATERIALFVSGIXPROC’ has a previous declaration as
‘typedef void (* PFNGLGETFRAGMENTMATERIALFVSGIXPROC)(GLenum, GLenum,
GLfloat*)’
/usr/include/GL/glew.h:8436: error: conflicting declaration ‘typedef
void (* PFNGLGETFRAGMENTMATERIALIVSGIXPROC)(GLenum, GLenum, const
GLint*)’
/usr/include/GL/glext.h:5580: error:
‘PFNGLGETFRAGMENTMATERIALIVSGIXPROC’ has a previous declaration as
‘typedef void (* PFNGLGETFRAGMENTMATERIALIVSGIXPROC)(GLenum, GLenum,
GLint*)’
/usr/include/GL/glew.h:9866: error:
‘PFNGLGETPIXELTRANSFORMPARAMETERFVEXTPROC’ does not name a type
/usr/include/GL/glew.h:9867: error:
‘PFNGLGETPIXELTRANSFORMPARAMETERIVEXTPROC’ does not name a type
H3DGLCanvas.cpp:8: warning: unused parameter ‘attribute_list’
H3DGLCanvas.cpp:17: warning: unused parameter ‘attribute_list’
H3DGLCanvas.cpp:34: warning: unused parameter ‘width’
H3DGLCanvas.cpp:34: warning: unused parameter ‘height’
make: *** [H3DGLCanvas.o] Error 1
sajjad at sajjad:~/Documents/X3D/H3DViewer$

/////////////////////////////////////////////////////////////////////////////

I have sub-classed the QGLWidget which contains the reference to the
another class that is the subclass of the third party class. It may be
clashing with the glew initialization.

Any idea to resolve this ?


Thanks
Sajjad



More information about the Qt-interest-old mailing list