From a6c0134d63e0c841a0bd9295b4cf093bbb7364b7 Mon Sep 17 00:00:00 2001 From: cyBerta Date: Sat, 18 Dec 2021 03:46:45 +0100 Subject: use ndk side-by-side, parse ndk directory name from source.properties and adapt the ndk path --- docker/android-ndk/Dockerfile | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'docker/android-ndk/Dockerfile') diff --git a/docker/android-ndk/Dockerfile b/docker/android-ndk/Dockerfile index 7d38973c..82d9155b 100644 --- a/docker/android-ndk/Dockerfile +++ b/docker/android-ndk/Dockerfile @@ -32,9 +32,11 @@ ENV ANDROID_NDK_HOME ${ANDROID_HOME}/android-ndk-${ANDROID_NDK_VERSION} ENV ANDROID_NDK_URL http://dl.google.com/android/repository/android-ndk-${ANDROID_NDK_VERSION}-linux-x86_64.zip RUN curl -L $ANDROID_NDK_URL -o ndk.zip \ - && unzip ndk.zip -d $ANDROID_HOME \ + && unzip ndk.zip -d $ANDROID_HOME/ndk \ && rm -rf ndk.zip - +RUN cat $ANDROID_HOME/ndk/android-ndk-${ANDROID_NDK_VERSION}/source.properties | \ + grep Pkg.Revision | cut -d "=" -f 2 | \ + xargs -I '{}' mv $ANDROID_HOME/ndk/android-ndk-${ANDROID_NDK_VERSION}/ $ANDROID_HOME/ndk/'{}' ENV PATH ${PATH}:${ANDROID_NDK_HOME} RUN echo "accept all licenses" -- cgit v1.2.3