How to install Qt5 X11 Extras module in Ubuntu 12.04?
For my build on travis CI I need qt5 x11extras addon. I tried to add ppa:ubuntu-sdk-team/ppa but cmakes find_package(Qt5X11Extras REQUIRED) still fails. Where the heck does ubuntu hide the qt stuff?
Are you sure you're talking about Ubuntu 12.04? Qt5 doesn't seem to be available in Ubuntu 12.04.
If you're talking about Ubuntu 14.04 or later, I think the package you want is named libqt5x11extras5-dev
. Check if it's installed:
sudo apt-get install libqt5x11extras5-dev
UPDATE:
Qt X11 Extras was introduced in Qt 5.1, but the Ubuntu SDK team PPA (ppa:ubuntu-sdk-team/ppa), provides only Qt 5.0 for Ubuntu 12.04. After an extensive search, I failed to find a PPA that you could use. IMHO, you're left with 2 options:
- Uninstall all Qt5 packages that you installed from PPA and install the latest Qt5 using the Qt Installer.
- Upgrade to Ubuntu 14.04 (or later) and install
libqt5x11extras5-dev
.
UPDATE 2:
If you're still interested, there's new PPAs by Stephan Binner with recent Qt versions for Precise and Trusty. In order to not mess with Qt system packages, they're installed in /opt
so you'll have to inform the correct path (/opt/qtXX/include/QtX11Extras
) to your build tool.
Example: if you want x11extras from Qt 5.1, you could add the Qt 5.1.1 PPA:
sudo apt-add-repository ppa:beineri/opt-qt511
sudo apt-get update
Then install qt-latest
and qt51x11extras
:
sudo apt-get install qt-latest qt51x11extras
The include files for x11extras will be in /opt/qt51/include/QtX11Extras
.
If you compile Qt5 on your own, you need to clone the git submodule qtx11extras
. If you then run configure and make, Qt will compile the extras, too.
Qt has a script named init-repository
in order to control git submodules to be cloned, but did not initialized qtx11extras for me.