From 4193f9e8cce5cd7a716ca1f1d7dd35ebe40e0455 Mon Sep 17 00:00:00 2001 From: Dan Albert Date: Tue, 9 Jan 2024 16:18:56 -0800 Subject: [PATCH] Rely on AGP to auto-install CMake and the NDK. --- .ci_tools/setup_env.sh | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/.ci_tools/setup_env.sh b/.ci_tools/setup_env.sh index 3322bae7b..3005a291d 100755 --- a/.ci_tools/setup_env.sh +++ b/.ci_tools/setup_env.sh @@ -1,18 +1,8 @@ #!/bin/bash -# Installs Android SDK, NDK, and CMake required to build the samples. +# Detects which Android SDK versions are used by the samples and installs those. +# NDK and CMake are auto-installed by AGP as needed. if [ -f ~/.android/repositories.cfg ]; then touch ~/.android/repositories.cfg fi - -for version in $(find . -name build.gradle | xargs grep -h compileSdk | sort | uniq | grep -o '[0-9]\+ *$'); do - echo y | sdkmanager "platforms;android-${version}" -done - -for version in $(find . -name build.gradle | xargs grep -h ndkVersion | sort | uniq | cut -d \' -f 2); do - echo y | sdkmanager "ndk;${version}" -done - -echo y | sdkmanager "cmake;3.18.1" -echo y | sdkmanager "cmake;3.22.1"