Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. QtCreator doesn't startup after updating Qt on OpenSuse Tumbleweed.. libQt5XcbQpa.so.5: version `Qt_5_PRIVATE_API' not found
QtWS25 Last Chance

QtCreator doesn't startup after updating Qt on OpenSuse Tumbleweed.. libQt5XcbQpa.so.5: version `Qt_5_PRIVATE_API' not found

Scheduled Pinned Locked Moved Unsolved Qt Creator and other tools
4 Posts 2 Posters 1.4k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • H Offline
    H Offline
    hari83
    wrote on 7 Feb 2021, 23:07 last edited by hari83 2 Jul 2021, 23:11
    #1

    Hello,
    The problem I'm having has been resolved here in the past but only a work around works for me.

    Problem: QtCreator throws error at launch on Opensuse Tumbleweed, kernel 5.10.12, KDE Plasma desktop

    QFactoryLoader::QFactoryLoader() looking at "/opt/Qt/Tools/QtCreator/lib/Qt/plugins/platforms/libqxcb.so"
    Found metadata in lib /opt/Qt/Tools/QtCreator/lib/Qt/plugins/platforms/libqxcb.so, metadata=
    {
    .
    .
    }
    
    Got keys from plugin meta data ("xcb")
    QFactoryLoader::QFactoryLoader() checking directory path "/opt/Qt/Tools/QtCreator/bin/platforms" ...
    Cannot load library /opt/Qt/Tools/QtCreator/lib/Qt/plugins/platforms/libqxcb.so: (/usr/lib64/libQt5XcbQpa.so.5: version `Qt_5_PRIVATE_API' not found (required by /opt/Qt/Tools/QtCreator/lib/Qt/plugins/platforms/libqxcb.so))
    QLibraryPrivate::loadPlugin failed on "/opt/Qt/Tools/QtCreator/lib/Qt/plugins/platforms/libqxcb.so" : "Cannot load library /opt/Qt/Tools/QtCreator/lib/Qt/plugins/platforms/libqxcb.so: (/usr/lib64/libQt5XcbQpa.so.5: version `Qt_5_PRIVATE_API' not found (required by /opt/Qt/Tools/QtCreator/lib/Qt/plugins/platforms/libqxcb.so))"
    qt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "" even though it was found.
    This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.
    

    Reason: libqxcb.so looks for the wrong libQt5XcbQpa.so.5 at the default path i.e /usr/lib64. But 'Qt_5_PRIVATE_API' is not there in this file. It's in the file at '/opt/Qt/Tools/QtCreator/lib/Qt/lib/libQt5XcbQpa.so.5'.
    I found this out by 'ldd' on the xcb library & by doing 'strings' on the target library.

    Solution: add the path to the correct Qt-bundled version of target libQt5XcbQpa.so.5 to LD_LIBRARY_PATH, in a startup script. This works for me.
    One can also export this path to QT_PLUGIN_PATH during startup, as per this solution, but it didn't work for me.

    But now when I restart the machine, the KDE Plasma does not launch window system & log me in. It's due to some conflict caused by updating LD_LIBRARY_PATH during startup. KDE works fine when I revert this update at startup.
    This was the only solution that worked in fixing the QtCreator launch issue but causes other serious issues.. So I can't use it permanently.

    Question:

    1. Is there a list of environment variables that are important for QtCreator at launch? Anything other than updating LD_LIBRARY_PATH that might work? Any other way to specify library path for Qt Tools?
    2. Is there a way to setup a *.conf file for QtCreator?

    I tried looking up manuals/documentation on Qt, nothing there.. I'd be really grateful for any advice or help!

    1 Reply Last reply
    0
    • S Offline
      S Offline
      SGaist
      Lifetime Qt Champion
      wrote on 8 Feb 2021, 19:28 last edited by
      #2

      Hi and welcome to devnet,

      Don't you have a shell script in the same folder as the Qt Creator binary ? If so, use it to start Qt Creator, it should modify the environment so it loads the correct libraries without messing up your system.

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0
      • H Offline
        H Offline
        hari83
        wrote on 8 Feb 2021, 22:11 last edited by
        #3

        Hi,
        I suppose that's good enough a work around!
        I still get to use QtCreator on KDE.. But I am still curious to know what environment variables Qt tools use.. Any suggestions on where to look?
        Thanks a lot! :-)

        1 Reply Last reply
        0
        • S Offline
          S Offline
          SGaist
          Lifetime Qt Champion
          wrote on 9 Feb 2021, 06:08 last edited by
          #4

          That's not a workaround, the script is there to ensure the adequate libraries are used. For example, binaries installation of Firefox do the same.

          You can read it to see how it works.

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          1

          3/4

          8 Feb 2021, 22:11

          • Login

          • Login or register to search.
          3 out of 4
          • First post
            3/4
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved