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. Qt SVG isn't working on Ubuntu with Qt 6
Forum Updated to NodeBB v4.3 + New Features

Qt SVG isn't working on Ubuntu with Qt 6

Scheduled Pinned Locked Moved Solved General and Desktop
7 Posts 2 Posters 1.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.
  • D Offline
    D Offline
    Donald Duck
    wrote on last edited by
    #1

    I'm writing a program for Ubuntu in Qt 6 which uses Qt SVG. When I try to run it I get the following error:

    error while loading shared libraries: libQt5Svg.so.5: cannot open shared object file: No such file or directory
    

    So I tried this:

    sudo apt-get install libqt6svg6*
    

    But it didn't help, I still get the same error. So I tried this:

    sudo apt-get install libqt5svg5*
    

    Now I get a different error:

    symbol lookup error: ./FeynmanDiagramEditor: undefined symbol: _ZdlPvm, version Qt_5
    

    This is weird because I'm using Qt 6, so it shouldn't care about Qt 5.

    How do I get this to work?

    Christian EhrlicherC 1 Reply Last reply
    0
    • Christian EhrlicherC Christian Ehrlicher

      Provide a minimal, compilable example.

      D Offline
      D Offline
      Donald Duck
      wrote on last edited by
      #7

      It seems like it was a caching issue. I solved it by deleting the build directory and re-compiling. Thanks for your help.

      1 Reply Last reply
      0
      • D Donald Duck

        I'm writing a program for Ubuntu in Qt 6 which uses Qt SVG. When I try to run it I get the following error:

        error while loading shared libraries: libQt5Svg.so.5: cannot open shared object file: No such file or directory
        

        So I tried this:

        sudo apt-get install libqt6svg6*
        

        But it didn't help, I still get the same error. So I tried this:

        sudo apt-get install libqt5svg5*
        

        Now I get a different error:

        symbol lookup error: ./FeynmanDiagramEditor: undefined symbol: _ZdlPvm, version Qt_5
        

        This is weird because I'm using Qt 6, so it shouldn't care about Qt 5.

        How do I get this to work?

        Christian EhrlicherC Offline
        Christian EhrlicherC Offline
        Christian Ehrlicher
        Lifetime Qt Champion
        wrote on last edited by
        #2

        @Donald-Duck said in Qt SVG isn't working on Ubuntu with Qt 6:

        This is weird because I'm using Qt 6, so it shouldn't care about Qt 5.

        But you use a (dependent) library which is using Qt5 (svg module)

        How do I get this to work?

        Don't use the lib which depends on Qt5 but the correct one which is using Qt6.

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

        D 1 Reply Last reply
        0
        • Christian EhrlicherC Christian Ehrlicher

          @Donald-Duck said in Qt SVG isn't working on Ubuntu with Qt 6:

          This is weird because I'm using Qt 6, so it shouldn't care about Qt 5.

          But you use a (dependent) library which is using Qt5 (svg module)

          How do I get this to work?

          Don't use the lib which depends on Qt5 but the correct one which is using Qt6.

          D Offline
          D Offline
          Donald Duck
          wrote on last edited by
          #3

          @Christian-Ehrlicher How am I using a library that uses Qt 5? I just installed Qt right now, and I only installed Qt 6, I didn't install anything that uses Qt 5. What else do I need to do?

          Christian EhrlicherC 1 Reply Last reply
          0
          • D Donald Duck

            @Christian-Ehrlicher How am I using a library that uses Qt 5? I just installed Qt right now, and I only installed Qt 6, I didn't install anything that uses Qt 5. What else do I need to do?

            Christian EhrlicherC Offline
            Christian EhrlicherC Offline
            Christian Ehrlicher
            Lifetime Qt Champion
            wrote on last edited by
            #4

            @Donald-Duck said in Qt SVG isn't working on Ubuntu with Qt 6:

            What else do I need to do?

            How should we know? The only thing we see is that your app is using a Qt5 library. You have to fix it. We don't have any code nor a simple reproducer.

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

            D 1 Reply Last reply
            0
            • Christian EhrlicherC Christian Ehrlicher

              @Donald-Duck said in Qt SVG isn't working on Ubuntu with Qt 6:

              What else do I need to do?

              How should we know? The only thing we see is that your app is using a Qt5 library. You have to fix it. We don't have any code nor a simple reproducer.

              D Offline
              D Offline
              Donald Duck
              wrote on last edited by Donald Duck
              #5

              @Christian-Ehrlicher How can I figure out why my app is using a Qt 5 library? I didn't do anything related to Qt 5. All I did was install Qt 6 from here (and only selecting things related to Qt 6 in the installer). I installed it on a clean WSL installation, so I don't have anything related to Qt 5 from previously. In my .pro file, all I have is QT += svg, with no reference to Qt 5.

              Christian EhrlicherC 1 Reply Last reply
              0
              • D Donald Duck

                @Christian-Ehrlicher How can I figure out why my app is using a Qt 5 library? I didn't do anything related to Qt 5. All I did was install Qt 6 from here (and only selecting things related to Qt 6 in the installer). I installed it on a clean WSL installation, so I don't have anything related to Qt 5 from previously. In my .pro file, all I have is QT += svg, with no reference to Qt 5.

                Christian EhrlicherC Offline
                Christian EhrlicherC Offline
                Christian Ehrlicher
                Lifetime Qt Champion
                wrote on last edited by
                #6

                Provide a minimal, compilable example.

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

                D 1 Reply Last reply
                0
                • Christian EhrlicherC Christian Ehrlicher

                  Provide a minimal, compilable example.

                  D Offline
                  D Offline
                  Donald Duck
                  wrote on last edited by
                  #7

                  It seems like it was a caching issue. I solved it by deleting the build directory and re-compiling. Thanks for your help.

                  1 Reply Last reply
                  0
                  • D Donald Duck has marked this topic as solved on

                  • Login

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