我在QGLviewer上遇到了一个问题(同样的问题,在linux和windows上都有)。
为了安装QGLviewer,我遵循了以下步骤http://www.libqglviewer.com/installWindows.html。
然后我尝试编译他们的示例项目,但失败了。我得到的是:
问题:
:-1: error: Use qmake LIB_DIR=/path/to/QGLViewer/libQGLViewerd2.a编译输出:
22:03:04: Running steps for project animation...
22:03:04: Starting: "C:\Qt\Qt5.4.1\5.4\mingw491_32\bin\qmake.exe" C:\Users\Bartek\Desktop\libQGLViewer-2.6.1\examples\animation\animation.pro -r -spec win32-g++
Project MESSAGE: Unable to find libQGLViewer2.a in C:\Windows\System32
Project ERROR: Use qmake LIB_DIR=/path/to/QGLViewer/libQGLViewer2.a
22:03:04: The process "C:\Qt\Qt5.4.1\5.4\mingw491_32\bin\qmake.exe" exited with code 3.
Error while building/deploying project animation (kit: Desktop Qt 5.4.1 MinGW 32bit)
When executing step "qmake"
22:03:04: Elapsed time: 00:00.即使我将生成的QGLViewer2.dll和QGLViewer2.a复制到C:\Windows\System32
你知道我该怎么做才能让它工作吗?
我使用的是QT Creator 3.3.1、QT 5.4.1
Windows 7 x64
谢谢你的任何建议!
发布于 2015-06-07 16:16:26
解决方案:
必须将以下行添加到*.pro文件中
LIB_DIR = C:\Qt\Libs这是你保存libQGLviewer文件的路径(所以libQGLviewer2.dll,libQGLviewer2.a,libQGLviewerd2.a)
希望能有所帮助。
https://stackoverflow.com/questions/30687070
复制相似问题