编译omnetpp-5.4.1时出现以下错误,我是否需要卸载libgles2-mesa-dev软件包?
在/usr/include/GL/gl.h:2055中包含的文件中:
/usr/include/GL/glext.h:469:19: error: typedef redefinition with different types ('ptrdiff_t' (aka 'int') vs 'khronos_intptr_t' (aka 'long')) typedef ptrdiff_t GLintptr; ^ /usr/include/GLES3/gl31.h:74:26: note: previous definition is here typedef khronos_intptr_t GLintptr; ^ In file included from osgviewer.cc:27: In file included from /usr/include/arm-linux-gnueabihf/qt5/QtGui/QOpenGLFunctions:1: /usr/include/arm-linux-gnueabihf/qt5/QtGui/qopenglfunctions.h:60:16: error: cannot combine with previous 'double' declaration specifier typedef double GLdouble; ^ /usr/include/osg/GL:129:38: note: expanded from macro 'GLdouble' #define GLdouble double ^ 3 errors generated.
答案 0 :(得分:0)
这似乎是系统头文件的问题。如果不需要OpenSceneGraph / osgEarth支持,则可以在configure.user
文件中将其关闭,然后重新配置/重建omnet。这将从构建过程中排除OSG特定文件。 (如果您不需要图形环境(Qtenv),甚至可以在configure.user
中将其关闭,这将避免也与Qt库链接)。