制作QGLViewer会产生与QT相关的错误



我想安装libqglviewer,我从http://www.libqglviewer.com/download.html下载了ubuntu 10.04。根据手册,我必须做;

1)CD QGLVIEWER/

2)Qmake

3)制作

通过键入编译库几乎立即出错结束;但是

`c++ -c -pipe -Wall -W -Os -fPIC  -DQT_NO_DEBUG -DQT_THREAD_SUPPORT -DQT_SHARED -DQT_TABLET_SUPPORT -I/usr/share/qt3/mkspecs/macx-g++ -I. -I/usr/include/qt3 -I/System/Library/Frameworks/OpenGL.framework/Headers -I/System/Library/Frameworks/AGL.framework/Headers/ -I.moc/ -o .obj/qglviewer.o qglviewer.cpp
In file included from domUtils.h:23,
                 from qglviewer.cpp:23:
config.h:77:22: error: QGLWidget: No such file or directory
config.h:88:17: error: QList: No such file or directory
config.h:89:19: error: QVector: No such file or directory
In file included from qglviewer.cpp:23:
domUtils.h:25:23: error: QDomElement: No such file or directory
domUtils.h:26:19: error: QString: No such file or directory
domUtils.h:27:23: error: QStringList: No such file or directory
domUtils.h:28:18: error: QColor: No such file or directory
`

这持续了一段时间,以:

结束
`qglviewer.cpp:841: error: ‘height’ was not declared in this scope
qglviewer.cpp: At global scope:
qglviewer.cpp:864: error: variable or field ‘timerEvent’ declared void
qglviewer.cpp:864: error: ‘QTimerEvent’ was not declared in this scope
qglviewer.cpp:864: error: expected primary-expression before ‘)’ token
make: *** [.obj/qglviewer.o] Error 1
rcar@DUD3642RCAR:~/Downloads/libQGLViewer-2.5.1/QGLViewer$ 
`

我认为这是因为它找不到QT库。但是我已经使用http://qt-project.org/downloads的最新下载安装了QT 5.2。

难道是无法找到图书馆路径的Makefile吗?如果是这样,我该如何修补?

解决了它!我错过了QTCreator。sudo apt-get安装qtcreator我还需要对Ubuntu 12.04进行升级,因为在10.04上,此问题持续存在。

相关内容

  • 没有找到相关文章

最新更新