Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Installation and Deployment
  4. Qt4 Cross compile Error
Qt 6.11 is out! See what's new in the release blog

Qt4 Cross compile Error

Scheduled Pinned Locked Moved Solved Installation and Deployment
7 Posts 2 Posters 990 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.
  • P Offline
    P Offline
    programsc
    wrote on last edited by
    #1

    I had an error while building qt to send E-mail using SMTP in Qt on Arm Board.
    We proceeded as follows. What's the problem?

    1. Download openssl (Openssl ver: 1.1.1d)

    2. Openssl cross compile
      ./Configue linux-arm4 -march=armv5te shared --cross-complie-prifix=/home/use/Toolchain/gcc-4.4.4-glibc-2-11.1-multilib-1.0/arm-fsl-linux/arm- linux- --prefix=/home/use/build_openssl

    3. build OK (create /home/use/build_openssl/lib/libcrypto.so and /home/use/build_openssl/lib/libssl.so)

    4. qt4.8.7 build in QT_Source folder.
      ./configue --prefix=/home/use/qt_build -embedded arm -xplatform qws/linux-arm-gnueabi-g++ -release -opensource -shared -confirm-license -no-largefile -no-accessibility -no-qt3support - no-multimedia -no-audio-backend -no-phonon -no-webkit -no-javascript-jit -no-script -no-scripttools -no-declarative -no-declarative-debug -system-zlib -system-libpng - system-libjpeg -no-libtiff -no-libtiff -no-libmng -no-gif -nis -no-cups -qt-mouse-tslib -nomake demos -nomake examples -qt-gfx-transformed -qt-freetype -v - svg -optimized-qmake -no-pch -no-nis OPENSSL_LIB="-L/home/use/build_openssl/lib -lssl -lcrypto" -openssl-linked

    5. An error occurred during Qt Build
      sl/qsslcertificate.cpp: In member function 'QByteArray QSslCertificate::version() const':
      ssl/qsslcertificate.cpp:264: error: invalid use of incomplete type 'struct x509_st'
      ../../include/QtNetwork/../../src/network/ssl/qsslcertificate.h:53: error: forward declaration of 'struct x509_st'
      ssl/qsslcertificate.cpp: In member function 'QByteArray QSslCertificate::serialNumber() const':
      ssl/qsslcertificate.cpp:279: error: invalid use of incomplete type 'struct x509_st'
      ../../include/QtNetwork/../../src/network/ssl/qsslcertificate.h:53: error: forward declaration of 'struct x509_st'
      ssl/qsslcertificate.cpp: In member function 'QSslKey QSslCertificate::publicKey() const':
      ssl/qsslcertificate.cpp:492: error: invalid use of incomplete type 'struct x509_st'
      ../../include/QtNetwork/../../src/network/ssl/qsslcertificate.h:53: error: forward declaration of 'struct x509_st'
      ssl/qsslcertificate.cpp:496: error: invalid use of incomplete type 'struct evp_pkey_st'
      /home/gene/share_folder/QT4.8.7_with_Openssl/build_openssl/include/openssl/ossl_typ.h:93: error: forward declaration of 'struct evp_pkey_st'
      ssl/qsslcertificate.cpp:500: error: invalid use of incomplete type 'struct evp_pkey_st'
      /home/gene/share_folder/QT4.8.7_with_Openssl/build_openssl/include/openssl/ossl_typ.h:93: error: forward declaration of 'struct evp_pkey_st'
      ssl/qsslcertificate.cpp:504: error: invalid use of incomplete type 'struct evp_pkey_st'
      /home/gene/share_folder/QT4.8.7_with_Openssl/build_openssl/include/openssl/ossl_typ.h:93: error: forward declaration of 'struct evp_pkey_st'
      Makefile:16867: recipe for target '.obj/release-shared-emb-arm/qsslcertificate.o' failed
      make[1]: *** [.obj/release-shared-emb-arm/qsslcertificate.o] Error 1
      make[1]: exit directory '/home/gene/share_folder/QT4.8.7_with_Openssl/QT_Source/qt-everywhere-opensource-src-4.8.7/src/network'
      Makefile:288: recipe for target 'sub-network-install_subtargets-ordered' failed
      make: *** [sub-network-install_subtargets-ordered] Error 2

    jsulmJ 1 Reply Last reply
    0
    • P programsc

      @jsulm

      Yes, i proceeded with make after make clean

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

      @programsc No, what I mean: delete the whole build folder and start from scratch

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

      P 1 Reply Last reply
      0
      • P programsc

        I had an error while building qt to send E-mail using SMTP in Qt on Arm Board.
        We proceeded as follows. What's the problem?

        1. Download openssl (Openssl ver: 1.1.1d)

        2. Openssl cross compile
          ./Configue linux-arm4 -march=armv5te shared --cross-complie-prifix=/home/use/Toolchain/gcc-4.4.4-glibc-2-11.1-multilib-1.0/arm-fsl-linux/arm- linux- --prefix=/home/use/build_openssl

        3. build OK (create /home/use/build_openssl/lib/libcrypto.so and /home/use/build_openssl/lib/libssl.so)

        4. qt4.8.7 build in QT_Source folder.
          ./configue --prefix=/home/use/qt_build -embedded arm -xplatform qws/linux-arm-gnueabi-g++ -release -opensource -shared -confirm-license -no-largefile -no-accessibility -no-qt3support - no-multimedia -no-audio-backend -no-phonon -no-webkit -no-javascript-jit -no-script -no-scripttools -no-declarative -no-declarative-debug -system-zlib -system-libpng - system-libjpeg -no-libtiff -no-libtiff -no-libmng -no-gif -nis -no-cups -qt-mouse-tslib -nomake demos -nomake examples -qt-gfx-transformed -qt-freetype -v - svg -optimized-qmake -no-pch -no-nis OPENSSL_LIB="-L/home/use/build_openssl/lib -lssl -lcrypto" -openssl-linked

        5. An error occurred during Qt Build
          sl/qsslcertificate.cpp: In member function 'QByteArray QSslCertificate::version() const':
          ssl/qsslcertificate.cpp:264: error: invalid use of incomplete type 'struct x509_st'
          ../../include/QtNetwork/../../src/network/ssl/qsslcertificate.h:53: error: forward declaration of 'struct x509_st'
          ssl/qsslcertificate.cpp: In member function 'QByteArray QSslCertificate::serialNumber() const':
          ssl/qsslcertificate.cpp:279: error: invalid use of incomplete type 'struct x509_st'
          ../../include/QtNetwork/../../src/network/ssl/qsslcertificate.h:53: error: forward declaration of 'struct x509_st'
          ssl/qsslcertificate.cpp: In member function 'QSslKey QSslCertificate::publicKey() const':
          ssl/qsslcertificate.cpp:492: error: invalid use of incomplete type 'struct x509_st'
          ../../include/QtNetwork/../../src/network/ssl/qsslcertificate.h:53: error: forward declaration of 'struct x509_st'
          ssl/qsslcertificate.cpp:496: error: invalid use of incomplete type 'struct evp_pkey_st'
          /home/gene/share_folder/QT4.8.7_with_Openssl/build_openssl/include/openssl/ossl_typ.h:93: error: forward declaration of 'struct evp_pkey_st'
          ssl/qsslcertificate.cpp:500: error: invalid use of incomplete type 'struct evp_pkey_st'
          /home/gene/share_folder/QT4.8.7_with_Openssl/build_openssl/include/openssl/ossl_typ.h:93: error: forward declaration of 'struct evp_pkey_st'
          ssl/qsslcertificate.cpp:504: error: invalid use of incomplete type 'struct evp_pkey_st'
          /home/gene/share_folder/QT4.8.7_with_Openssl/build_openssl/include/openssl/ossl_typ.h:93: error: forward declaration of 'struct evp_pkey_st'
          Makefile:16867: recipe for target '.obj/release-shared-emb-arm/qsslcertificate.o' failed
          make[1]: *** [.obj/release-shared-emb-arm/qsslcertificate.o] Error 1
          make[1]: exit directory '/home/gene/share_folder/QT4.8.7_with_Openssl/QT_Source/qt-everywhere-opensource-src-4.8.7/src/network'
          Makefile:288: recipe for target 'sub-network-install_subtargets-ordered' failed
          make: *** [sub-network-install_subtargets-ordered] Error 2

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

        @programsc said in Qt4 Cross compile Error:

        Openssl ver: 1.1.1d

        I don't think Qt4 supports OpenSSL 1.1.
        You should use 1.0 or even older (according to https://doc.qt.io/archives/qt-4.8/requirements.html >= 0.9.7, but 1.1 will for sure not work as it is not compatible with 1.0).

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

        1 Reply Last reply
        1
        • P Offline
          P Offline
          programsc
          wrote on last edited by programsc
          #3

          thank you for your reply
          Openssl was restarted using 1.0.2u, but the following error occurred.

          make[1]: exit directory '/home/gene/share_folder/QT4.8.7_with_Openssl/QT_Source/qt-everywhere-opensource-src-4.8.7/src/xml'
          cd src/network/ && make -f Makefile install
          make[1]: Enter directory '/home/gene/share_folder/QT4.8.7_with_Openssl/QT_Source/qt-everywhere-opensource-src-4.8.7/src/network'
          make[1]: *** target '/home/gene/share_folder/QT4.8.7_with_Openssl/build_openssl/include/openssl/cryptoerr.h' required from '.obj/release-shared-emb-arm/qsslcertificate.o' There are no rules to create . stoppage.
          make[1]: exit directory '/home/gene/share_folder/QT4.8.7_with_Openssl/QT_Source/qt-everywhere-opensource-src-4.8.7/src/network'
          Makefile:288: recipe for target 'sub-network-install_subtargets-ordered' failed
          make: *** [sub-network-install_subtargets-ordered] Error 2

          jsulmJ 1 Reply Last reply
          0
          • P programsc

            thank you for your reply
            Openssl was restarted using 1.0.2u, but the following error occurred.

            make[1]: exit directory '/home/gene/share_folder/QT4.8.7_with_Openssl/QT_Source/qt-everywhere-opensource-src-4.8.7/src/xml'
            cd src/network/ && make -f Makefile install
            make[1]: Enter directory '/home/gene/share_folder/QT4.8.7_with_Openssl/QT_Source/qt-everywhere-opensource-src-4.8.7/src/network'
            make[1]: *** target '/home/gene/share_folder/QT4.8.7_with_Openssl/build_openssl/include/openssl/cryptoerr.h' required from '.obj/release-shared-emb-arm/qsslcertificate.o' There are no rules to create . stoppage.
            make[1]: exit directory '/home/gene/share_folder/QT4.8.7_with_Openssl/QT_Source/qt-everywhere-opensource-src-4.8.7/src/network'
            Makefile:288: recipe for target 'sub-network-install_subtargets-ordered' failed
            make: *** [sub-network-install_subtargets-ordered] Error 2

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

            @programsc You should complete clean rebuild

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

            P 1 Reply Last reply
            0
            • jsulmJ jsulm

              @programsc You should complete clean rebuild

              P Offline
              P Offline
              programsc
              wrote on last edited by
              #5

              @jsulm

              Yes, i proceeded with make after make clean

              jsulmJ 1 Reply Last reply
              0
              • P programsc

                @jsulm

                Yes, i proceeded with make after make clean

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

                @programsc No, what I mean: delete the whole build folder and start from scratch

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

                P 1 Reply Last reply
                0
                • jsulmJ jsulm

                  @programsc No, what I mean: delete the whole build folder and start from scratch

                  P Offline
                  P Offline
                  programsc
                  wrote on last edited by
                  #7

                  @jsulm
                  Thank you
                  We have solved the problem with your help.

                  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