Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Find out which library is causing "Cannot mix incompatible Qt library"
Forum Updated to NodeBB v4.3 + New Features

Find out which library is causing "Cannot mix incompatible Qt library"

Scheduled Pinned Locked Moved Solved General and Desktop
7 Posts 5 Posters 21.9k Views 1 Watching
  • 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.
  • S Offline
    S Offline
    Sacha Hony
    wrote on last edited by
    #1

    Hello,

    I have been fighting with this message:
    "Cannot mix incompatible Qt library (version 0x50d01) with this library (version 0x50d02)"
    after updating all qt packages. I compiled the individual packages found here:
    http://download.qt.io/official_releases/qt/5.13/5.13.2/submodules/

    I do not see any old version libQt5*.so file on my system.

    I have been reading the forums but cannot find an answer.
    I have tried setting QT_PLUGINS_DEBUG and inspected the output.
    I have run ldd on the executable (goldendict) but neither helps me to figure out what is wrong.
    Is there a way to determine which file is causing this message?

    Thank you for any help.

    1 Reply Last reply
    0
    • JonBJ JonB

      @Christian-Ehrlicher
      OP says he has done that.

      @Sacha-Hony
      You might post the output from ldd, and from QT_PLUGINS_DEBUG, in case someone else spots something. If it's not too voluminous....

      You might run your app under strace, if you're lucky the last library you see it load might be the offending one....

      You might uninstall your Qt completely, check your machine for any remaining Qt libraries anywhere, then reinstall.

      grep is not going to help you here, as you're looking for some binary bytes in binaries,

      I don't know whether Qt actually stores its version number as any recognisable "resource" on the library files, like you might on Windows. We'd need something like that to do a search.

      From a search your goldendict looks like it was last Qt 5.5-ish 6 years ago, that might not be great against latest Qt?

      S Offline
      S Offline
      Sacha Hony
      wrote on last edited by
      #6

      @JonB Hi,

      Thank you for your help. I figured out what went wrong. I compiled the packages with the old libraries and development headers still installed. Apparently somehow this confused the resulting libraries. I have uninstalled the developement packages while re-compiling and the resulting libraries work.

      To go back to your suggestions and the recommendations i found in the forum:
      I had already inspected the output from
      ldd,
      running with the QT_DEBUG_PLUGINS=1
      I grepped through the output from strace.
      And I ran the binary under gdb
      all of those did not help me to track down the culprit

      It would be very helpful if the error message contained more information:
      An exception occurred while loading /usr/lib64/qt5/plugins/XXX.so
      Cannot mix incompatible ...
      From reading the web forums I believe this change would help more users.

      Also I did not find a clear description on the web in which order one is supposed to compile the individual modules in order to get a fully functional QT5 environment.

      Still problem seems to be solved,

      Sacha

      Pablo J. RoginaP 1 Reply Last reply
      1
      • dheerendraD Offline
        dheerendraD Offline
        dheerendra
        Qt Champions 2022
        wrote on last edited by
        #2

        Do you have two versions of Qt installed on your system ? Did you copy the shared libraries from somewhere else ?

        Dheerendra
        @Community Service
        Certified Qt Specialist
        http://www.pthinks.com

        S 1 Reply Last reply
        0
        • dheerendraD dheerendra

          Do you have two versions of Qt installed on your system ? Did you copy the shared libraries from somewhere else ?

          S Offline
          S Offline
          Sacha Hony
          wrote on last edited by
          #3

          @dheerendra

          I have only one version installed and I compiled the packages locally before installing. All libraries listed by ldd are from version 5.13.2.

          The error would be much more helpful if it would list the file in which version 0x50d01 is found. Can I use grep to find out the offending library?

          1 Reply Last reply
          0
          • Christian EhrlicherC Offline
            Christian EhrlicherC Offline
            Christian Ehrlicher
            Lifetime Qt Champion
            wrote on last edited by
            #4

            Then maybe a plugin is loading a wrong library - try with QT_DEBUG_PLUGINS=1 as env var.

            Qt Online Installer direct download: https://download.qt.io/official_releases/online_installers/
            Visit the Qt Academy at https://academy.qt.io/catalog

            JonBJ 1 Reply Last reply
            1
            • Christian EhrlicherC Christian Ehrlicher

              Then maybe a plugin is loading a wrong library - try with QT_DEBUG_PLUGINS=1 as env var.

              JonBJ Offline
              JonBJ Offline
              JonB
              wrote on last edited by JonB
              #5

              @Christian-Ehrlicher
              OP says he has done that.

              @Sacha-Hony
              You might post the output from ldd, and from QT_PLUGINS_DEBUG, in case someone else spots something. If it's not too voluminous....

              You might run your app under strace, if you're lucky the last library you see it load might be the offending one....

              You might uninstall your Qt completely, check your machine for any remaining Qt libraries anywhere, then reinstall.

              grep is not going to help you here, as you're looking for some binary bytes in binaries,

              I don't know whether Qt actually stores its version number as any recognisable "resource" on the library files, like you might on Windows. We'd need something like that to do a search.

              From a search your goldendict looks like it was last Qt 5.5-ish 6 years ago, that might not be great against latest Qt?

              S 1 Reply Last reply
              1
              • JonBJ JonB

                @Christian-Ehrlicher
                OP says he has done that.

                @Sacha-Hony
                You might post the output from ldd, and from QT_PLUGINS_DEBUG, in case someone else spots something. If it's not too voluminous....

                You might run your app under strace, if you're lucky the last library you see it load might be the offending one....

                You might uninstall your Qt completely, check your machine for any remaining Qt libraries anywhere, then reinstall.

                grep is not going to help you here, as you're looking for some binary bytes in binaries,

                I don't know whether Qt actually stores its version number as any recognisable "resource" on the library files, like you might on Windows. We'd need something like that to do a search.

                From a search your goldendict looks like it was last Qt 5.5-ish 6 years ago, that might not be great against latest Qt?

                S Offline
                S Offline
                Sacha Hony
                wrote on last edited by
                #6

                @JonB Hi,

                Thank you for your help. I figured out what went wrong. I compiled the packages with the old libraries and development headers still installed. Apparently somehow this confused the resulting libraries. I have uninstalled the developement packages while re-compiling and the resulting libraries work.

                To go back to your suggestions and the recommendations i found in the forum:
                I had already inspected the output from
                ldd,
                running with the QT_DEBUG_PLUGINS=1
                I grepped through the output from strace.
                And I ran the binary under gdb
                all of those did not help me to track down the culprit

                It would be very helpful if the error message contained more information:
                An exception occurred while loading /usr/lib64/qt5/plugins/XXX.so
                Cannot mix incompatible ...
                From reading the web forums I believe this change would help more users.

                Also I did not find a clear description on the web in which order one is supposed to compile the individual modules in order to get a fully functional QT5 environment.

                Still problem seems to be solved,

                Sacha

                Pablo J. RoginaP 1 Reply Last reply
                1
                • S Sacha Hony

                  @JonB Hi,

                  Thank you for your help. I figured out what went wrong. I compiled the packages with the old libraries and development headers still installed. Apparently somehow this confused the resulting libraries. I have uninstalled the developement packages while re-compiling and the resulting libraries work.

                  To go back to your suggestions and the recommendations i found in the forum:
                  I had already inspected the output from
                  ldd,
                  running with the QT_DEBUG_PLUGINS=1
                  I grepped through the output from strace.
                  And I ran the binary under gdb
                  all of those did not help me to track down the culprit

                  It would be very helpful if the error message contained more information:
                  An exception occurred while loading /usr/lib64/qt5/plugins/XXX.so
                  Cannot mix incompatible ...
                  From reading the web forums I believe this change would help more users.

                  Also I did not find a clear description on the web in which order one is supposed to compile the individual modules in order to get a fully functional QT5 environment.

                  Still problem seems to be solved,

                  Sacha

                  Pablo J. RoginaP Offline
                  Pablo J. RoginaP Offline
                  Pablo J. Rogina
                  wrote on last edited by
                  #7

                  @Sacha-Hony said in Find out which library is causing "Cannot mix incompatible Qt library":

                  seems to be solved,

                  so please don't forget to mark your post as such! Thanks.

                  Upvote the answer(s) that helped you solve the issue
                  Use "Topic Tools" button to mark your post as Solved
                  Add screenshots via postimage.org
                  Don't ask support requests via chat/PM. Please use the forum so others can benefit from the solution in the future

                  1 Reply Last reply
                  0

                  • Login

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