1 [ -z $ROOT_DIR ] && ROOT_DIR=$HOME
2 echo "Using ROOT_DIR=\"$ROOT_DIR\""
4 [ -z $DALI_DIR ] && DALI_DIR=$(cd ../../../;pwd)
5 echo "Using DALI_DIR=\"$DALI_DIR\""
6 export DALI_DIR=$DALI_DIR
8 [ -z $DALI_ENV_DIR ] && DALI_ENV_DIR=$DALI_DIR/dali-env/android
9 echo "Using DALI_ENV_DIR=\"$DALI_ENV_DIR\""
10 export DALI_ENV_DIR=$DALI_ENV_DIR
12 [ -z $TARGET ] && export TARGET=armeabi-v7a
13 echo "Using TARGET=\"$TARGET\""
15 if [ ! -d "$ANDROID_SDK" ]; then
17 if [ -d "$ROOT_DIR/Android/Sdk" ]; then
18 export ANDROID_SDK=$ROOT_DIR/Android/Sdk
21 echo "Using ANDROID_SDK=\"$ANDROID_SDK\""
23 if [ ! -d "$ANDROID_NDK" ]; then
24 if [ -d "$ANDROID_SDK" ]; then
25 NDK_DIR=$(find $ANDROID_SDK -maxdepth 2 -name ndk-build | sed 's/\/ndk-build//')
26 # Some sdk folder structures have extra <version> dir for ndk folders.
27 if [ ! -d "$NDK_DIR" ]; then
28 NDK_DIR=$(find $ANDROID_SDK -maxdepth 3 -name ndk-build | sed 's/\/ndk-build//')
30 if [ -d "$NDK_DIR" ]; then
31 export ANDROID_NDK=$NDK_DIR
35 echo "Using ANDROID_NDK=\"$ANDROID_NDK\""