Qt5 wayland gui application
-
Previously I was using Qt4 running with the -qws option.
I have now changed to Qt5. As I understand it, qws is no longer a supported platform so I'm trying to run my gui application using the wayland compositor.
I have included the Qt5 and qtwayland packages in my custom yocto build. I can run console applications but if I try use the -wayland specifier to run my gui application I get the folowing:
root@beaglebone:~# ./bbb3 -platform wayland
error: XDG_RUNTIME_DIR not set in the environment.
Failed to create display (No such file or directory)Could someone point me in the right direction?
Thanks.
-
-
Thanks for the welcome and your quick response.
After some research I discovered that I first need to run the weston compositor before running my application. I included the weston packages in my yocto build and ran it with the following commands:
mkdir -p /tmp/$USER-weston
chmod 0700 /tmp/$USER-weston
export XDG_RUNTIME_DIR=/tmp/$USER-weston
weston --tty=1 --backend=fbdev-backend.so &Then I successfully ran my QT5 gui application with the wayland platform specifier:
./myQt5App -platform wayland
-
Nice ! Happy coding !