Android – How to build OpenSSL on Android/Linux

androidandroid-ndkg++openssl

Hi
I'm in need to build OpenSSL lib for Android NDK r5b, today it will be second day of my … useles fight. Here is short list what i've done

  1. Downloaded: https://github.com/fries/android-external-openssl/
  2. As i found here on StackOverflow fixed .S <->.s problem
  3. Crypto gets builded… until i get this message:

/prebuilt/windows/bin/arm-linux-androideabi-
SharedLibrary : libcrypto.so
arm-linux-androideabi-g++.exe: CreateProcess: No such file or directory
make: * [/cygdrive/c/AndroidDev/AndroidOpenSSL/obj/local/armeabi/libcrypto.so]
Error 1*

It's 10 years when i last time used make, and i was sure it's problem with g++ path. Added some debug to toolchain, and got:

TOOLCHAIN_NAME: arm-linux-androideabi-4.4.3
TOOLCHAIN_PREFIX: /cygdrive/c/Android_NDK/toolchains/arm-linux-androideabi-4.4.3/prebuilt/windows/bin/arm-linux-androideabi-

both looks fine for me, as /cygdrive/c/Android_NDK/toolchains/arm-linux-androideabi-4.4.3/prebuilt/windows/bin/ does exist, and arm-linux-androideabi-g++.exe is right there 🙁

Any one ever had this same problem? I realy have no idea where to look any future 🙁
Will be appreciative for help

Best Answer

One solution is also to shorten the openssl build path, eg. from c:\code\openssl-android to just c:\ssl