我剛剛下載了Qt 5.0的源代碼,並將其編譯到Ubuntu 12.10 64位上。運行sudo make install
似乎已經將文件複製到/usr/local/Qt-5.0.0
:如何讓Qt 5.0與Qt Creator 2.5.2一起工作?
到目前爲止好。但是當我啓動Qt Creator 2.5.2並嘗試將其指向新版本時,出現一個不尋常的錯誤:The default mkspec symlink is broken
。
什麼可能導致這種錯誤的? /usr/local/Qt-5.0.0/mkspecs
下的所有符號鏈接都是有效的。的qmake -query
輸出如下:
QT_SYSROOT: QT_INSTALL_PREFIX:/usr/local/Qt-5.0.0 QT_INSTALL_ARCHDATA:/usr/local/Qt-5.0.0 QT_INSTALL_DATA:/usr/local/Qt-5.0.0 QT_INSTALL_DOCS:/usr/local/Qt-5.0.0/doc QT_INSTALL_HEADERS:/usr/local/Qt-5.0.0/include QT_INSTALL_LIBS:/usr/local/Qt-5.0.0/lib QT_INSTALL_LIBEXECS:/usr/local/Qt-5.0.0/libexec QT_INSTALL_BINS:/usr/local/Qt-5.0.0/bin QT_INSTALL_TESTS:/usr/local/Qt-5.0.0/tests QT_INSTALL_PLUGINS:/usr/local/Qt-5.0.0/plugins QT_INSTALL_IMPORTS:/usr/local/Qt-5.0.0/imports QT_INSTALL_QML:/usr/local/Qt-5.0.0/qml QT_INSTALL_TRANSLATIONS:/usr/local/Qt-5.0.0/translations QT_INSTALL_CONFIGURATION:/etc/xdg QT_INSTALL_EXAMPLES:/usr/local/Qt-5.0.0/examples QT_INSTALL_DEMOS:/usr/local/Qt-5.0.0/examples QT_HOST_PREFIX:/usr/local/Qt-5.0.0 QT_HOST_DATA:/usr/local/Qt-5.0.0 QT_HOST_BINS:/usr/local/Qt-5.0.0/bin QMAKE_SPEC:linux-g++-64 QMAKE_XSPEC:linux-g++-64 QMAKE_VERSION:3.0 QT_VERSION:5.0.0
我還要指出的是,我沒有安裝這臺機器上的Qt 4.x的開發文件:
[email protected]:~$ dpkg -l | grep qt4 ii libqt4-dbus:amd64 4:4.8.3+dfsg-0ubuntu3 amd64 Qt 4 D-Bus module ii libqt4-declarative:amd64 4:4.8.3+dfsg-0ubuntu3 amd64 Qt 4 Declarative module ii libqt4-designer:amd64 4:4.8.3+dfsg-0ubuntu3 amd64 Qt 4 designer module ii libqt4-help:amd64 4:4.8.3+dfsg-0ubuntu3 amd64 Qt 4 help module ii libqt4-network:amd64 4:4.8.3+dfsg-0ubuntu3 amd64 Qt 4 network module rc libqt4-opengl:amd64 4:4.8.3+dfsg-0ubuntu3 amd64 Qt 4 OpenGL module rc libqt4-qt3support:amd64 4:4.8.3+dfsg-0ubuntu3 amd64 Qt 3 compatibility library for Qt 4 ii libqt4-script:amd64 4:4.8.3+dfsg-0ubuntu3 amd64 Qt 4 script module ii libqt4-scripttools:amd64 4:4.8.3+dfsg-0ubuntu3 amd64 Qt 4 script tools module ii libqt4-sql:amd64 4:4.8.3+dfsg-0ubuntu3 amd64 Qt 4 SQL module ii libqt4-sql-sqlite:amd64 4:4.8.3+dfsg-0ubuntu3 amd64 Qt 4 SQLite 3 database driver ii libqt4-svg:amd64 4:4.8.3+dfsg-0ubuntu3 amd64 Qt 4 SVG module ii libqt4-test:amd64 4:4.8.3+dfsg-0ubuntu3 amd64 Qt 4 test module ii libqt4-xml:amd64 4:4.8.3+dfsg-0ubuntu3 amd64 Qt 4 XML module ii libqt4-xmlpatterns:amd64 4:4.8.3+dfsg-0ubuntu3 amd64 Qt 4 XML patterns module ii python-qt4 4.9.3-4 amd64 Python bindings for Qt4 ii python-qt4-dbus 4.9.3-4 amd64 D-Bus Support for PyQt4