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. Ubuntu 22.04 with Qt 6.3.0 and OpenSSL
Forum Updated to NodeBB v4.3 + New Features

Ubuntu 22.04 with Qt 6.3.0 and OpenSSL

Scheduled Pinned Locked Moved Solved General and Desktop
11 Posts 6 Posters 6.7k Views 3 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.
  • I Offline
    I Offline
    imironchik
    wrote on last edited by
    #1

    On Ubuntu 22.04 OpenSSL installed version is 3, that is not compatible with pre-built Qt binaries. I have installed OpenSSL 1.1 with Qt installer. But I have question: how can I say Qt to load OpenSSL from custom directory?

    1 Reply Last reply
    1
    • I Offline
      I Offline
      imironchik
      wrote on last edited by
      #2

      LD_LIBRARY_PATH solves the problem.

      1 Reply Last reply
      1
      • X Offline
        X Offline
        XaviP
        wrote on last edited by
        #3

        I have installed OpenSSL 1.1 with Qt Maintenance Tool, but I don't find which path has to be added to LD_LIBRARY_PATH. @imironchik can you be more explicit?

        SGaistS 1 Reply Last reply
        0
        • X XaviP

          I have installed OpenSSL 1.1 with Qt Maintenance Tool, but I don't find which path has to be added to LD_LIBRARY_PATH. @imironchik can you be more explicit?

          SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          @XaviP hi and welcome to devnet,

          You need to add the path to the folder containing the OpenSSL libraries.

          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
          • X Offline
            X Offline
            XaviP
            wrote on last edited by XaviP
            #5

            I've tried with:
            export LD_LIBRARY_PATH=/home/my_user/Documents/Qt/Tools/OpenSSL/
            checked with:
            echo $LD_LIBRARY_PATH
            start qtcreator, rebuild and run, but not working yet.

            I've tried too with:
            export LD_LIBRARY_PATH=/home/my_user/Documents/Qt/Tools/OpenSSL/src/
            export LD_LIBRARY_PATH=/home/my_user/Documents/Qt/Tools/OpenSSL/src/ssl/
            even with:
            sudo ldconfig
            after every export, but not working yet.

            [edit]
            the opposite way:
            export LD_LIBRARY_PATH=/usr/lib/x86_64-linux-gnu/libssl.so.3
            doesn’t work either.

            jsulmJ 1 Reply Last reply
            0
            • X XaviP

              I've tried with:
              export LD_LIBRARY_PATH=/home/my_user/Documents/Qt/Tools/OpenSSL/
              checked with:
              echo $LD_LIBRARY_PATH
              start qtcreator, rebuild and run, but not working yet.

              I've tried too with:
              export LD_LIBRARY_PATH=/home/my_user/Documents/Qt/Tools/OpenSSL/src/
              export LD_LIBRARY_PATH=/home/my_user/Documents/Qt/Tools/OpenSSL/src/ssl/
              even with:
              sudo ldconfig
              after every export, but not working yet.

              [edit]
              the opposite way:
              export LD_LIBRARY_PATH=/usr/lib/x86_64-linux-gnu/libssl.so.3
              doesn’t work either.

              jsulmJ Offline
              jsulmJ Offline
              jsulm
              Lifetime Qt Champion
              wrote on last edited by jsulm
              #6

              @XaviP Which folder contains the SSL libraries (*.so files)?
              Also, if it does not work when running the app from QtCreator you need to update PATH in Run configuration of your project in QtCreator.

              https://forum.qt.io/topic/113070/qt-code-of-conduct

              1 Reply Last reply
              1
              • X Offline
                X Offline
                XaviP
                wrote on last edited by XaviP
                #7
                • After installing OpenSSL 1.1, I have SSL libraries at /usr/local/lib/libssl.so
                  (the original system ones (ssl3) are at /usr/lib/x86_64-linux-gnu/libssl.so)
                • The error, among others, when running the app from qtcreator is:
                  "qt.tlsbackend.ossl: Incompatible version of OpenSSL (built with OpenSSL 1.x, runtime version is >= 3.x)"
                • So I need to update Run configuration of the project, but I don't understand how. I've tried with "Environment", adding LD_LIBRARY_PATH=usr/local/lib/libssl.so, with no results.
                jsulmJ 1 Reply Last reply
                0
                • X XaviP
                  • After installing OpenSSL 1.1, I have SSL libraries at /usr/local/lib/libssl.so
                    (the original system ones (ssl3) are at /usr/lib/x86_64-linux-gnu/libssl.so)
                  • The error, among others, when running the app from qtcreator is:
                    "qt.tlsbackend.ossl: Incompatible version of OpenSSL (built with OpenSSL 1.x, runtime version is >= 3.x)"
                  • So I need to update Run configuration of the project, but I don't understand how. I've tried with "Environment", adding LD_LIBRARY_PATH=usr/local/lib/libssl.so, with no results.
                  jsulmJ Offline
                  jsulmJ Offline
                  jsulm
                  Lifetime Qt Champion
                  wrote on last edited by
                  #8

                  @XaviP said in Ubuntu 22.04 with Qt 6.3.0 and OpenSSL:

                  LD_LIBRARY_PATH=usr/local/lib/libssl.so, with no results.

                  This is wrong - you add folders to that path (and you also forgot / at the beginning of the path):

                  LD_LIBRARY_PATH=/usr/local/lib
                  

                  https://forum.qt.io/topic/113070/qt-code-of-conduct

                  1 Reply Last reply
                  3
                  • X Offline
                    X Offline
                    XaviP
                    wrote on last edited by
                    #9

                    Yes, now it's solved. Thank you very much!

                    PatGP 1 Reply Last reply
                    0
                    • X XaviP

                      Yes, now it's solved. Thank you very much!

                      PatGP Offline
                      PatGP Offline
                      PatG
                      wrote on last edited by
                      #10

                      @XaviP This worked for me...

                      Download libssl1.1_1.1.1f-1ubuntu2_amd64.deb from official repository:
                      wget http://archive.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.1f-1ubuntu2_amd64.deb

                      Install it:
                      sudo dpkg -i libssl1.1_1.1.1f-1ubuntu2_amd64.deb

                      keksi venksiK 1 Reply Last reply
                      3
                      • PatGP PatG

                        @XaviP This worked for me...

                        Download libssl1.1_1.1.1f-1ubuntu2_amd64.deb from official repository:
                        wget http://archive.ubuntu.com/ubuntu/pool/main/o/openssl/libssl1.1_1.1.1f-1ubuntu2_amd64.deb

                        Install it:
                        sudo dpkg -i libssl1.1_1.1.1f-1ubuntu2_amd64.deb

                        keksi venksiK Offline
                        keksi venksiK Offline
                        keksi venksi
                        wrote on last edited by
                        #11

                        @PatG thanks, This helped me

                        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