Browse Source

Android: Add script calling OpenSSL configure with the right parameters

JNI-88
Hussein Kasem 3 years ago
parent
commit
9456cb696c
2 changed files with 19 additions and 3 deletions
  1. +5
    -3
      android/external/Makefile
  2. +14
    -0
      utils/configure_openssl.sh

+ 5
- 3
android/external/Makefile View File

@ -11,7 +11,7 @@
NDK_ABI ?= arm
NDK_TOOLCHAIN_VERSION ?= clang
APP_ABI ?= armeabi-v7a
APP_PLATFORM ?= android-18
ANDROID_API ?= 18
PEP_PACKAGE_NAME ?= security.pEp
APP_OPTIM ?= debug
@ -242,10 +242,12 @@ openssl-clean:
EXTERNAL_SRCS += openssl-src
EXTERNAL_SRCS_CLEAN += openssl-clean
OPENSSL_ARCHITECTURE:=android-arm
openssl/Makefile: openssl.src.stamp
cd openssl && \
PATH="$(ANDROID_NDK_HOME)/bin:$(PATH)" ./Configure android-arm --prefix=$(prefix)
../../../utils/configure_openssl.sh ${OPENSSL_ARCHITECTURE} $(ANDROID_API) $(LOCAL)
openssl/libssl.so: | openssl/Makefile
PATH="$(ANDROID_NDK_HOME)/bin:$(PATH)" $(MAKE) -C openssl


+ 14
- 0
utils/configure_openssl.sh View File

@ -0,0 +1,14 @@
#!/bin/bash
### 
# DONT USE IT
### 
CC=clang
TOOLCHAINS_PATH=$(python ../../../utils/ndk_toolchains_path.py --ndk ${ANDROID_NDK})
PATH=$TOOLCHAINS_PATH/bin:$PATH
ARCHITECTURE=$1
ANDROID_API=$2
echo $3
./Configure ${ARCHITECTURE} -D__ANDROID_API__=$ANDROID_API --prefix=$3

Loading…
Cancel
Save