Raspberry Pi Wheezy Image With Qt and Wayland Support

According to what I read around, it should be possible to install some build of Qt 5 using apt on Raspberry by adding the Qt repo: read here.

However, some asked for a version of Qt compiled for Pi, so, if that was not ok for you for some reason, this is an entire image with many packages for which Qt has support and includes wayland and QtMultimedia (what is working oob).
This is the configuration of the build:

Bulding on: linux-g++
Building for: devices/linux-rasp-pi-g++
Architecture: arm, features:
Host architecture: i386, features:
Platform notes:
- Also available for Linux: linux-kcc linux-icc linux-cxx
Build .................. libs examples
Configuration .......... cross_compile qpa largefile neon pcre minimal-config small-config medium-config large-config full-config fontconfig libudev evdev linuxfb c++11 accessibility egl eglfs opengl opengles2 shared qpa reduce_exports reduce_relocations clock-gettime clock-monotonic mremap getaddrinfo ipv6ifname getifaddrs inotify system-jpeg png system-freetype system-zlib nis iconv glib gstreamer dbus openssl rpath alsa icu concurrent audio-backend v8 v8snapshot release
Debug .................. no
C++11 support .......... yes
pkg-config ............. yes
Qt D-Bus module ........ yes (run-time)
Qt Concurrent code ..... yes
Qt GUI module .......... yes
Qt Widgets module ...... yes
JavaScriptCore JIT ..... To be decided by JavaScriptCore
QML debugging .......... yes
PCH support ............ no
iWMMXt support ......... no
NEON support ........... yes
IPv6 ifname support .... yes
getaddrinfo support .... yes
getifaddrs support ..... yes
Accessibility .......... yes
NIS support ............ yes
CUPS support ........... no
Iconv support .......... yes
Glib support ........... yes
GStreamer support ...... yes
PulseAudio support ..... no
Large File support ..... yes
GIF support ............ plugin
JPEG support ........... plugin (system)
PNG support ............ yes (qt)
zlib support ........... system
Session management ..... auto
libudev support ........ yes
Use system proxies ..... no
OpenGL support ......... yes (OpenGL ES 2.x)
OpenVG support ......... no
XShape support ......... auto
XVideo support ......... auto
XSync support .......... auto
Xinerama support ....... runtime
Xcursor support ........ runtime
Xfixes support ......... runtime
Xrandr support ......... runtime
Xi support ............. runtime
Xi2 support ............ auto
MIT-SHM support ........ auto
FontConfig support ..... yes
XKB Support ............ auto
GTK theme support ...... no
SQLite support ......... plugin (qt)
OpenSSL support ........ yes (run-time)
Alsa support ........... yes
libICU support ......... yes
PCRE support ........... qt
Xcb support ............ no
Xrender support ........ no
EGLFS support .......... yes
DirectFB support ....... no
LinuxFB support ........ yes
KMS support ............ no

The modules I compiled are:

  1. qtbase
  2. qtscript
  3. qtjsbackend
  4. qtdeclarative
  5. qtgraphicaleffects
  6. qtimageformats
  7. qtmultimedia
  8. qtquick1
  9. qtsvg
  10. qtwayland
  11. qtwebkit
  12. qtwebkit-examples-and-demos
  13. qtxmlpatterns
  14. qt3d

How to Use to Build

To build code with this you need to dd the image to an SD card (4GB at least), and setup your system to cross-compile using the same libs.
First transfer the image to the SD:

tar xvfp wheezy_qt5_20130310.tar
tar xvfpj wheeze_image_20130310_qt5.tar.bz2
sudo dd if=wheezy_image_20130310.img of=your_sd_dev

Then transfer all the libs you need to cross-compile in your sysroot, which must be located in /opt/rpi/sysroot.

sudo mkdir /opt/rpi
sudo mkdir /opt/rpi/sysroot
cd /opt/rpi/sysroot
sudo scp -r root@rpi_ip:/lib root@rpi_ip:/opt .
sudo mkdir usr
sudo scp -r root@rpi_ip:/usr/lib root@rpi_ip:/usr/include root@rpi_ip:/usr/local usr

Now place the Qt tools into your system:

tar xvfpj Qt-rasp-5.0.2_build_rools.tar.bz2
sudo mv Qt-rasp-5.0.2 /usr/local

Setup Qt Creator to Cross-Compile

You should now be able to setup Qt Creator to cross-compile. Open Qt Creator, got to the Window -> Options -> Build & Run. Open the “Compilers” tab and add the new cross-compiler.
Setup the Qt version by selecting the qmake binary from /usr/local/Qt-rasp-5.0.2/bin/qmake.
Setup a new kit by setting both the compiler and the Qt version you just added.
You should be done.

Download the Package

The package is large since it contains the entire image, including all the needed packages. Try to download from here (sorry, I experienced too much traffic so I had to remove it, you can try with this torrent or this ftp, but both will take long; please let me know if you experience troubles).
The userid is pi and the passwords are rasp for both the user pi and root.

Edit 2013.04.16

I see that many are still trying to download and the server is permanently at full upload speed, I suppose it is better to start using p2p: use this ed2k link to download. I’m sharing this with priority. If you’re already downloading via FTP, then please complete the download as quickly as possible; I’ll remove the file in a couple of days. In case you experienced issues, please leave a message.

Edit 2021.09.03

The download is no more available.

81 thoughts on “Raspberry Pi Wheezy Image With Qt and Wayland Support”

  1. hi,sorry for English proficiency currency ,i processing video with qt creator on rasperry pi,but it load very slow, can you help me

  2. Hi Luca,
    i tried several tutorials and qt5 / toolchain combinations. All have issues at some point of the build process.
    Did i get it right? Did you upload once a complete raspbian image which includes the qt5 binaries that should work right out of the box?
    Are they still online?

    Thanks a lot if you might be able to help.
    Nik

  3. Hi Luca and Osama

    I get the same error, did you have any progress? I'm also trying to solve it, but i'm quite new to linux, so there's no much hope 🙂

  4. wheezy_qt5_20130807.7z contains the build tools. Inside the 7z package there is Qt-rasp-5.1.2.tar.bz2 which contains all the build tools you need for Qt.

  5. Thank you, at last I set up an Ubuntu VM to get things easier.
    Now, I'd need wheezy_qt5_20130310.tar ….
    (I was able to download wheezy_qt5_20130807.tar but it doesn't contain Qt-rasp-5.x.2_build_tools and anyway I wish not to mess up things again with different versions). I found a torrent but i'm stuck at 51% since a week. May you help me ?
    Thanks in advance

  6. ls /opt/rpi/
    gcc-4.7-linaro-rpi-gnueabihf sysroot

    so I changed "gcc-4.7-linaro-rpi-gnueabihf" to "gcc-linaro-arm-linux-gnueabihf-raspbian".

    Now , I have a new error :
    In file included from /opt/rpi/gcc-linaro-arm-linux-gnueabihf-raspbian/bin/../lib/gcc/arm-linux-gnueabihf/4.7.2/../../../../arm-linux-gnueabihf/include/c++/4.7.2/arm-linux-gnueabihf/bits/c++config.h:414:0,
    from /opt/rpi/gcc-linaro-arm-linux-gnueabihf-raspbian/bin/../lib/gcc/arm-linux-gnueabihf/4.7.2/../../../../arm-linux-gnueabihf/include/c++/4.7.2/utility:70,
    from /opt/rpi/gcc-linaro-arm-linux-gnueabihf-raspbian/bin/../lib/gcc/arm-linux-gnueabihf/4.7.2/../../../../arm-linux-gnueabihf/include/c++/4.7.2/algorithm:61,
    from /opt/rpi/sysroot/usr/local/Qt-rasp-5.1.2/include/QtCore/qglobal.h:80,
    from /opt/rpi/sysroot/usr/local/Qt-rasp-5.1.2/include/QtCore/qcoreapplication.h:45,
    from /opt/rpi/sysroot/usr/local/Qt-rasp-5.1.2/include/QtGui/qguiapplication.h:45,
    from /opt/rpi/sysroot/usr/local/Qt-rasp-5.1.2/include/QtGui/QGuiApplication:1,
    from ../MahaProjectQML2/main.cpp:1:
    /opt/rpi/gcc-linaro-arm-linux-gnueabihf-raspbian/bin/../lib/gcc/arm-linux-gnueabihf/4.7.2/../../../../arm-linux-gnueabihf/include/c++/4.7.2/arm-linux-gnueabihf/bits/os_defines.h:40:22: fatal error: features.h: No such file or directory
    compilation terminated.
    make: *** [main.o] Error 1
    22:56:50: The process "/usr/bin/make" exited with code 2.
    Error while building/deploying project MahaProjectQML2 (kit: raspberrypi)
    When executing step 'Make'

  7. Thanks for this great job 🙂

    I followed all instruction , but I have this error

    "Project ERROR: Compiler /opt/rpi/gcc-linaro-arm-linux-gnueabihf-raspbian/bin/arm-linux-gnueabihf-g++ not found. Check the value of CROSS_COMPILE -device-option
    Could not read qmake configuration file /usr/local/Qt-rasp-5.1.2/mkspecs/devices/linux-rasp-pi-g++/qmake.conf."

  8. Now I know I'm a fool ! :-O Unfortunately Qt-rasp-5.1.2 has no source for qmake and other utilities….can you address on the right track to get these libraries compiled ? Shall I use regular Qt sources ? I'm sure there are compilation flags I will miss….

  9. qmake: ELF 32-bit LSB executable, Intel 80386, version 1 (GNU/Linux), dynamically linked (uses shared libs), for GNU/Linux 2.6.24, not stripped

    This is pretty eloquent 🙂

    If you want to work on a system different from the one for which the executables are built you'll have to rebuild.

  10. update: I changed file permission (my fault) and hardlinked to /usr/administrator/documents. Now Qt Creator complains about "Cannot start '/Users/amministratore/Documents/qmake': Exec format error". file command on qmake returns
    "qmake: ELF 32-bit LSB executable, Intel 80386, version 1 (GNU/Linux), dynamically linked (uses shared libs), for GNU/Linux 2.6.24, not stripped".
    Any suggestions ?
    Thanks !

  11. Hi. I am trying to setup the Qt version by selecting the qmake binary from /usr/local/Qt-rasp-5.1.2/bin (could not get 5.0.2 version). Qt Creator does not allow me to navigate to /usr….. so I symlinked quake in /usr/administrator/documents. Now I can select qmake but I get this error: "The qmake executable /Users/administrator/Documents/qmake could not be added: qmake is not an executable. I'm confused, this should be a x86 version. Am I doing something wrong ? I'm on a Macbook 2011 Pro
    Any help you can give would be great !

  12. Now I'm just confusing myself. Please disregard my previous comment (October 16, 2013 at 1:25 AM). The folder /opt/rpi/sysroot/usr/local is populated from the libraries present on the Raspberry Pi in /usr/local. Is it possible for you to check your image_20130807.img file in /usr/local/Qt-rasp-5.1.2/include/ to see if QtDeclarative is there?

    I am able to get a test project compiled and running now but it would be nice to have the QtDeclarative library.

    Thanks for your help!

  13. Check that, It does make sense that the folders would be different since I used the tarball to populate the Qt directory under usr/local on my Desktop. Maybe that file is missing a few files in the torrent?

  14. From the output of my compiler (shown below) I take it that the QtDeclarative library is missing in /opt/rpi/sysroot/usr/local/Qt-rasp-5.1.2/include/

    When I check in that folder on my Desktop I do not find the QtDeclarative library.
    When I check in: /opt/rpi/sysroot/usr/local/Qt-rasp-5.1.2 on the raspberry pi I only find an examples folder. This is confusing to me since I do have additional libraries in the corresponding folder on my desktop since I populated that directory from the Pi.

    Compiler output

    17:09:53: Running steps for project SwitcherGUI…
    17:09:53: Configuration unchanged, skipping qmake step.
    17:09:53: Starting: "/usr/bin/make"
    /opt/rpi/gcc-linaro-arm-linux-gnueabihf-raspbian/bin/arm-linux-gnueabihf-g++ -c -pipe -marm -mfpu=vfp -mtune=arm1176jzf-s -march=armv6zk -mabi=aapcs-linux -mfloat-abi=hard –sysroot=/opt/rpi/sysroot -std=c++0x -g -Wall -W -D_REENTRANT -fPIE -DQT_QML_DEBUG -DQT_DECLARATIVE_DEBUG -DQT_DECLARATIVE_LIB -DQT_WIDGETS_LIB -DQT_SCRIPT_LIB -DQT_GUI_LIB -DQT_CORE_LIB -I/usr/local/Qt-rasp-5.1.2/mkspecs/devices/linux-rasp-pi-g++ -I../SwitcherGUI -I../SwitcherGUI/qmlapplicationviewer -I/opt/rpi/sysroot/usr/local/Qt-rasp-5.1.2/include -I/opt/rpi/sysroot/usr/local/Qt-rasp-5.1.2/include/QtDeclarative -I/opt/rpi/sysroot/usr/local/Qt-rasp-5.1.2/include/QtWidgets -I/opt/rpi/sysroot/usr/local/Qt-rasp-5.1.2/include/QtScript -I/opt/rpi/sysroot/usr/local/Qt-rasp-5.1.2/include/QtGui -I/opt/rpi/sysroot/usr/local/Qt-rasp-5.1.2/include/QtCore -I. -I/opt/rpi/sysroot/opt/vc/include -I/opt/rpi/sysroot/opt/vc/include/interface/vcos/pthreads -I/opt/rpi/sysroot/opt/vc/include/interface/vmcs_host/linux -I. -o main.o ../SwitcherGUI/main.cpp
    In file included from ../SwitcherGUI/main.cpp:2:0:
    ../SwitcherGUI/qmlapplicationviewer/qmlapplicationviewer.h:14:28: fatal error: QDeclarativeView: No such file or directory
    compilation terminated.
    make: *** [main.o] Error 1
    17:09:54: The process "/usr/bin/make" exited with code 2.
    Error while building/deploying project SwitcherGUI (kit: Rpi)
    When executing step 'Make'
    17:09:54: Elapsed time: 00:01.

  15. One thing that might be illuminating (though I don't know) is that I get a warning that no qmlviewer has been installed when I select the qmake file.

  16. Is there any information that I can provide that would help?

    I decided to erase everything and start over and followed your instructions. Because I am using the more recent torrent (from your August 8th post) some of the filenames were a little different.

    In addition, I found that I had to provide a compiler in the /opt/rpi folder or Qt complained about not being able to find one there. More specifically it was looking for: /gcc-linaro-arm-linux-gnueabihf-raspbian/bin/arm-linux-gnueabihf-gcc. I got this compiler from: https://github.com/raspberrypi/tools under the arm-bcm2708 directory.

    I tried changing the compiler I used to the gcc and g++ compilers located in opt/rpi/gcc-linaro…. but still had no luck. I don't think I missed any of the scp steps though that seems like the most likely candidate.

    Any help you can give would be great. I'm really struggling to get anything to work.

    Thanks again!

  17. Hi Luca,

    Thanks for this image! I am having some trouble getting cross compiled projects to run. I think that I probably have a path wrong somewhere because it says, "error: QDeclarativeView: No such file or directory" Do you have any ideas of what could be causing that?

  18. I got the file from the torrent but am having some trouble. It seems that the username and password has been changed. The image also had a different file name so that could be the source of the problem. Does anyone know the new login info?

  19. Hi,

    Can someone tell me where i can find the crosscompiler as described in the instructions: "Open the "Compilers" tab and add the new cross-compiler."

    thnx!

  20. Hi. I don't know why the connection stopped. I just checked and it seems there are a couple of connections downloading that file. So it should start sooner or later.

  21. Hello, It's now downloaded about 75% but the connection broke somewhere around this midnight. Would be grateful for the remaining part.

    I was in contact with the QtWayland developers and apparently the git repo has been semi-broken since april, but most of them seem to be on vacation right now. Tried using older revisions but then there's wayland-scanner conflicts and whatnot. I'll keep sharing your file once it's done though.

  22. Hello, the ed2k-file doesn't seem to work at all. The torrent-file was pretty good, but it's been stuck on 51.7%. Trying to build QtWayland seems to pose all sorts of problems for me: if wayland is compiled according to your instructions, then the build fails due to deprecated functions in wayland-server.h, if the RPi libwayland-package is used instead of compiling wayland yourself, the build gets further but then it instead fails with this

    In file included from qwaylandbrcmeglintegration.cpp:46:0:
    qwaylandbrcmeglwindow.h:57:7: warning: direct base ‘QObject’ inaccessible in ‘QWaylandBrcmEglWindow’ due to ambiguity [enabled by default]
    qwaylandbrcmeglintegration.cpp: In static member function ‘static void QWaylandBrcmEglIntegration::wlDisplayHandleGlobal(void*, wl_registry*, uint32_t, const QString&, uint32_t)’:
    qwaylandbrcmeglintegration.cpp:67:100: error: ‘wl_brcm_interface’ was not declared in this scope
    )

    The image would be really appreciated, as it would save a lot of trouble trying to get your multimedia-backend running. I could also keep seeding it with a 100MBPs upload for a couple of months. Thank you.

  23. I have a strong unlimited server that can be used to make a mirror for you too if you want. Please advice me when it's ready 😀

    Thanks a lot.

    Cheers

  24. Yes, you're right, I'm sorry. For some reason it seems that it is not working any more. I changed my server configuration recently so I might have done something wrong. I'll try to fix this.

  25. Hi, i can't download it from any of your link 🙁 left edonkey for two days and it's still at 0%, Is there any other alternative, i tried to manually compile it from your other guide but kept failing at the Qt Compositor step

  26. Yeah, at 5 kb/s I think I'll actually pass on that one. All I'm really looking for is to make an environment where I have Qt installed on my raspberry, a working QtCreator environment to remote deploy to my raspberry, and working, smooth video. The BakeQtPi script gives me the first two, and It's looking really dark that number three will ever be accomplished with the extreme lack of useful documentation.

  27. Could you please re-upload this file? I've been trying to get video working on QtonPi for what seems like forever, since the BakeQtPi-script cannot delivery in that aspect, and documentation is scarcer than teeth on a hen.

  28. Hi, Where I found this package: Qt-rasp-5.0.2_build_rools.tar.bz2 ??? Someone can post this link ??

    Thanks.

  29. Hi Luca

    Thanks. When you write add the new compiler in QtCreator, where is the cross compiler located.

    Doug

  30. Hi Luca,

    thank you for this great work!
    In the meantime: Did you found a location for a faster download?
    It would be wonderful if I could have the image on monday.
    I'm currently downloading at 5 KB/s.

    simon

  31. yes, there is a qmake. But it is not built for arm:

    using the file commane on qmake gives:
    qmake: ELF 32-bit LSB executable, Intel 80386, version 1 (GNU/Linux), dynamically linked (uses shared libs), for GNU/Linux 2.6.24, BuildID[sha1]=0x738fd98f8401a125cc62cb2e44eaf8bb93041b4f, not stripped

    I would like to be able to compile on the pi…

  32. Hello.
    Thank you so much for sharing this!

    I downloaded the image from ftp.

    When i tried to build some qt-examples i realized, there is no qmake around.

    Should it be there? Did i miss something? Do i have to install the qt4-dev-tools? or building it from qt5-source?

    Thanks for any advice.

    inx

  33. Yes, unfortunately I see there are many connections opened so bandwidth is shared. In the meantime if any other file host comes up I can upload there.

  34. Unfortunately… did'nt get more luck with this ed2k link.

    Maybe you could put img file on a file hosting server (like mega or else) for those who could not grab file in time ?

    Thanks anyway for your job

    Sylvain

  35. Sorry, but due to excessive traffic I had to remove it. Only torrent was available but, as you say, I'm not sure it is working anymore.
    You could try this, and see if you have more luck: ed2k://|file|wheezy_qt5_20130310.tar|1637989888|A617A84BBBEE92A5204471250098E83F|/.

  36. Hi, i would like to thank you for your great work !
    I can't get your SDCard image using torrent … 0.0% after 2 days working !

    Could you put your .img in other place where we could grab it ?

    Thank you !
    Sylvain

  37. Hi,

    1) yes, I saw that as well. You should ask the reason to the Qt developer or look into the code.
    2) can you provide that mp4? Does omxplayer behaves the same way?
    3) how did you play those videos? Flash is not included… so html5 video tag?

  38. Ciao Luca,

    First of all I appreciate your work about qt on raspberry. So I did some tests with qtwayland and I found some issues:

    1) when by qml-compositor I close an application. Sometimes I receive this error: "file:///usr/local/Qt-rasp-5.0.2/examples/qtwayland/qml-compositor/main.qml:113: TypeError: Cannot read property 'parent' of null".

    2) I did a test with video and I see that the mpg video are working properly, but with a mp4 the player drops a lot frames and of course I have a lag for the video and the audio does not work.

    3) Furthermore I tried to play youtube video and I saw that the webprocess everytime crash ("WARNING: The web process experienced a crash on 'file:///opt/TestYouTube/player.html?9bZkp7q19f0'."). By HTOP I see that the CPU it was always 100% when web process crashed.

    Now I am investigating about issues….

    Ciao,
    Massimo.

  39. Yes they are present,

    However I checked the qmake -query in detail and it seems that I'm missing quite a lot of paths. Namely these:

    QT_INSTALL_BINS:/opt/rpi/sysroot/usr/local/Qt-rasp-5.0.2/bin
    QT_INSTALL_TESTS:/opt/rpi/sysroot/usr/local/Qt-rasp-5.0.2/tests
    QT_INSTALL_TESTS/raw:/usr/local/Qt-rasp-5.0.2/tests
    QT_INSTALL_PLUGINS/raw:/usr/local/Qt-rasp-5.0.2/plugins
    QT_INSTALL_TRANSLATIONS:/opt/rpi/sysroot/usr/local/Qt-rasp-5.0.2/translations
    QT_INSTALL_TRANSLATIONS/raw:/usr/local/Qt-rasp-5.0.2/translations
    QT_INSTALL_CONFIGURATION:/opt/rpi/sysroot/usr/local/Qt-rasp-5.0.2/etc/xdg
    QT_INSTALL_CONFIGURATION/raw:/usr/local/Qt-rasp-5.0.2/etc/xdg

    I'm going to try and make empty directories for these and see if that works, I'll report back…

  40. Hello,
    I tried following this guide but when I came to the point where the I needed to add the qmake to Qtcreator for crosscompiling, but when I do I get the following error:

    Qt version not properly installed, please run make install.

    I tried the sugestions from the beginners guide, I also ran qmake -query to check the paths, they seem to be right.

    Does anyone have any sugestion how to fix it?

  41. Hi! Thanks for the guide, but I got some questions, I'm new to linux.
    After I dd the image to the SD card, I boot up your PI, connect to it with SSH.
    1.: Do I run these commands on my ubuntu and not on my PI, right ?

    sudo mkdir /opt/rpi
    sudo mkdir /opt/rpi/sysroot
    cd /opt/rpi/sysroot
    sudo scp -r root@rpi_ip:/lib root@rpi_ip:/opt .
    sudo mkdir usr
    sudo scp -r root@rpi_ip:/usr/lib root@rpi_ip:/usr/include root@rpi_ip:/usr/local usr

    And also replacing rpi_ip with 192.168.1.101, for me example.

    2.: After that, do I have to run any ./configure file or similar ?

    3.: Where do I have to run these commands?

    tar xvfpj Qt-rasp-5.0.2_build_rools.tar.bz2
    sudo mv Qt-rasp-5.0.2 /usr/local

    4.: Do I have to run or know amything else that is not obvious for me ? 🙂

    Sorry for the noobish questions, waiting for your reply

    Yaga

Leave a Reply

Your email address will not be published.