Can't find Qt platform plugin "xcb"

• Feb 20, 2014 - 14:45
Type
Functional
Severity
S5 - Suggestion
Status
closed
Project

Would someone help me here?

System OpenSuSe linux 13.1

QT5.2.0

I updated from GIT earlier in the week, compiled and installed, everything was file. I updated again today ( GIT version: 37db5d76c1073ee832d8e22183aab07754bbb6ab) and everything compiled, linked and installed without a problem. Now, however, I get the following message when loading mscore.

/home/turtle$ mscore
This application failed to start because it could not find or load the Qt platform plugin "xcb".

Reinstalling the application may fix this problem.
Aborted
/home/turtle$

Has something changed I am not aware of?

Thanks for any advice.


Comments

You changed something in your install of Qt ? How did you install it in the first place?
It's better to use the forum, the developer mailing list or IRC for this type of support request.

Lubuntu 13.04 (32bits)
Same situation
My automated script detected the new revision and changed revision.h to the last value (dated 2014/02/20) but the …/build.release/mscore/mscore file is always dated 2014/02/19.

My Mint16 (64bits) machine just compiled with Qt5.2 and installed 37db5d7 and is uploading it.

I tried again the 32 bits compilation with Qt5.1 which was in error :
g++: internal compiler error: Processus arrêté (program cc1plus)
Please submit a full bug report,
with preprocessed source if appropriate.
See for instructions.
make[3]: *** [mscore/CMakeFiles/mscore.dir/qrc_musescore.cpp.o] Erreur 4
make[3]: *** Attente des tâches non terminées....
make[3]: quittant le répertoire « /home/leleu/musescore/MuseScore/build.release »
make[2]: *** [mscore/CMakeFiles/mscore.dir/all] Erreur 2
make[2]: quittant le répertoire « /home/leleu/musescore/MuseScore/build.release »
make[1]: *** [all] Erreur 2
make[1]: quittant le répertoire « /home/leleu/musescore/MuseScore/build.release »
make: *** [release] Erreur 2
leleu@serveur:~/musescore/MuseScore$

I downloaded Qt5.2 from the QT project download site. Installed by their installer. All this was done weeks ago and everything was working fine until this last GIT pull.

The only thing was, I had to do a rename of QT installed directory Qt5.2.0/5.2.0 to Qt5.2.0/5.2.0-rc1 in order to comply with the build path specified in the mscore makefile. But, as I said, everything was working.

@lasconic: I apologize if this is the wrong place. It just felt to me that this might be a mscore 'build' problem. Thank you for helping me.

@lasconic:

Thank you. Yes. I saw that in trying to find some kind of solution. I am sorry it does not apply.

If I do an ldd of mscore I get:-

*****************************************

/home/turtle$ ldd /usr/local/bin/mscore
linux-vdso.so.1 (0x00007fffe41fe000)
libvorbisfile.so.3 => /usr/lib64/libvorbisfile.so.3 (0x00007f6e3251c000)
libvorbis.so.0 => /usr/lib64/libvorbis.so.0 (0x00007f6e322ee000)
libogg.so.0 => /usr/lib64/libogg.so.0 (0x00007f6e320e7000)
libsndfile.so.1 => /usr/lib64/libsndfile.so.1 (0x00007f6e31e7c000)
libasound.so.2 => /usr/lib64/libasound.so.2 (0x00007f6e31b9a000)
libQt5Core.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5Core.so.5 (0x00007f6e314cd000)
libQt5Gui.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5Gui.so.5 (0x00007f6e30e48000)
libQt5Designer.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5Designer.so.5 (0x00007f6e30732000)
libQt5Declarative.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5Declarative.so.5 (0x00007f6e3019b000)
libQt5Script.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5Script.so.5 (0x00007f6e2fd1e000)
libQt5ScriptTools.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5ScriptTools.so.5 (0x00007f6e2fa63000)
libQt5Network.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5Network.so.5 (0x00007f6e2f70f000)
libQt5Test.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5Test.so.5 (0x00007f6e2f4e5000)
libQt5Xml.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5Xml.so.5 (0x00007f6e2f2a7000)
libQt5XmlPatterns.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5XmlPatterns.so.5 (0x00007f6e2ec5e000)
libQt5Svg.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5Svg.so.5 (0x00007f6e2ea0c000)
libQt5Sql.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5Sql.so.5 (0x00007f6e2e7cd000)
libQt5Widgets.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5Widgets.so.5 (0x00007f6e2df88000)
libQt5PrintSupport.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5PrintSupport.so.5 (0x00007f6e2dd23000)
libQt5Concurrent.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5Concurrent.so.5 (0x00007f6e2db1d000)
libQt5WebKit.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5WebKit.so.5 (0x00007f6e2b696000)
libQt5WebKitWidgets.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5WebKitWidgets.so.5 (0x00007f6e2b454000)
libQt5OpenGL.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5OpenGL.so.5 (0x00007f6e2b1f0000)
libz.so.1 => /lib64/libz.so.1 (0x00007f6e2afda000)
libdl.so.2 => /lib64/libdl.so.2 (0x00007f6e2add6000)
libpthread.so.0 => /lib64/libpthread.so.0 (0x00007f6e2abb8000)
libportaudio.so.2 => /usr/lib64/libportaudio.so.2 (0x00007f6e2a989000)
libpulse.so.0 => /usr/lib64/libpulse.so.0 (0x00007f6e2a73d000)
librt.so.1 => /lib64/librt.so.1 (0x00007f6e2a535000)
libm.so.6 => /lib64/libm.so.6 (0x00007f6e2a232000)
libQt5Quick.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5Quick.so.5 (0x00007f6e29c9e000)
libQt5Positioning.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5Positioning.so.5 (0x00007f6e29a62000)
libQt5Qml.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5Qml.so.5 (0x00007f6e29455000)
libQt5Sensors.so.5 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libQt5Sensors.so.5 (0x00007f6e29217000)
libstdc++.so.6 => /usr/lib64/libstdc++.so.6 (0x00007f6e28f0f000)
libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x00007f6e28cf8000)
libc.so.6 => /lib64/libc.so.6 (0x00007f6e28949000)
libFLAC.so.8 => /usr/lib64/libFLAC.so.8 (0x00007f6e2870a000)
libvorbisenc.so.2 => /usr/lib64/libvorbisenc.so.2 (0x00007f6e2823b000)
libspeex.so.1 => /usr/lib64/libspeex.so.1 (0x00007f6e28022000)
/lib64/ld-linux-x86-64.so.2 (0x00007f6e32725000)
libicui18n.so.51 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libicui18n.so.51 (0x00007f6e27c09000)
libicuuc.so.51 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libicuuc.so.51 (0x00007f6e27883000)
libgthread-2.0.so.0 => /usr/lib64/libgthread-2.0.so.0 (0x00007f6e27681000)
libglib-2.0.so.0 => /usr/lib64/libglib-2.0.so.0 (0x00007f6e2737e000)
libGL.so.1 => /usr/lib64/libGL.so.1 (0x00007f6e2711f000)
libgobject-2.0.so.0 => /usr/lib64/libgobject-2.0.so.0 (0x00007f6e26ece000)
libX11.so.6 => /usr/lib64/libX11.so.6 (0x00007f6e26b90000)
libXrender.so.1 => /usr/lib64/libXrender.so.1 (0x00007f6e26986000)
libXcomposite.so.1 => /usr/lib64/libXcomposite.so.1 (0x00007f6e26783000)
libxslt.so.1 => /usr/lib64/libxslt.so.1 (0x00007f6e26544000)
libxml2.so.2 => /usr/lib64/libxml2.so.2 (0x00007f6e261d9000)
libgstreamer-0.10.so.0 => /usr/lib64/libgstreamer-0.10.so.0 (0x00007f6e25eed000)
libgstapp-0.10.so.0 => /usr/lib64/libgstapp-0.10.so.0 (0x00007f6e25ce0000)
libgstbase-0.10.so.0 => /usr/lib64/libgstbase-0.10.so.0 (0x00007f6e25a8b000)
libgstinterfaces-0.10.so.0 => /usr/lib64/libgstinterfaces-0.10.so.0 (0x00007f6e25879000)
libgstpbutils-0.10.so.0 => /usr/lib64/libgstpbutils-0.10.so.0 (0x00007f6e25655000)
libgstvideo-0.10.so.0 => /usr/lib64/libgstvideo-0.10.so.0 (0x00007f6e25439000)
libjack.so.0 => /usr/lib64/libjack.so.0 (0x00007f6e251f2000)
libjson.so.0 => /usr/lib64/libjson.so.0 (0x00007f6e24fe8000)
libpulsecommon-4.0.so => /usr/lib64/pulseaudio/libpulsecommon-4.0.so (0x00007f6e24d79000)
libdbus-1.so.3 => /lib64/libdbus-1.so.3 (0x00007f6e24b31000)
libcrypto.so.1.0.0 => /lib64/libcrypto.so.1.0.0 (0x00007f6e24746000)
libicudata.so.51 => /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/lib/libicudata.so.51 (0x00007f6e22ffd000)
libpcre.so.1 => /usr/lib64/libpcre.so.1 (0x00007f6e22d97000)
libglapi.so.0 => /usr/lib64/libglapi.so.0 (0x00007f6e22b71000)
libXext.so.6 => /usr/lib64/libXext.so.6 (0x00007f6e2295f000)
libXdamage.so.1 => /usr/lib64/libXdamage.so.1 (0x00007f6e2275c000)
libXfixes.so.3 => /usr/lib64/libXfixes.so.3 (0x00007f6e22556000)
libX11-xcb.so.1 => /usr/lib64/libX11-xcb.so.1 (0x00007f6e22354000)
libxcb-glx.so.0 => /usr/lib64/libxcb-glx.so.0 (0x00007f6e2213c000)
libxcb-dri2.so.0 => /usr/lib64/libxcb-dri2.so.0 (0x00007f6e21f37000)
libxcb.so.1 => /usr/lib64/libxcb.so.1 (0x00007f6e21d18000)
libXxf86vm.so.1 => /usr/lib64/libXxf86vm.so.1 (0x00007f6e21b12000)
libdrm.so.2 => /usr/lib64/libdrm.so.2 (0x00007f6e21906000)
libffi.so.4 => /usr/lib64/libffi.so.4 (0x00007f6e216fe000)
liblzma.so.5 => /usr/lib64/liblzma.so.5 (0x00007f6e214d8000)
libgmodule-2.0.so.0 => /usr/lib64/libgmodule-2.0.so.0 (0x00007f6e212d4000)
liborc-0.4.so.0 => /usr/lib64/liborc-0.4.so.0 (0x00007f6e21051000)
libwrap.so.0 => /lib64/libwrap.so.0 (0x00007f6e20e46000)
libXau.so.6 => /usr/lib64/libXau.so.6 (0x00007f6e20c42000)
/home/turtle$

**************************

In which I do not see any errors.

However, I have discovered that if I add the Qt5 plugins directory to QT_PLUGIN_PATH,
it works.

QT_PLUGIN_PATH=$QT_PLUGIN_PATH:/home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/plugins

/home/turtle$ ./addQtPluginPath
false
QDateTime(" Qt::LocalTime") QDateTime("2014-02-20 13:23:34.000 EST Qt::LocalTime")
internal error: shortcut not found

cannot find shortcut
internal error: shortcut not found

cannot find shortcut
TextStyleType not found
Articulation::setSubtype: empty subtype
Articulation::setSubtype: empty subtype
Marker::read type 0
Marker::read type 1
Marker::read type 2
Marker::read type 3
Marker::read type 4
Marker::read type 5
Marker::read type 6
QWidget::setMinimumSize: (inspector/Ms::Inspector) Negative sizes (-331,0) are not possible
QWidget::setMinimumSize: (inspector/Ms::Inspector) Negative sizes (-331,0) are not possible
QQmlComponent: Component is not ready
creating component failed
line 13: module "QtQuick" is not installed
QQmlComponent: Component is not ready
creating component failed
line 1: module "QtQuick" is not installed

The only little problem now is why is it not finding QtQuick. This does not bother me too much
as long as the main program works. But my question is, as mscore is fully linked with QT5 and there are no linker errors, why is it not finding things it used to.

Thanks again for replying and helping me along.

I think that changing Qt's folder name resulted in this error, because Qt has some hard-coded paths.
See, for example:
http://stackoverflow.com/questions/2905868/change-qt-install-path-after…
http://qt-project.org/doc/qt-5/linux-deployment.html

You can try to add your own qt.conf to Qt bin folder with
[Paths]
Prefix = /home/turtle/Qt5.2.0/5.2.0-rc1/gcc_64/bin

http://qt-project.org/doc/qt-5.0/qtdoc/qt-conf.html

Or you can go back to the previous name of the folder and add in front of your PATH the path to Qt bin folder and set the environment variable QTDIR to Qt folder (for example export QTDIR=/home/turtle/Qt5.2.0/5.2.0/gcc_64)

Hope this helps.
Ciao,
ABL

@ABL: - thank you so much for your suggestions. I really appreciate it when people are helpful, especially as my knowledge of the system is limited.

I hear what you say about Qt hard encoding of name paths. So what I did was to rename the directory back to its original name and then create a link for the name as used in the mscore build.

My thought is that then everything should be accessible by name/path either by Qt or by the make. (actually if I had been thinking right I should have done this in the first place!)

The other thing is that my Qt5.2.0 is part of my local, user filesystem, not a part of the linux system build and is only used during the mscore build. My understanding is that mscore is statically linked so if the build works without error, the program should run and find all its components.

I had been using the renamed Qt5,2,0 system in mscore builds for weeks. My problem happened only after a git pull from MuseScore which lead me to think there might be some kind of problem with MuseScore.

This morning I did a further git pull and make which worked without problem. However calling mscore without changing the qt_plugin_path variable still does not work. The problems persist!

I am thinking that perhaps I should download Qt 5.2 again and re-install it.

Thanks again for helping.

> So what I did was to rename the directory back to its original name and then
> create a link for the name as used in the mscore build.

In principle this should not be necessary, provided that you add Qt bin directory in front of the PATH before compiling MuseScore (and that there is no actual /5.2.0-rc1 folder with Qt programs masking the real one). Possibly, also the QTDIR could be necessary (it works in my Linux environment).

> My understanding is that mscore is statically linked so if the build works
> without error, the program should run and find all its components.

No, the build is not a static build: the library are linked dynamically, as far as I understand. Indeed, the Linux nightly build require the libraries to be installed in order to run (but I never actually used Linux Nightly build, so I can be wrong here).

> I had been using the renamed Qt5,2,0 system in mscore builds for weeks.
> My problem happened only after a git pull from MuseScore which lead me to
> think there might be some kind of problem with MuseScore.

Can you try to make a clean build, i.e. "make clean" before compiling MuseScore again?

> However calling mscore without changing the qt_plugin_path variable still does not work.

I obtain the same problem (missing plugin xcb) in my personal build when I rename the plugin folder inside the Qt folder. Can you check that the name of that folder is really "plugins"?

You can try the "qt.conf" method I was mentioning before, by possibly adding also:
Plugins = /path/to/your/plugin/folder
so that the qt.conf file inside your Qt bin folder reads:
[Paths]
Prefix = /home/turtle/Qt5.2.0/5.2.0/gcc_64/bin
Plugins = /home/turtle/Qt5.2.0/5.2.0/gcc_64/plugins

[adjust path if necessary]

[If this still does not work, try a clean build ("make clean" before compilation) after setting the "qt.conf" file]

Ciao,
ABL

@ABL:

Again thank you for your reply. Here is the latest activity and I am pleased to say, both problems have now gone.

I followed your advice, but with a sledgehammer approach.

Downloaded latest Qt5 from Qt project (Qt5.2.1)
Cloned latest from MuseScore GIT (5b36fbf0f4bdfab14952bbe96f920fede4be260c)

So that both are latest versions.

Did the mscore build and install.

Everything now works without error and without having to change the QT environment. In effect I am now back to where I was, no I am actually better with the latest versions.

Thanks again to everyone who helped me, especially you ABL.