Francisco Alberto Carrillo Dominguez

Qt5 with Qt3D over Wayland rootfs

Discussion created by Francisco Alberto Carrillo Dominguez Employee on Apr 4, 2013
Latest reply on Sep 17, 2015 by sanjeev sharma

First  Thanks to Prabhu Sundararaj  for sharing his knowledge and tips to be able to accomplish all these steps.



With our new release of wayland coming soon, many of you would like to see it working with the latest Qt.  The process might sound complicated, but it is simpler than it seems.


Once you get in your hands the newest release sources then follow the MX6_Wayland_Weston_User_Guide_Review.pdf  for the instructions to install your Ltib and compile the rootfs.  I was successful creating the rootfs with Gnome profile selected.



Pay a lot of attention to step 8



8 Enabling Wayland/Weston Support for Prebuilt rootfs in

LTIB File System

The prebuilt root file system (rootfs) comes with prebuilt GPU driver. By default, it is set to EGL framebuffer. To enable

Wayland/Weston support, make EGL and GAL point to correct binaries as shown below:

$ ls –l $(ROOTFS)/usr/lib/ ->

$ ls –l $(ROOTFS)/usr/lib/ ->


The manual only advices to change link to,  but you also have to change link,  it should point to as well.




ln -s

ln -s

ln -s


Once building the rootfs is successful, please test that it boots correctly and start weston correctly.



$export LD_LIBRARY_PATH="/usr/lib"

$export XDG_RUNTIME_DIR="/tmp"



Proceed to QT5 build.  Please follow the guide to build QT5.


Pay attention that the rootfs now is the one created with the wayland release.


For example this  configure line:


./configure -opensource -confirm-license -make libs -device imx6 -device-option CROSS_COMPILE=/opt/freescale/usr/local/gcc-4.6.2-glibc-2.13-linaro-multilib-2011.12/fsl-linaro-toolchain/bin/arm-fsl-linux-gnueabi- -sysroot /home/b35153/waylandRootfs/ltib/rootfs -no-gcc-sysroot -prefix /opt/qt5wayland -no-pch -no-opengl -opengl es2 -no-xcb -make examples -make demos


After completing the guide, the next step is to build the Qtwayland plug-in.


1. Download the git repository for Qtwayland:



$ git clone git://

   $ cd qtwayland

2. gedit src/plugins/platforms/qwayland-egl/

and make the change as like this, please be careful on not to break the syntax:



Delete these lines:

!contains(QT_CONFIG, no-pkg-config) {

    CONFIG += link_pkgconfig

    PKGCONFIG += wayland-egl egl

    } else {

    LIBS += -lwayland-egl -lEGL



Replace them with this line


3. cd to <qtwayland directory>/qtwayland and run the qmake

(qmake should be in the PATH, or you can specify the full path to qmake)


$ qmake -r


   The qtwayland will test certain packages. The summary should look like this:


Checking for wayland... yes

Checking for xkbcommon... yes

Checking for brcm_egl... no

Checking for egl... yes

Checking for glx... no

Checking for wayland_egl... yes

Checking for xcomposite... no

If you have an error about the wayland-scanner not detected, disable the check at the

#!config_wayland_scanner {

#    error(QtWayland requires wayland-scanner)



   4.  Build

make && sudo make install




Ater this step you should be able to run demos  using the wayland-egl platform like this:


$ ./forest_qml -platform wayland-egl


Now in order to install Qt3D follow this guide:




$./shaders -platform wayland-egl