Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Mobile and Embedded
  4. Android - How to install .so file?
Forum Update on Monday, May 27th 2025

Android - How to install .so file?

Scheduled Pinned Locked Moved Unsolved Mobile and Embedded
31 Posts 6 Posters 13.5k 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.
  • E Ed Buchwalter
    8 Mar 2017, 09:17

    I am trying to include openSSL and cURL with my android application.
    I have built openSSL and cURL but seem unable to install the libssl.so and the libcrypto.so files to my device.
    Though I have now spent many hours I just can't seem to get this to work.
    Any help is appreciated!

    Regards,
    Ed

    E Offline
    E Offline
    ekkescorner
    Qt Champions 2016
    wrote on 8 Mar 2017, 09:22 last edited by
    #2

    @Ed-Buchwalter I'm just about to do the same for openssl and Qt 5.8
    Have you followed http://doc.qt.io/qt-5/opensslsupport.html to get the openssl .so libs ?

    ekke ... Qt Champion 2016 | 2024 ... mobile business apps
    5.15 --> 6.8 https://t1p.de/ekkeChecklist
    QMake --> CMake https://t1p.de/ekkeCMakeMobileApps

    1 Reply Last reply
    0
    • L Offline
      L Offline
      luca
      wrote on 8 Mar 2017, 09:23 last edited by
      #3

      Hi,
      I followed the steps on:
      http://doc.qt.io/qt-5/opensslsupport.html
      to build Openssl, then I added to my .pro :

      LIBS += -L$$PWD/../../openssl/android/ -lcrypto -lssl
      INCLUDEPATH += $$PWD/../../openssl/android/openssl-1.0.2h/include/
      
      contains(ANDROID_TARGET_ARCH,armeabi-v7a) {
          ANDROID_EXTRA_LIBS = \
              $$PWD/../../openssl/android/libcrypto.so \
              $$PWD/../../openssl/android/libssl.so
      }
      

      for me it worked... hope it hepls!

      Luca

      E 1 Reply Last reply 8 Mar 2017, 09:29
      0
      • E Offline
        E Offline
        ekkescorner
        Qt Champions 2016
        wrote on 8 Mar 2017, 09:23 last edited by
        #4

        and from another thread @Joseneas added the .so this way:

        To package the .so files into apk, add the below code into .pro file of the project:

        contains(ANDROID_TARGET_ARCH,arm) {
            # update the path of the libraries where you put in your project.
            # I put in: myapp/android/libs/openssl/armeabi-v7a/:
            ANDROID_EXTRA_LIBS = \
                $$PWD/android/libs/openssl/armeabi-v7a/libcrypto.so \
                $$PWD/android/libs/openssl/armeabi-v7a/ibssl.so
        }
        

        ekke ... Qt Champion 2016 | 2024 ... mobile business apps
        5.15 --> 6.8 https://t1p.de/ekkeChecklist
        QMake --> CMake https://t1p.de/ekkeCMakeMobileApps

        1 Reply Last reply
        0
        • L luca
          8 Mar 2017, 09:23

          Hi,
          I followed the steps on:
          http://doc.qt.io/qt-5/opensslsupport.html
          to build Openssl, then I added to my .pro :

          LIBS += -L$$PWD/../../openssl/android/ -lcrypto -lssl
          INCLUDEPATH += $$PWD/../../openssl/android/openssl-1.0.2h/include/
          
          contains(ANDROID_TARGET_ARCH,armeabi-v7a) {
              ANDROID_EXTRA_LIBS = \
                  $$PWD/../../openssl/android/libcrypto.so \
                  $$PWD/../../openssl/android/libssl.so
          }
          

          for me it worked... hope it hepls!

          Luca

          E Offline
          E Offline
          ekkescorner
          Qt Champions 2016
          wrote on 8 Mar 2017, 09:29 last edited by
          #5

          @luca so you don't copy the .so into the project - you always refer to one location. makes sense if many projects are using the libs

          ekke ... Qt Champion 2016 | 2024 ... mobile business apps
          5.15 --> 6.8 https://t1p.de/ekkeChecklist
          QMake --> CMake https://t1p.de/ekkeCMakeMobileApps

          L 1 Reply Last reply 8 Mar 2017, 09:40
          0
          • E ekkescorner
            8 Mar 2017, 09:29

            @luca so you don't copy the .so into the project - you always refer to one location. makes sense if many projects are using the libs

            L Offline
            L Offline
            luca
            wrote on 8 Mar 2017, 09:40 last edited by
            #6

            @ekkescorner Yes, I use the same .so for every project.

            E 1 Reply Last reply 8 Mar 2017, 09:57
            0
            • L luca
              8 Mar 2017, 09:40

              @ekkescorner Yes, I use the same .so for every project.

              E Offline
              E Offline
              ekkescorner
              Qt Champions 2016
              wrote on 8 Mar 2017, 09:57 last edited by ekkescorner 3 Aug 2017, 10:06
              #7

              @luca I'm not the cmd line expert - only a mobile app developer ;-)

              so please excuse my questions. am I right with my commands below ?

              CC=<ANDROID_NDK_PATH>/toolchains/arm-linux-androideabi-<VER>/prebuilt/<NDK_HOST>/bin/arm-linux-androideabi-gcc
              AR=<ANDROID_NDK_PATH>/toolchains/arm-linux-androideabi-<VER>/prebuilt/<NDK_HOST>/bin/arm-linux-androideabi-ar
              ANDROID_DEV=<ANDROID_NDK_PATH>/platforms/<ANDROID-PLATFORM>/arch-arm/usr
              

              will execute inside Terminal on OSX
              is -4.9 the correct version ?
              the <NDK_HOST> I found following the path as darwin-x86_64
              as <ANDROID-PLATFORM> I used the newest from r10e: android-21

              cd <directory-where extracted openssl>/openssl-1.0.2k
              export ANDROID_NDK_ROOT=/daten/_android/android-ndk-r10e
              CC=$ANDROID_NDK_ROOT/toolchains/arm-linux-androideabi-4.9/prebuilt/darwin-x86_64/bin/arm-linux-androideabi-gcc
              AR=$ANDROID_NDK_ROOT/toolchains/arm-linux-androideabi-4.9/prebuilt/darwin-x86_64/bin/arm-linux-androideabi-ar
              ANDROID_DEV=$ANDROID_NDK_ROOT/platforms/android-21/arch-arm/usr
              

              as next

              ./Configure shared android or android-armv7
              

              don't know what to choose - probably this:

              ./Configure shared android-armv7
              

              then doing the mentioned replaces and finally

              make build_libs
              

              will do the job ?

              thanks

              ekke ... Qt Champion 2016 | 2024 ... mobile business apps
              5.15 --> 6.8 https://t1p.de/ekkeChecklist
              QMake --> CMake https://t1p.de/ekkeCMakeMobileApps

              L 1 Reply Last reply 8 Mar 2017, 10:07
              0
              • E ekkescorner
                8 Mar 2017, 09:57

                @luca I'm not the cmd line expert - only a mobile app developer ;-)

                so please excuse my questions. am I right with my commands below ?

                CC=<ANDROID_NDK_PATH>/toolchains/arm-linux-androideabi-<VER>/prebuilt/<NDK_HOST>/bin/arm-linux-androideabi-gcc
                AR=<ANDROID_NDK_PATH>/toolchains/arm-linux-androideabi-<VER>/prebuilt/<NDK_HOST>/bin/arm-linux-androideabi-ar
                ANDROID_DEV=<ANDROID_NDK_PATH>/platforms/<ANDROID-PLATFORM>/arch-arm/usr
                

                will execute inside Terminal on OSX
                is -4.9 the correct version ?
                the <NDK_HOST> I found following the path as darwin-x86_64
                as <ANDROID-PLATFORM> I used the newest from r10e: android-21

                cd <directory-where extracted openssl>/openssl-1.0.2k
                export ANDROID_NDK_ROOT=/daten/_android/android-ndk-r10e
                CC=$ANDROID_NDK_ROOT/toolchains/arm-linux-androideabi-4.9/prebuilt/darwin-x86_64/bin/arm-linux-androideabi-gcc
                AR=$ANDROID_NDK_ROOT/toolchains/arm-linux-androideabi-4.9/prebuilt/darwin-x86_64/bin/arm-linux-androideabi-ar
                ANDROID_DEV=$ANDROID_NDK_ROOT/platforms/android-21/arch-arm/usr
                

                as next

                ./Configure shared android or android-armv7
                

                don't know what to choose - probably this:

                ./Configure shared android-armv7
                

                then doing the mentioned replaces and finally

                make build_libs
                

                will do the job ?

                thanks

                L Offline
                L Offline
                luca
                wrote on 8 Mar 2017, 10:07 last edited by
                #8

                @ekkescorner I followed those steps but I'm working on Linux so I can't confirm it works on Mac.

                I used:

                ./Configure shared android-armv7
                

                because that way you can cover almost all current Android devices.

                E 2 Replies Last reply 8 Mar 2017, 10:08
                1
                • L luca
                  8 Mar 2017, 10:07

                  @ekkescorner I followed those steps but I'm working on Linux so I can't confirm it works on Mac.

                  I used:

                  ./Configure shared android-armv7
                  

                  because that way you can cover almost all current Android devices.

                  E Offline
                  E Offline
                  ekkescorner
                  Qt Champions 2016
                  wrote on 8 Mar 2017, 10:08 last edited by
                  #9

                  @luca thx - will try it out

                  ekke ... Qt Champion 2016 | 2024 ... mobile business apps
                  5.15 --> 6.8 https://t1p.de/ekkeChecklist
                  QMake --> CMake https://t1p.de/ekkeCMakeMobileApps

                  1 Reply Last reply
                  0
                  • L luca
                    8 Mar 2017, 10:07

                    @ekkescorner I followed those steps but I'm working on Linux so I can't confirm it works on Mac.

                    I used:

                    ./Configure shared android-armv7
                    

                    because that way you can cover almost all current Android devices.

                    E Offline
                    E Offline
                    ekkescorner
                    Qt Champions 2016
                    wrote on 8 Mar 2017, 10:28 last edited by
                    #10

                    @luca did all.
                    configuration was done

                    did changes in Makefile

                    then make build_libs fails:

                    Configured for android-armv7.
                    ekkes-MBP:openssl-1.0.2k admin$ make build_libs
                    making all in crypto...
                    /usr/bin/perl ../util/mkbuildinf.pl "gcc -I. -I.. -I../include  -fPIC -DOPENSSL_PIC -DOPENSSL_THREADS -D_REENTRANT -DDSO_DLFCN -DHAVE_DLFCN_H -march=armv7-a -mandroid -I/include -B/lib -O3 -fomit-frame-pointer -Wall -DOPENSSL_BN_ASM_MONT -DOPENSSL_BN_ASM_GF2m -DSHA1_ASM -DSHA256_ASM -DSHA512_ASM -DAES_ASM -DBSAES_ASM -DGHASH_ASM" "android-armv7" >buildinf.h
                    gcc -I. -I.. -I../include  -fPIC -DOPENSSL_PIC -DOPENSSL_THREADS -D_REENTRANT -DDSO_DLFCN -DHAVE_DLFCN_H -march=armv7-a -mandroid -I/include -B/lib -O3 -fomit-frame-pointer -Wall -DOPENSSL_BN_ASM_MONT -DOPENSSL_BN_ASM_GF2m -DSHA1_ASM -DSHA256_ASM -DSHA512_ASM -DAES_ASM -DBSAES_ASM -DGHASH_ASM   -c -o cryptlib.o cryptlib.c
                    clang: error: unknown argument: '-mandroid'
                    make[1]: *** [cryptlib.o] Error 1
                    make: *** [build_crypto] Error 1
                    

                    any idea what went wrong ?

                    ekke ... Qt Champion 2016 | 2024 ... mobile business apps
                    5.15 --> 6.8 https://t1p.de/ekkeChecklist
                    QMake --> CMake https://t1p.de/ekkeCMakeMobileApps

                    L 1 Reply Last reply 8 Mar 2017, 10:50
                    0
                    • E ekkescorner
                      8 Mar 2017, 10:28

                      @luca did all.
                      configuration was done

                      did changes in Makefile

                      then make build_libs fails:

                      Configured for android-armv7.
                      ekkes-MBP:openssl-1.0.2k admin$ make build_libs
                      making all in crypto...
                      /usr/bin/perl ../util/mkbuildinf.pl "gcc -I. -I.. -I../include  -fPIC -DOPENSSL_PIC -DOPENSSL_THREADS -D_REENTRANT -DDSO_DLFCN -DHAVE_DLFCN_H -march=armv7-a -mandroid -I/include -B/lib -O3 -fomit-frame-pointer -Wall -DOPENSSL_BN_ASM_MONT -DOPENSSL_BN_ASM_GF2m -DSHA1_ASM -DSHA256_ASM -DSHA512_ASM -DAES_ASM -DBSAES_ASM -DGHASH_ASM" "android-armv7" >buildinf.h
                      gcc -I. -I.. -I../include  -fPIC -DOPENSSL_PIC -DOPENSSL_THREADS -D_REENTRANT -DDSO_DLFCN -DHAVE_DLFCN_H -march=armv7-a -mandroid -I/include -B/lib -O3 -fomit-frame-pointer -Wall -DOPENSSL_BN_ASM_MONT -DOPENSSL_BN_ASM_GF2m -DSHA1_ASM -DSHA256_ASM -DSHA512_ASM -DAES_ASM -DBSAES_ASM -DGHASH_ASM   -c -o cryptlib.o cryptlib.c
                      clang: error: unknown argument: '-mandroid'
                      make[1]: *** [cryptlib.o] Error 1
                      make: *** [build_crypto] Error 1
                      

                      any idea what went wrong ?

                      L Offline
                      L Offline
                      luca
                      wrote on 8 Mar 2017, 10:50 last edited by
                      #11

                      @ekkescorner Do you get the same error if you try

                      ./Configure shared android
                      

                      ?

                      E 2 Replies Last reply 8 Mar 2017, 11:03
                      0
                      • L luca
                        8 Mar 2017, 10:50

                        @ekkescorner Do you get the same error if you try

                        ./Configure shared android
                        

                        ?

                        E Offline
                        E Offline
                        ekkescorner
                        Qt Champions 2016
                        wrote on 8 Mar 2017, 11:03 last edited by
                        #12

                        @luca just asked in interests list - perhaps I got some info there

                        ekke ... Qt Champion 2016 | 2024 ... mobile business apps
                        5.15 --> 6.8 https://t1p.de/ekkeChecklist
                        QMake --> CMake https://t1p.de/ekkeCMakeMobileApps

                        L 1 Reply Last reply 8 Mar 2017, 11:09
                        0
                        • E ekkescorner
                          8 Mar 2017, 11:03

                          @luca just asked in interests list - perhaps I got some info there

                          L Offline
                          L Offline
                          luca
                          wrote on 8 Mar 2017, 11:09 last edited by
                          #13

                          @ekkescorner Ok,
                          anyway I just tryed on my Linux PC and it worked:

                          cd openssl-1.0.2h
                          export AR=/home/luca/android-ndk-r10e/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-ar
                          export CC=/home/luca/android-ndk-r10e/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-gcc
                          export LD=/home/luca/android-ndk-r10e/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-ld
                          export ANDROID_DEV=/home/luca/android-ndk-r10e/platforms/android-21/arch-arm/usr
                          ./Configure shared android-armv7
                          make depend
                          make build_libs
                          
                          E 3 Replies Last reply 8 Mar 2017, 11:12
                          0
                          • L luca
                            8 Mar 2017, 11:09

                            @ekkescorner Ok,
                            anyway I just tryed on my Linux PC and it worked:

                            cd openssl-1.0.2h
                            export AR=/home/luca/android-ndk-r10e/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-ar
                            export CC=/home/luca/android-ndk-r10e/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-gcc
                            export LD=/home/luca/android-ndk-r10e/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-ld
                            export ANDROID_DEV=/home/luca/android-ndk-r10e/platforms/android-21/arch-arm/usr
                            ./Configure shared android-armv7
                            make depend
                            make build_libs
                            
                            E Offline
                            E Offline
                            ekkescorner
                            Qt Champions 2016
                            wrote on 8 Mar 2017, 11:12 last edited by
                            #14

                            @luca difference is
                            OSX
                            1.0.2k

                            and what does
                            make depend ?

                            ekke ... Qt Champion 2016 | 2024 ... mobile business apps
                            5.15 --> 6.8 https://t1p.de/ekkeChecklist
                            QMake --> CMake https://t1p.de/ekkeCMakeMobileApps

                            1 Reply Last reply
                            0
                            • L luca
                              8 Mar 2017, 11:09

                              @ekkescorner Ok,
                              anyway I just tryed on my Linux PC and it worked:

                              cd openssl-1.0.2h
                              export AR=/home/luca/android-ndk-r10e/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-ar
                              export CC=/home/luca/android-ndk-r10e/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-gcc
                              export LD=/home/luca/android-ndk-r10e/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-ld
                              export ANDROID_DEV=/home/luca/android-ndk-r10e/platforms/android-21/arch-arm/usr
                              ./Configure shared android-armv7
                              make depend
                              make build_libs
                              
                              E Offline
                              E Offline
                              ekkescorner
                              Qt Champions 2016
                              wrote on 8 Mar 2017, 13:40 last edited by
                              #15

                              @luca just also tried 1.0.2.h

                              got info to execute make depend

                              then error:

                              Configured for android-armv7.
                              
                              *** Because of configuration changes, you MUST do the following before
                              *** building:
                              
                              	make depend
                              ekkes-MBP:openssl-1.0.2h admin$ make depend
                              making depend in crypto...
                              clang: error: unknown argument: '-mandroid'
                              make[1]: *** [local_depend] Error 1
                              make: *** [depend] Error 1
                              

                              ekke ... Qt Champion 2016 | 2024 ... mobile business apps
                              5.15 --> 6.8 https://t1p.de/ekkeChecklist
                              QMake --> CMake https://t1p.de/ekkeCMakeMobileApps

                              1 Reply Last reply
                              0
                              • L luca
                                8 Mar 2017, 10:50

                                @ekkescorner Do you get the same error if you try

                                ./Configure shared android
                                

                                ?

                                E Offline
                                E Offline
                                ekkescorner
                                Qt Champions 2016
                                wrote on 8 Mar 2017, 14:11 last edited by
                                #16

                                @luca said in Android - How to install .so file?:

                                @ekkescorner Do you get the same error if you try

                                ./Configure shared android
                                

                                ?

                                got the same error

                                who has successfully installed openssl for Qt 5.8 on OSX ?

                                ekke ... Qt Champion 2016 | 2024 ... mobile business apps
                                5.15 --> 6.8 https://t1p.de/ekkeChecklist
                                QMake --> CMake https://t1p.de/ekkeCMakeMobileApps

                                1 Reply Last reply
                                0
                                • L luca
                                  8 Mar 2017, 11:09

                                  @ekkescorner Ok,
                                  anyway I just tryed on my Linux PC and it worked:

                                  cd openssl-1.0.2h
                                  export AR=/home/luca/android-ndk-r10e/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-ar
                                  export CC=/home/luca/android-ndk-r10e/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-gcc
                                  export LD=/home/luca/android-ndk-r10e/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-ld
                                  export ANDROID_DEV=/home/luca/android-ndk-r10e/platforms/android-21/arch-arm/usr
                                  ./Configure shared android-armv7
                                  make depend
                                  make build_libs
                                  
                                  E Offline
                                  E Offline
                                  ekkescorner
                                  Qt Champions 2016
                                  wrote on 8 Mar 2017, 14:28 last edited by
                                  #17

                                  @luca said in Android - How to install .so file?:

                                  @ekkescorner Ok,
                                  anyway I just tryed on my Linux PC and it worked:

                                  cd openssl-1.0.2h
                                  

                                  ...

                                  export LD=/home/luca/android-ndk-r10e/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-ld

                                  why have you added this line ?
                                  and should I use 'export AR= and CC=' instead of AR= and CC= in docs ?

                                  thx again

                                  ekke ... Qt Champion 2016 | 2024 ... mobile business apps
                                  5.15 --> 6.8 https://t1p.de/ekkeChecklist
                                  QMake --> CMake https://t1p.de/ekkeCMakeMobileApps

                                  E L 2 Replies Last reply 8 Mar 2017, 15:02
                                  0
                                  • E ekkescorner
                                    8 Mar 2017, 14:28

                                    @luca said in Android - How to install .so file?:

                                    @ekkescorner Ok,
                                    anyway I just tryed on my Linux PC and it worked:

                                    cd openssl-1.0.2h
                                    

                                    ...

                                    export LD=/home/luca/android-ndk-r10e/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-ld

                                    why have you added this line ?
                                    and should I use 'export AR= and CC=' instead of AR= and CC= in docs ?

                                    thx again

                                    E Offline
                                    E Offline
                                    ekkescorner
                                    Qt Champions 2016
                                    wrote on 8 Mar 2017, 15:02 last edited by
                                    #18

                                    found https://github.com/openssl/openssl/issues/1531 and https://bruteforce.gr/bypassing-clang-error-unknown-argument.html
                                    and tried to add at first line
                                    ARCHFLAGS=-Wno-error=unused-command-line-argument-hard-error-in-future

                                    didn't work - same error
                                    also I guess GCC is used because of
                                    CC=$ANDROID_NDK_ROOT/toolchains/arm-linux-androideabi-4.9/prebuilt/darwin-x86_64/bin/arm-linux-androideabi-gcc
                                    so the error shouldn't happen ?

                                    also found https://github.com/android-ndk/ndk/issues/5 mentioning 1.0.2g added -mandroid,
                                    so I tried downloading 1.0.2f
                                    same error

                                    I'm lost now - no one out there on OSX already added openssl libs to Qt 5.8 ?

                                    thx
                                    ekke

                                    ekke ... Qt Champion 2016 | 2024 ... mobile business apps
                                    5.15 --> 6.8 https://t1p.de/ekkeChecklist
                                    QMake --> CMake https://t1p.de/ekkeCMakeMobileApps

                                    1 Reply Last reply
                                    0
                                    • E ekkescorner
                                      8 Mar 2017, 14:28

                                      @luca said in Android - How to install .so file?:

                                      @ekkescorner Ok,
                                      anyway I just tryed on my Linux PC and it worked:

                                      cd openssl-1.0.2h
                                      

                                      ...

                                      export LD=/home/luca/android-ndk-r10e/toolchains/arm-linux-androideabi-4.9/prebuilt/linux-x86_64/bin/arm-linux-androideabi-ld

                                      why have you added this line ?
                                      and should I use 'export AR= and CC=' instead of AR= and CC= in docs ?

                                      thx again

                                      L Offline
                                      L Offline
                                      luca
                                      wrote on 8 Mar 2017, 16:06 last edited by
                                      #19

                                      @ekkescorner I used "export" because otherwise my bash terminal didn't use the environmental variables.
                                      LD is used to force the android version of the linker. Don't know if you can avoid it.

                                      E 1 Reply Last reply 8 Mar 2017, 16:44
                                      0
                                      • L luca
                                        8 Mar 2017, 16:06

                                        @ekkescorner I used "export" because otherwise my bash terminal didn't use the environmental variables.
                                        LD is used to force the android version of the linker. Don't know if you can avoid it.

                                        E Offline
                                        E Offline
                                        ekkescorner
                                        Qt Champions 2016
                                        wrote on 8 Mar 2017, 16:44 last edited by
                                        #20

                                        @luca said in Android - How to install .so file?:

                                        @ekkescorner I used "export" because otherwise my bash terminal didn't use the environmental variables.
                                        LD is used to force the android version of the linker. Don't know if you can avoid it.

                                        did the same

                                        now another error - probably the LD is only needed on Linux ?

                                        ekkes-MBP:openssl-1.0.2k admin$ make build_libs
                                        making all in crypto...
                                        /usr/bin/perl ../util/mkbuildinf.pl "/daten/_android/android-ndk-r10e/toolchains/arm-linux-androideabi-4.9/prebuilt/darwin-x86_64/bin/arm-linux-androideabi-gcc -I. -I.. -I../include  -fPIC -DOPENSSL_PIC -DOPENSSL_THREADS -D_REENTRANT -DDSO_DLFCN -DHAVE_DLFCN_H -march=armv7-a -mandroid -I/include -B/lib -O3 -fomit-frame-pointer -Wall -DOPENSSL_BN_ASM_MONT -DOPENSSL_BN_ASM_GF2m -DSHA1_ASM -DSHA256_ASM -DSHA512_ASM -DAES_ASM -DBSAES_ASM -DGHASH_ASM" "android-armv7" >buildinf.h
                                        /daten/_android/android-ndk-r10e/toolchains/arm-linux-androideabi-4.9/prebuilt/darwin-x86_64/bin/arm-linux-androideabi-gcc -I. -I.. -I../include  -fPIC -DOPENSSL_PIC -DOPENSSL_THREADS -D_REENTRANT -DDSO_DLFCN -DHAVE_DLFCN_H -march=armv7-a -mandroid -I/include -B/lib -O3 -fomit-frame-pointer -Wall -DOPENSSL_BN_ASM_MONT -DOPENSSL_BN_ASM_GF2m -DSHA1_ASM -DSHA256_ASM -DSHA512_ASM -DAES_ASM -DBSAES_ASM -DGHASH_ASM   -c -o cryptlib.o cryptlib.c
                                        In file included from cryptlib.c:117:0:
                                        cryptlib.h:62:21: fatal error: stdlib.h: No such file or directory
                                         # include <stdlib.h>
                                                             ^
                                        compilation terminated.
                                        make[1]: *** [cryptlib.o] Error 1
                                        make: *** [build_crypto] Error 1
                                        

                                        ekke ... Qt Champion 2016 | 2024 ... mobile business apps
                                        5.15 --> 6.8 https://t1p.de/ekkeChecklist
                                        QMake --> CMake https://t1p.de/ekkeCMakeMobileApps

                                        1 Reply Last reply
                                        0
                                        • E Offline
                                          E Offline
                                          ekkescorner
                                          Qt Champions 2016
                                          wrote on 8 Mar 2017, 17:10 last edited by
                                          #21

                                          created a Bug: https://bugreports.qt.io/browse/QTBUG-59375 - will make it easier to follow

                                          ekke ... Qt Champion 2016 | 2024 ... mobile business apps
                                          5.15 --> 6.8 https://t1p.de/ekkeChecklist
                                          QMake --> CMake https://t1p.de/ekkeCMakeMobileApps

                                          E 1 Reply Last reply 8 Mar 2017, 23:18
                                          1

                                          11/31

                                          8 Mar 2017, 10:50

                                          20 unread
                                          • Login

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