I am using Qt 5.5.1 Creator on my virtual machine (Ubuntu 12.04.5 LTS), and Beaglebone black with touch screen. When i write gui application(only one window with push button) and try to deploy it, i get this error :
This application failed to start because it could not find or load the Qt platform plugin "xcb"
Reinstalling the application may fix this problem. bash: line 1: 907 Aborted DISPLAY=':0.0' /opt/proba/Test/Test Application finished with exit code 134.
I was searching on the internet and found that this problem is somehow related to libqxcb.so
library, I tried ldd libxcb.so
command and result is :
linux-vdso.so.1 (0xbef5a000)
libQt5XcbQpa.so.5 => not found
libdl.so.2 => /lib/arm-linux-gnueabihf/libdl.so.2 (0xb6f67000)
libX11-xcb.so.1 => /usr/lib/arm-linux-gnueabihf/libX11-xcb.so.1 (0xb6f55000)
libXi.so.6 => /usr/lib/arm-linux-gnueabihf/libXi.so.6 (0xb6f3b000)
libxcb-render-util.so.0 => /usr/lib/arm-linux-gnueabihf/libxcb-render-util.so.0 (0xb6f30000)
libSM.so.6 => /usr/lib/arm-linux-gnueabihf/libSM.so.6 (0xb6f1a000)
libICE.so.6 => /usr/lib/arm-linux-gnueabihf/libICE.so.6 (0xb6ef7000)
libxcb-render.so.0 => /usr/lib/arm-linux-gnueabihf/libxcb-render.so.0 (0xb6ee0000)
libxcb.so.1 => /usr/lib/arm-linux-gnueabihf/libxcb.so.1 (0xb6ebb000)
libxcb-image.so.0 => /usr/lib/arm-linux-gnueabihf/libxcb-image.so.0 (0xb6ea7000)
libxcb-icccm.so.4 => /usr/lib/arm-linux-gnueabihf/libxcb-icccm.so.4 (0xb6e9b000)
libxcb-sync.so.1 => /usr/lib/arm-linux-gnueabihf/libxcb-sync.so.1 (0xb6e85000)
libxcb-xfixes.so.0 => /usr/lib/arm-linux-gnueabihf/libxcb-xfixes.so.0 (0xb6e70000)
libxcb-shm.so.0 => /usr/lib/arm-linux-gnueabihf/libxcb-shm.so.0 (0xb6e5d000)
libxcb-randr.so.0 => /usr/lib/arm-linux-gnueabihf/libxcb-randr.so.0 (0xb6e44000)
etc...
As you can see, libQt5XcbQpa.so.5 is not found, even though this library exists in part of my program where i Keep my libraries:
-rw------- 1 debian debian 1140 Feb 9 2016 libQt5XcbQpa.la
-rw------- 1 debian debian 1478 Feb 9 2016 libQt5XcbQpa.prl
lrwxrwxrwx 1 debian debian 21 Mar 1 12:34 libQt5XcbQpa.so -> libQt5XcbQpa.so.5.5.1
lrwxrwxrwx 1 debian debian 21 Mar 1 12:34 libQt5XcbQpa.so.5 -> libQt5XcbQpa.so.5.5.1
lrwxrwxrwx 1 debian debian 21 Mar 1 12:34 libQt5XcbQpa.so.5.5 -> libQt5XcbQpa.so.5.5.1
-rw------- 1 debian debian 602768 Feb 9 2016 libQt5XcbQpa.so.5.5.1
Can any one tell me how to solve this problem,also when I start my application it opens terminal.
Sorry for my bad english.
Your application needs libqxcm.so
which requires libQt5XcmQpa.so.5
,libQt5DBus.so.5
, libQt5Gui.so.5
and libQt5Core.so.5
libqxcm.so
will be in the directory platforms
in your application directory.
Not forget to create symbolic links for the shared libraries like the following:
libQt5Core.so.5 -> libQt5Core.so.5.5.1
libQt5Gui.so.5 -> libQt5Gui.so.5.5.1
libQt5XcmQpa.so.5 -> libQt5XcmQpa.so.5.5.1
libQt5DBus.so.5 -> libQt5DBus.so.5.5.1
For a detailed answer, check this answer: Deploying dynamically linked Qt 5.7 application on CentOS 7