<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[missing Qt platform plugin xcb]]></title><description><![CDATA[<p dir="auto">I built an application on CentOS 7, and when I try to run it on a non-development CentOS 7 machine, I get the following error:</p>
<pre><code>This application failed to start because it could not find or load the Qt platform plugin "xcb" in "".

Available platform plugins are: eglfs, linuxfb, minimal, minimalegl, offscreen, xcb.
</code></pre>
<p dir="auto">Within my application's directory, I have distributed the following files:</p>
<p dir="auto">Application<br />
<a href="http://Application.sh" target="_blank" rel="noopener noreferrer nofollow ugc">Application.sh</a><br />
libQt5Core.so.5<br />
libQt5DBus.so.5<br />
libQt5Gui.so.5<br />
libQt5Network.so.5<br />
libQt5Widgets.so.5<br />
<a href="http://libxcb.so" target="_blank" rel="noopener noreferrer nofollow ugc">libxcb.so</a><br />
libicu*<br />
... application specific libs ...<br />
platforms/libqeglfs.so<br />
platforms/libqlinuxfb.so<br />
platforms/libqminimal.so<br />
platforms/libqminimalegl.so<br />
platforms/libqoffscreen.so<br />
platforms/libqxcb.so</p>
<p dir="auto">Within <a href="http://Application.sh" target="_blank" rel="noopener noreferrer nofollow ugc">Application.sh</a>, it sets the path to look for application libraries within the same directory:</p>
<pre><code>export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:.
./Application

</code></pre>
<p dir="auto">I've seen this question asked many times before, but none of those solutions seem to fix this problem. It seems to be finding the xcb platform, because it identifies it as available. Why does it give an error?</p>
]]></description><link>https://forum.qt.io/topic/67968/missing-qt-platform-plugin-xcb</link><generator>RSS for Node</generator><lastBuildDate>Tue, 09 Jun 2026 17:26:26 GMT</lastBuildDate><atom:link href="https://forum.qt.io/topic/67968.rss" rel="self" type="application/rss+xml"/><pubDate>Mon, 06 Jun 2016 13:55:40 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to missing Qt platform plugin xcb on Fri, 01 Jul 2016 15:34:09 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/hskoglund">@<bdi>hskoglund</bdi></a></p>
<p dir="auto">Ah!  I wasn't aware the installer embeds paths into the shared objects.  I moved the files around a bit after the install so now they've got invalid paths in them.</p>
<p dir="auto">Thanks for the info!</p>
]]></description><link>https://forum.qt.io/post/335862</link><guid isPermaLink="true">https://forum.qt.io/post/335862</guid><dc:creator><![CDATA[zd3nik]]></dc:creator><pubDate>Fri, 01 Jul 2016 15:34:09 GMT</pubDate></item><item><title><![CDATA[Reply to missing Qt platform plugin xcb on Fri, 01 Jul 2016 02:05:18 GMT]]></title><description><![CDATA[<p dir="auto">Hi, there are several other options available to fix this, for example, you could create a <strong>qt.conf</strong> file (and place it next to your application's .exe file) with this content:</p>
<pre><code>[Paths]
Plugins=plugins
</code></pre>
<p dir="auto">or you could binary edit libQt5Core.so.5, it has a setting created by Qt's installer that points to 5.6.1's <em>prefix</em> directory, to see it type <code>strings libQt5Core.so.5 | grep prfxpath</code><br />
(Qt adds <strong>plugins</strong> to that path to get 5.6.1's plugins)</p>
<p dir="auto">or you could do a call to <code>QCoreApplication::addLibraryPath("plugins");</code> just before QApplication a(argc, argv); in your main.cpp</p>
<p dir="auto">and as a final option, which might be the easiest, instead of having a directory structure with a <em>plugins</em> directory containing the <em>platforms</em> subdirectory etc.. move all those subdirectories up one level, so that there is a <em>platforms</em> directory visible from your application's .exe file.<br />
(That would be equivalent of creating a qt.conf file with this contents:</p>
<pre><code>[Paths]
Plugins=.
</code></pre>
<p dir="auto">Hope this helps!</p>
]]></description><link>https://forum.qt.io/post/335748</link><guid isPermaLink="true">https://forum.qt.io/post/335748</guid><dc:creator><![CDATA[hskoglund]]></dc:creator><pubDate>Fri, 01 Jul 2016 02:05:18 GMT</pubDate></item><item><title><![CDATA[Reply to missing Qt platform plugin xcb on Fri, 01 Jul 2016 00:45:07 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/mrjj">@<bdi>mrjj</bdi></a><br />
I am having a very similar problem.  The application is built on CentOS 7.  But we're also running the application on the system it was built on.</p>
<p dir="auto">ldd doesn't show anything missing.  QTDIR is set to the qt 5.6.1 dir which contains <code>lib</code>, <code>include</code>, <code>bin</code>, <code>plugins</code>, etc.</p>
<p dir="auto"><em>The error:</em></p>
<pre><code>$ LD_LIBRARY_PATH=. ./application
This application failed to start because it could not find or load the Qt platform plugin "xcb"
in "".

Reinstalling the application may fix this problem.
Aborted (core dumped)
</code></pre>
<p dir="auto"><em>ldd output:</em></p>
<pre><code>$ LD_LIBRARY_PATH=. ldd ./application 
	linux-vdso.so.1 =&gt;  (0x00007ffd6068b000)
	libApplication.so.1 =&gt; ./libApplication.so.1 (0x00007ffa421b9000)
	libhunspell.so.1 =&gt; ./libhunspell.so.1 (0x00007ffa3e54e000)
	libprotobuf.so.8 =&gt; ./libprotobuf.so.8 (0x00007ffa3e104000)
	libopencv_core.so.3.0 =&gt; ./libopencv_core.so.3.0 (0x00007ffa3dbfd000)
	libQt5Widgets.so.5 =&gt; &lt;QTDIR&gt;/lib/libQt5Widgets.so.5 (0x00007ffa3d386000)
	libQt5Gui.so.5 =&gt; &lt;QTDIR&gt;/lib/libQt5Gui.so.5 (0x00007ffa3cb8d000)
	libQt5Xml.so.5 =&gt; &lt;QTDIR&gt;/lib/libQt5Xml.so.5 (0x00007ffa3c952000)
	libQt5Core.so.5 =&gt; &lt;QTDIR&gt;/lib/libQt5Core.so.5 (0x00007ffa3c23e000)
	libGL.so.1 =&gt; /lib64/libGL.so.1 (0x00007ffa3bf8d000)
	libpthread.so.0 =&gt; /lib64/libpthread.so.0 (0x00007ffa3bd71000)
	libstdc++.so.6 =&gt; /lib64/libstdc++.so.6 (0x00007ffa3ba69000)
	libm.so.6 =&gt; /lib64/libm.so.6 (0x00007ffa3b766000)
	libgcc_s.so.1 =&gt; /lib64/libgcc_s.so.1 (0x00007ffa3b550000)
	libc.so.6 =&gt; /lib64/libc.so.6 (0x00007ffa3b18e000)
	libuuid.so.1 =&gt; /lib64/libuuid.so.1 (0x00007ffa3af88000)
	librt.so.1 =&gt; /lib64/librt.so.1 (0x00007ffa3ad80000)
	libQt5XmlPatterns.so.5 =&gt; &lt;QTDIR&gt;/lib/libQt5XmlPatterns.so.5 (0x00007ffa3a7ab000)
	libQt5Network.so.5 =&gt; &lt;QTDIR&gt;/lib/libQt5Network.so.5 (0x00007ffa3a44a000)
	libQt5Sql.so.5 =&gt; &lt;QTDIR&gt;/lib/libQt5Sql.so.5 (0x00007ffa3a206000)
	libssl.so.1.0.0 =&gt; ./libssl.so.1.0.0 (0x00007ffa39f94000)
	libcrypto.so.1.0.0 =&gt; ./libcrypto.so.1.0.0 (0x00007ffa36a4f000)
	libdl.so.2 =&gt; /lib64/libdl.so.2 (0x00007ffa3684b000)
	libz.so.1 =&gt; /lib64/libz.so.1 (0x00007ffa36635000)
	libgobject-2.0.so.0 =&gt; /lib64/libgobject-2.0.so.0 (0x00007ffa363e4000)
	libgthread-2.0.so.0 =&gt; /lib64/libgthread-2.0.so.0 (0x00007ffa361e2000)
	libglib-2.0.so.0 =&gt; /lib64/libglib-2.0.so.0 (0x00007ffa35eab000)
	libXext.so.6 =&gt; /lib64/libXext.so.6 (0x00007ffa35c98000)
	libX11.so.6 =&gt; /lib64/libX11.so.6 (0x00007ffa3595a000)
	libicui18n.so.56 =&gt; ./libicui18n.so.56 (0x00007ffa354bf000)
	libicuuc.so.56 =&gt; ./libicuuc.so.56 (0x00007ffa35107000)
	libicudata.so.56 =&gt; ./libicudata.so.56 (0x00007ffa33724000)
	/lib64/ld-linux-x86-64.so.2 (0x00007ffa4354d000)
	libexpat.so.1 =&gt; /lib64/libexpat.so.1 (0x00007ffa334f9000)
	libglapi.so.0 =&gt; /lib64/libglapi.so.0 (0x00007ffa332cb000)
	libselinux.so.1 =&gt; /lib64/libselinux.so.1 (0x00007ffa330a6000)
	libXdamage.so.1 =&gt; /lib64/libXdamage.so.1 (0x00007ffa32ea2000)
	libXfixes.so.3 =&gt; /lib64/libXfixes.so.3 (0x00007ffa32c9c000)
	libX11-xcb.so.1 =&gt; /lib64/libX11-xcb.so.1 (0x00007ffa32a9a000)
	libxcb-glx.so.0 =&gt; /lib64/libxcb-glx.so.0 (0x00007ffa3287f000)
	libxcb-dri2.so.0 =&gt; /lib64/libxcb-dri2.so.0 (0x00007ffa3267a000)
	libxcb-dri3.so.0 =&gt; /lib64/libxcb-dri3.so.0 (0x00007ffa32477000)
	libxcb-present.so.0 =&gt; /lib64/libxcb-present.so.0 (0x00007ffa32273000)
	libxcb-randr.so.0 =&gt; /lib64/libxcb-randr.so.0 (0x00007ffa32065000)
	libxcb-xfixes.so.0 =&gt; /lib64/libxcb-xfixes.so.0 (0x00007ffa31e5d000)
	libxcb-render.so.0 =&gt; /lib64/libxcb-render.so.0 (0x00007ffa31c52000)
	libxcb-shape.so.0 =&gt; /lib64/libxcb-shape.so.0 (0x00007ffa31a4e000)
	libxcb-sync.so.1 =&gt; /lib64/libxcb-sync.so.1 (0x00007ffa31847000)
	libxcb.so.1 =&gt; /lib64/libxcb.so.1 (0x00007ffa31624000)
	libxshmfence.so.1 =&gt; /lib64/libxshmfence.so.1 (0x00007ffa31421000)
	libXxf86vm.so.1 =&gt; /lib64/libXxf86vm.so.1 (0x00007ffa3121b000)
	libdrm.so.2 =&gt; /lib64/libdrm.so.2 (0x00007ffa3100d000)
	libffi.so.6 =&gt; /lib64/libffi.so.6 (0x00007ffa30e04000)
	libpcre.so.1 =&gt; /lib64/libpcre.so.1 (0x00007ffa30ba3000)
	liblzma.so.5 =&gt; /lib64/liblzma.so.5 (0x00007ffa3097d000)
	libXau.so.6 =&gt; /lib64/libXau.so.6 (0x00007ffa30779000)
</code></pre>
<p dir="auto"><em>If I set QT_QPA_PLATFORM_PLUGIN_PATH it works.</em></p>
<pre><code>QT_QPA_PLATFORM_PLUGIN_PATH=$QTDIR/plugins LD_LIBRARY_PATH=. ./application
-- application runs without errors --
</code></pre>
<p dir="auto">This started happening when we switched from qt 5.2.1 to 5.6.1-1.  We would build qt 5.2.1 ourselves from source (so we could link our own build of SSL libs).  On 5.6.1 we're using the qt installer to get the libs instead of building them ourselves because we no longer need to use custom built SSL libs.</p>
<p dir="auto">We have a <code>plugins</code> directory relative to the application binary.  So I thought maybe that was confusing Qt's plugin path search, so I've tried linking  the content of QTDIR/plugins into the application plugins directory:</p>
<pre><code>ln -s $QTDIR/plugins/* ./plugins/
</code></pre>
<p dir="auto">But that didn't work.  The only thing I've found, so far, that works is setting QT_QPA_PLATFORM_PLUGIN_PATH.  We can do that, but it seems like there's something wrong here and I'd like to figure out what it is.</p>
<p dir="auto">Any ideas?</p>
]]></description><link>https://forum.qt.io/post/335746</link><guid isPermaLink="true">https://forum.qt.io/post/335746</guid><dc:creator><![CDATA[zd3nik]]></dc:creator><pubDate>Fri, 01 Jul 2016 00:45:07 GMT</pubDate></item><item><title><![CDATA[Reply to missing Qt platform plugin xcb on Mon, 06 Jun 2016 16:46:13 GMT]]></title><description><![CDATA[<p dir="auto"><a class="plugin-mentions-user plugin-mentions-a" href="/user/gregb">@<bdi>GregB</bdi></a><br />
super. Good found :)</p>
]]></description><link>https://forum.qt.io/post/331653</link><guid isPermaLink="true">https://forum.qt.io/post/331653</guid><dc:creator><![CDATA[mrjj]]></dc:creator><pubDate>Mon, 06 Jun 2016 16:46:13 GMT</pubDate></item><item><title><![CDATA[Reply to missing Qt platform plugin xcb on Mon, 06 Jun 2016 16:44:36 GMT]]></title><description><![CDATA[<p dir="auto">That did it, thank you! It was missing "libQt5XcbQpa.so.5"</p>
]]></description><link>https://forum.qt.io/post/331652</link><guid isPermaLink="true">https://forum.qt.io/post/331652</guid><dc:creator><![CDATA[GregB]]></dc:creator><pubDate>Mon, 06 Jun 2016 16:44:36 GMT</pubDate></item><item><title><![CDATA[Reply to missing Qt platform plugin xcb on Mon, 06 Jun 2016 14:25:36 GMT]]></title><description><![CDATA[<p dir="auto">Hi<br />
Have you tried to see with ldd if it misses a plugin or so file for<br />
xcb on the machine where it dont start.</p>
]]></description><link>https://forum.qt.io/post/331636</link><guid isPermaLink="true">https://forum.qt.io/post/331636</guid><dc:creator><![CDATA[mrjj]]></dc:creator><pubDate>Mon, 06 Jun 2016 14:25:36 GMT</pubDate></item></channel></rss>