标签:
参考:http://askubuntu.com/questions/279421/how-can-i-install-qt-5-x-on-12-04-lts
sudo apt-get install qtcreator
You can usually do this with the following commands:
sudo apt-add-repository ppa:ubuntu-sdk-team/ppa sudo apt-get update
The next step is to install the necessary packages for Qt5 / QML 2.0 development. You can do that by running these command:
sudo apt-get install qtdeclarative5-dev
This will install the headers / libraries necessary for development with desktop Qt and QML. You will also probably want to grab the latest release of Qt Creator from this page.
I‘ve found that Qt Creator sometimes has problems finding your new Qt5 installation. If that is the case, perform these steps:
click "Add..." and enter the location that corresponds with your OS:
32-bit: /usr/lib/i686-linux-gnu/qt5/bin/qmake 64-bit: /usr/lib/x86_64-linux-gnu/qt5/bin/qmake
1、下载源:http://mirrors.hust.edu.cn/qtproject/archive/qt/5.1/5.1.0/qt-linux-opensource-5.1.0-x86-offline.run
2、开始安装:
null@dev:~/echo$ ./qt-linux-opensource-5.1.0-x86_64-offline.run
如果遇到权限问题请按如下操作:
null@dev:~/echo$ chmod +x ./qt-linux-opensource-5.1.0-x86_64-offline.run
null@dev:~/echo$ sudo ./qt-linux-opensource-5.1.0-x86_64-offline.run
3、选择安装路径为 /home/null/qt/qt5.1.0
4、在本地资源搜索并打开QTcreater
5、更改QTGCC
a、查看编译器路径:
null@dev:~$ echo $PATH /home/null/fsl-release-bsp/build-x11/tmp/sysroots/x86_64-linux/usr/bin/arm-poky-linux-gnueabi:/home/null/bin:/home/null/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games
b、在qtcreater设置编译器路径:
/home/null/fsl-release-bsp/build-x11/tmp/sysroots/x86_64-linux/usr/bin/arm-poky-linux-gnueabi/arm-poky-linux-gnueabi-gcc
6、源文件目录:
error tips:
Non-installed -prefix bulid -for internal development only. No qmlscent installed. No qmlviewer installed.
标签:
原文地址:http://www.cnblogs.com/yechuang/p/4562626.html