From 1828b5b29b4f01b9846b29acd79d75b6c10063d1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20M=C3=BCller?= Date: Thu, 26 Sep 2024 11:10:30 +0200 Subject: [PATCH] Fix Android build when first building `x64` architecture The argument `x64` is an alias for `x86_64` but the name of the build folder always contains `x86_64`, so the `data` folder and certificate were not being found when using the `x64` argument, unless another architecture was previously built. --- scripts/android/cmake_android.sh | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/scripts/android/cmake_android.sh b/scripts/android/cmake_android.sh index 643d016a5..d541250a3 100755 --- a/scripts/android/cmake_android.sh +++ b/scripts/android/cmake_android.sh @@ -26,6 +26,9 @@ if [ -z ${1+x} ]; then printf "${COLOR_RED}%s${COLOR_RESET}\n" "Did not pass Android build type" else ANDROID_BUILD=$1 + if [[ "${ANDROID_BUILD}" == "x64" ]]; then + ANDROID_BUILD="x86_64" + fi printf "${COLOR_YELLOW}%s${COLOR_RESET}\n" "Android build type: ${ANDROID_BUILD}" fi @@ -168,7 +171,7 @@ if [[ "${ANDROID_BUILD}" == "x86" || "${ANDROID_BUILD}" == "all" ]]; then PID_BUILD_X86=$! fi -if [[ "${ANDROID_BUILD}" == "x86_64" || "${ANDROID_BUILD}" == "x64" || "${ANDROID_BUILD}" == "all" ]]; then +if [[ "${ANDROID_BUILD}" == "x86_64" || "${ANDROID_BUILD}" == "all" ]]; then build_for_type x86_64 x86_64 x86_64-linux-android & PID_BUILD_X86_64=$! fi @@ -236,7 +239,7 @@ if [[ "${ANDROID_BUILD}" == "x86" || "${ANDROID_BUILD}" == "all" ]]; then copy_libs x86 x86 fi -if [[ "${ANDROID_BUILD}" == "x86_64" || "${ANDROID_BUILD}" == "x64" || "${ANDROID_BUILD}" == "all" ]]; then +if [[ "${ANDROID_BUILD}" == "x86_64" || "${ANDROID_BUILD}" == "all" ]]; then copy_libs x86_64 x86_64 fi