Install Qt 5 on Ubuntu
来源:互联网 发布:mac桌面没了咋办v 编辑:程序博客网 时间:2024/04/28 17:54
Introduction
This is a tutorial for installation of Qt 5.0.2 to Ubuntu 12.10. It may be used also for newer versions of Qt and Ubuntu. A difference for OpenGL has been found and added as a note below.
Installation Guide
- Download
Visit Qt downloads page an download a 32-bit or 64-bit Linux installation [qt-project.org] depending your version of Ubuntu. The installation file can be also downloaded through the command line using wget.
Example:
- wget http://download.qt-project.org/official_releases/qt/5.0/5.0.2/qt-linux-opensource-5.0.2-x86-offline.run
- Install
Adjust permission, run the installer and follow the instruction to complete the installation.
- chmod +x qt-linux-opensource-5.0.2-x86-offline.run
- ./qt-linux-opensource-5.0.2-x86-offline.run
- Install g++
Open a terminal and execute the following command to install g++:
- sudo apt-get install build-essential
- Configure a compiler
Launch Qt Creator. Go to Tools > Options. Click Build & Run and select tab Kit. Configure a compiler if it is not automatically detected.
- Install OpenGL libraries
Execute the following command to install OpenGL libraries:
- sudo apt-get install mesa-common-dev
Note: Just installing the above-mentioned mesa-common-dev kit is not sufficient for more recent Ubuntu versions. Based on this comment in the forum [qt-project.org] an additional package needs installation. Execute following command:
- sudo apt-get install libglu1-mesa-dev -y
Tested with Qt5.3.1 and Ubuntu 14.04 and it solved the problem with missing -lGL.
Troubleshooting
- Qt Creator needs a compiler set up to build
Follow the instruction from the previous section to configure compiler for Qt Creator.
- error: g++: Command not found
Solution:
- sudo apt-get install build-essential
- error: GL/gl.h: No such file or directory
Solution:
- sudo apt-get install mesa-common-dev
- Install Qt 5 on Ubuntu
- Install Qt 5 on Ubuntu
- Install Qt 5 on Ubuntu
- install qt on ubuntu 14.04
- how to install qt on ubuntu
- INSTALL CGAL on ubuntu and use it in qt
- Install CUDA 5 on Ubuntu 12.04
- install ImageMagick on Ubuntu
- install myreview on ubuntu
- Install JDK on Ubuntu
- install mplayer on ubuntu
- install mplayer on ubuntu
- install xipmsg on ubuntu
- Install gtk2hs on ubuntu
- install ibus on Ubuntu
- Mysql Install on ubuntu
- Install sqldeveloper on Ubuntu
- Install NS2 on Ubuntu
- assign,copy,retain -Object-C中纠结的三个属性(retain)
- 美国医学美容护肤品MDSUN
- Eclipse快捷键记录
- 猴子睡觉前之二:property属性设置
- 第八周项目五:定期存款利息计算器
- Install Qt 5 on Ubuntu
- Node.js安装
- jtester
- assign,copy,retain -Object-C中纠结的三个属性(copy)
- mysql点滴_01查看错误码的方法
- C++的string类~
- log4j配置详解
- C++大整数类
- Spring不支持依赖注入static静态变量