This can be done by adding the following PPA to your system:
ppa:canonical-qt5-edgers/ubuntu1204-qt5 (Click here for instructions on using PPAs.)
You can usually do this with the following commands:
sudo apt-add-repository ppa:canonical-qt5-edgers/ubuntu1204-qt5
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:
- open it up and go to Tools->Options
- click the "Build & Run" section in the left menu
- click the "Qt Versions" tab
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
Previously these packages were located here:
ppa:ubuntu-sdk-team/ppa
According to the "Ubuntu SDK Team": Old Ubuntu 12.04 LTS Qt 5.0 packages have been moved to https://launchpad.net/~canonical-qt5-edgers/+archive/ubuntu/ubuntu1204-qt5/
, and that seems to have occurred sometime in May of 2016.