Ubuntu 18.04 Bionic comes with Qt 5.9.5 by default.
But, Canonical has built it without considering the ARM Mali GPU detection and Qt5 didn’t work on Ubuntu 18.04 at all.
So we have to build the Qt5 source code manually.
Here is a quick and dirty build guide. I tested on the latest XU4 Ubuntu 18.04 Bionic image.
Update.
sudo apt update && sudo apt upgrade && sudo apt dist-upgrade
Install build-depends and source code.
sudo apt build-dep qt5-default apt source qtbase5-dev cd qtbase-opensource-src-5.9.5+dfsg
Edit a file for correct detecting the ARM’s Mali GPU.
Line 86 : src/platformsupport/eglconvenience/qxlibeglintegration.cpp
Line 86 : src/platformsupport/eglconvenience/qxlibeglintegration.cpp
to :
if (vendor && (strstr(vendor, "Vivante") || strstr(vendor, "ARM"))) {
from :
if (vendor && strstr(vendor, "Vivante")) {
Another file should be edited to avoid a compile error. I wasted several hours to find this simple solution.
src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_egldevice/qeglfskmsegldevice.cpp
http://code.qt.io/cgit/qt/qtbase.git/commit/?h=dev&id=9a640e7bc67b0a1ff5c61c63703b669e6f24521eCreate two symlinks for proper OpenGL-ES detection. This fix will be included in the next update probably.
src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_egldevice/qeglfskmsegldevice.cpp
http://code.qt.io/cgit/qt/qtbase.git/commit/?h=dev&id=9a640e7bc67b0a1ff5c61c63703b669e6f24521eCreate two symlinks for proper OpenGL-ES detection. This fix will be included in the next update probably.
sudo rm /usr/lib/arm-linux-gnueabihf/libGLESv2.so.2.0.0 sudo rm /usr/lib/arm-linux-gnueabihf/libEGL.so.1.0.0 sudo ln -s /usr/lib/arm-linux-gnueabihf/mali-egl/libmali.so /usr/lib/arm-linux-gnueabihf/libGLESv2.so.2.0.0 sudo ln -s /usr/lib/arm-linux-gnueabihf/mali-egl/libmali.so /usr/lib/arm-linux-gnueabihf/libEGL.so.1.0.0
Build Qt5
sudo dpkg-buildpackage -b
I met this error when I ran it on a SSH session.
Project ERROR: QtDBus is enabled but session bus is not available. Please check the installation.
When I built it on the Mate desktop terminal instead of the remote ssh access, the build had no issue. It is still not understandable.After 2~3 hours of boring build time, the “debian packaging” failed due to a missing PGP key.
But all the Qt5 libraries with examples were generated correctly and I could install them with sudo make install command.Qt-OpenGL example works beautifully now.
Project ERROR: QtDBus is enabled but session bus is not available. Please check the installation.
When I built it on the Mate desktop terminal instead of the remote ssh access, the build had no issue. It is still not understandable.After 2~3 hours of boring build time, the “debian packaging” failed due to a missing PGP key.
But all the Qt5 libraries with examples were generated correctly and I could install them with sudo make install command.Qt-OpenGL example works beautifully now.
We will test the stability and functionality for a couple of weeks.
If there is no critical issue, we will release it officially.
Feel free to post your idea on the forum thread.
A few interesting Qt5 base applications for Linux users
OpenCV (Open Source Computer Vision Library) is an open source computer vision and machine learning software library.
Qt5 framework is used with OpenCV for image processing visualization as well as interactive user interface.
Calligra : It offers a comprehensive set of 8 applications which satisfies the office, graphics and management needs.
Word, Presentation, Spreadsheet and many more. Simply run “sudo apt install calligra-libs” command to play with it.
Word, Presentation, Spreadsheet and many more. Simply run “sudo apt install calligra-libs” command to play with it.
Calibre : It is a powerful and easy to use e-book manager.
Simply run “sudo apt install calibre” command to read tons of great e-books.
Simply run “sudo apt install calibre” command to read tons of great e-books.
Stellarium is a free open source planetarium for your computer.
It shows a realistic sky in 3D, just like what you see with the naked eye, binoculars or a telescope.
It shows a realistic sky in 3D, just like what you see with the naked eye, binoculars or a telescope.
Running “sudo apt install stellarium” is enough to enjoy the virtual sky on your ODROID-XU4.
Krita is a professional and open source painting program. It is made by artists that want to see affordable art tools for everyone.
Unfortunately, Krita for ARM platform in Ubuntu 18.04 PPA was broken and it will be fixed by Canonical soon. It is available in Ubuntu 16.04 PPA only.