From ea2d5b11dcd880e14f5b7a0f43926f33da494d3c Mon Sep 17 00:00:00 2001 From: Frank Denis Date: Thu, 20 Feb 2025 14:50:57 +0100 Subject: [PATCH] Indent Android build scripts --- dist-build/android-aar.sh | 7 ++----- dist-build/android-build.sh | 2 +- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/dist-build/android-aar.sh b/dist-build/android-aar.sh index 0f7f1084..14cbe18e 100755 --- a/dist-build/android-aar.sh +++ b/dist-build/android-aar.sh @@ -13,8 +13,7 @@ if [ -z "$NDK_PLATFORM" ]; then echo "Compiling for default platform: [${NDK_PLATFORM}] - That can be changed by setting an NDK_PLATFORM environment variable." fi -SDK_VERSION=$( echo "$NDK_PLATFORM" | cut -f2 -d"-" ) - +SDK_VERSION=$(echo "$NDK_PLATFORM" | cut -f2 -d"-") if which zip >/dev/null; then echo "The 'zip' command is installed." @@ -68,7 +67,6 @@ make_prefab_structure() { mkdir "$DEST_PATH/${variant}/libs/android.${arch}/include" NDK_ARCH="$arch" - make_abi_json "$DEST_PATH/${variant}/libs/android.${arch}" done done @@ -121,8 +119,7 @@ zip -9 -r "$AAR_PATH" META-INF prefab AndroidManifest.xml cd .. || exit rm -r "$DEST_PATH" - -echo "Congrats you have built an AAR containing libsodium! +echo "Congrats you have built an AAR containing libsodium! The build used a min Android SDK of version $SDK_VERSION You can build for a different SDK version by specifying NDK_PLATFORM=\"android-{SDK_VERSION}\" as an environment variable before running this script but the defaults should be fine. diff --git a/dist-build/android-build.sh b/dist-build/android-build.sh index b1c300dc..53935210 100755 --- a/dist-build/android-build.sh +++ b/dist-build/android-build.sh @@ -4,7 +4,7 @@ if [ -z "$NDK_PLATFORM" ]; then echo "No NDK_PLATFORM specified, set to value such as \"android-{Min_SDK_VERSION}\" or just use android-aar.sh" exit fi -SDK_VERSION=$( echo "$NDK_PLATFORM" | cut -f2 -d"-" ) +SDK_VERSION=$(echo "$NDK_PLATFORM" | cut -f2 -d"-") export NDK_PLATFORM_COMPAT="${NDK_PLATFORM_COMPAT:-${NDK_PLATFORM}}" export NDK_API_VERSION="$(echo "$NDK_PLATFORM" | sed 's/^android-//')" export NDK_API_VERSION_COMPAT="$(echo "$NDK_PLATFORM_COMPAT" | sed 's/^android-//')"