diff --git a/scripts/android-build-common.sh b/scripts/android-build-common.sh index 77313184a..b1f074ed7 100644 --- a/scripts/android-build-common.sh +++ b/scripts/android-build-common.sh @@ -11,6 +11,10 @@ if [ -z $NDK_TARGET ]; then NDK_TARGET=21 fi +if [ -z $CCACHE ]; then + CCACHE=$(which ccache) +fi + if [ -z $ANDROID_NDK ]; then ANDROID_NDK="missing" fi diff --git a/scripts/android-build-openssl.sh b/scripts/android-build-openssl.sh index de2c7474b..a0f443ffb 100755 --- a/scripts/android-build-openssl.sh +++ b/scripts/android-build-openssl.sh @@ -30,7 +30,7 @@ function build { common_run export CROSS_SYSROOT=$ANDROID_NDK/platforms/android-$NDK_TARGET/$PLATFORM_PREFIX common_run export ANDROID_DEV=$ANDROID_NDK/platforms/android-$NDK_TARGET/$PLATFORM_PREFIX/usr - common_run export CROSS_COMPILE=$ARCH_PREFIX + common_run export CROSS_COMPILE="$CCACHE $ARCH_PREFIX" common_run export PATH=$ANDROID_NDK/toolchains/$TOOLCHAIN_PREFIX$COMPILER/prebuilt/$HOST_PLATFORM/bin/:$ORG_PATH echo "CONFIG=$CONFIG"