尝试从 Qt 5.1 构建示例程序,我得到这个运行时错误:
Starting /Users/pietro/myProgs/ParamGUI/build-6_treeview-Desktop_Qt_5_1_0_clang_64bit-Debug/mv_tree.app/Contents/MacOS/mv_tree...
dyld: Library not loaded: /Users/bld.qt/bamboo-agent-home/xml-data/build-dir/DQTC-LGPLRELEASEBUILD510-OSX106/______________________________PADDING______________________________/lib/QtWidgets.framework/Versions/5/QtWidgets
Referenced from: /Users/pietro/myProgs/ParamGUI/build-6_treeview-Desktop_Qt_5_1_0_clang_64bit-Debug/mv_tree.app/Contents/MacOS/mv_tree
Reason: image not found
The program has unexpectedly finished.
/Users/pietro/myProgs/ParamGUI/build-6_treeview-Desktop_Qt_5_1_0_clang_64bit-Debug/mv_tree.app/Contents/MacOS/mv_tree exited with code 0
使用调试器启动程序,在 main() 的第一条指令处有一个断点,我收到以下错误消息(相对于二进制代码位置):
The inferior stopped because it received a signal from the Operating System.
Signal name: SIGTRAP
Signal meaning: Trace/breakpoint trap
我不知道如何解决它。
该示例是从 Qt 文档创建树视图的简单示例。在我指定的 qmake 文件中:QT += widgets
该错误Reason: image not found
不是指位图图像,是吗?
我错了,还是很多人对 Qt5 有问题?
平台:Qt 5.1、Mac OS-X 10.7、QtCreator 2.7.2
--- 新测试 ---
在相同的环境中:
- “普通 C++ 项目(CMake 构建)”工作正常。
- “Qt 控制台应用程序”与此问题中提到的应用程序具有相同的问题。
--- 项目源代码 ---
轮廓:
QT += core
QT -= gui
TARGET = Qt5Test2
CONFIG += console
CONFIG -= app_bundle
TEMPLATE = app
SOURCES += main.cpp
main.cpp 文件:
#include <QCoreApplication>
int main(int argc, char *argv[])
{
QCoreApplication a(argc, argv);
return a.exec();
}