chiark / gitweb /
Weblate
[fdroidserver.git] / buildserver / provision-android-ndk
index de6943b49c1389caa5bb8ad6fabe17eed7f6ef9f..8e9724bc57702e5ca2344d651d80bc0089f485b6 100644 (file)
@@ -9,41 +9,17 @@ NDK_BASE=$1
 test -e $NDK_BASE || mkdir -p $NDK_BASE
 cd $NDK_BASE
 
-if [ ! -e $NDK_BASE/r9b ]; then
-    tar xjf /vagrant/cache/android-ndk-r9b-linux-x86_64.tar.bz2
-    tar xjf /vagrant/cache/android-ndk-r9b-linux-x86_64-legacy-toolchains.tar.bz2
-    mv android-ndk-r9b r9b
-fi
-
 if [ ! -e $NDK_BASE/r10e ]; then
     7zr x /vagrant/cache/android-ndk-r10e-linux-x86_64.bin > /dev/null
     mv android-ndk-r10e r10e
 fi
 
-if [ ! -e $NDK_BASE/r11c ]; then
-    unzip /vagrant/cache/android-ndk-r11c-linux-x86_64.zip > /dev/null
-    mv android-ndk-r11c r11c
-fi
-
-if [ ! -e $NDK_BASE/r12b ]; then
-    unzip /vagrant/cache/android-ndk-r12b-linux-x86_64.zip > /dev/null
-    mv android-ndk-r12b r12b
-fi
-
-if [ ! -e $NDK_BASE/r13b ]; then
-    unzip /vagrant/cache/android-ndk-r13b-linux-x86_64.zip > /dev/null
-    mv android-ndk-r13b r13b
-fi
-
-if [ ! -e $NDK_BASE/r14b ]; then
-    unzip /vagrant/cache/android-ndk-r14b-linux-x86_64.zip > /dev/null
-    mv android-ndk-r14b r14b
-fi
-
-if [ ! -e $NDK_BASE/r15b ]; then
-    unzip /vagrant/cache/android-ndk-r15b-linux-x86_64.zip > /dev/null
-    mv android-ndk-r15b r15b
-fi
+for version in r11c r12b r13b r14b r15c r16b; do
+    if [ ! -e ${NDK_BASE}/${version} ]; then
+        unzip /vagrant/cache/android-ndk-${version}-linux-x86_64.zip > /dev/null
+        mv android-ndk-${version} ${version}
+    fi
+done
 
 chmod -R a+rX $NDK_BASE/
 find $NDK_BASE/ -type f -executable -print0 | xargs -0 chmod a+x