Indent Android build scripts

This commit is contained in:
Frank Denis
2025-02-20 14:50:57 +01:00
parent 5d1aea483f
commit ea2d5b11dc
2 changed files with 3 additions and 6 deletions

View File

@@ -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.

View File

@@ -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-//')"