Qt World Summit: Register Today!

Ubuntu QtQuick deployment, Segmentation fault

  • Hello, trying to deploy an Qt-application from Ubuntu 18.04.2 LTS (bionic) to the same ubuntu version on another computer without Qt installed, but I'm only getting segmentation fault when trying to start the application on the other computer. The application runs fine on the computer with Qt installed.

    I've copied the files that I've seen missing with ldd.
    Backtrace with QT_PLUGINS_DEBUG enabled:

    Starting program: /home/elcomias/Skrivebord/release/myApp 
    [Thread debugging using libthread_db enabled]
    Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
    QFactoryLoader::QFactoryLoader() checking directory path "/home/elcomias/Skrivebord/release/plugins/platforms" ...
    QFactoryLoader::QFactoryLoader() looking at "/home/elcomias/Skrivebord/release/plugins/platforms/libqxcb.so"
    Found metadata in lib /home/elcomias/Skrivebord/release/plugins/platforms/libqxcb.so, metadata=
        "IID": "org.qt-project.Qt.QPA.QPlatformIntegrationFactoryInterface.5.3",
        "MetaData": {
            "Keys": [
        "className": "QXcbIntegrationPlugin",
        "debug": false,
        "version": 329989
    Got keys from plugin meta data ("xcb")
    QFactoryLoader::QFactoryLoader() checking directory path "/home/elcomias/Skrivebord/release/platforms" ...
    loaded library "/home/elcomias/Skrivebord/release/plugins/platforms/libqxcb.so"
    [New Thread 0x7fffeae40700 (LWP 4652)]
    loaded library "Xcursor"
    Thread 1 "myApp" received signal SIGSEGV, Segmentation fault.
    0x00007fffef3c5b28 in ?? () from ./lib/libQt5XcbQpa.so.5
    (gdb) backtrace
    #0  0x00007fffef3c5b28 in ?? () from ./lib/libQt5XcbQpa.so.5
    #1  0x00007fffef3b1650 in ?? () from ./lib/libQt5XcbQpa.so.5
    #2  0x00007fffef3b1728 in ?? () from ./lib/libQt5XcbQpa.so.5
    #3  0x00007fffef3a6df9 in QXcbConnection::QXcbConnection(QXcbNativeInterface*, bool, unsigned int, char const*) ()
       from ./lib/libQt5XcbQpa.so.5
    #4  0x00007fffef3aa4be in QXcbIntegration::QXcbIntegration(QStringList const&, int&, char**) () from ./lib/libQt5XcbQpa.so.5
    #5  0x00007fffef66d2ab in ?? () from /home/elcomias/Skrivebord/release/plugins/platforms/libqxcb.so
    #6  0x00007ffff6d725eb in QPlatformIntegrationFactory::create(QString const&, QStringList const&, int&, char**, QString const&) ()
       from ./lib/libQt5Gui.so.5
    #7  0x00007ffff6d7f8f7 in QGuiApplicationPrivate::createPlatformIntegration() () from ./lib/libQt5Gui.so.5
    #8  0x00007ffff6d809dd in QGuiApplicationPrivate::createEventDispatcher() () from ./lib/libQt5Gui.so.5
    #9  0x00007ffff5c072ff in QCoreApplicationPrivate::init() () from ./lib/libQt5Core.so.5
    #10 0x00007ffff6d8230b in QGuiApplicationPrivate::init() () from ./lib/libQt5Gui.so.5
    #11 0x00007ffff6d82f34 in QGuiApplication::QGuiApplication(int&, char**, int) () from ./lib/libQt5Gui.so.5
    #12 0x000055555555da5c in main ()

  • Lifetime Qt Champion


    Which version of Qt are you using ?
    Is it the one provided by the distribution ?
    Are these two machines different ?
    What about their graphic hardware ?
    What drivers are you running ?

  • I went with another solution installing Ubuntu 16.04 on Virtualbox and then using linuxdeployqt instead. Works perfectly.

Log in to reply