From 3f3ece4a39a148c6d7ac29852ea3c43cb6264a08 Mon Sep 17 00:00:00 2001 From: Changming Sun Date: Thu, 12 Oct 2023 14:08:43 -0700 Subject: [PATCH] Update NDK to 26.0.10792818 (#17852) ### Description Update NDK to 26.0.10792818 which is included in every macOS build machine so that we do not need to download a different version every time in every build. ### Motivation and Context Downloading NDK on-the-fly is a main contributor of Android related build failures. --- onnxruntime/test/onnx/TestCase.cc | 2 +- tools/android_custom_build/Dockerfile | 2 +- .../github/azure-pipelines/templates/use-android-ndk.yml | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/onnxruntime/test/onnx/TestCase.cc b/onnxruntime/test/onnx/TestCase.cc index cb9633ff04..bc88f69fa9 100644 --- a/onnxruntime/test/onnx/TestCase.cc +++ b/onnxruntime/test/onnx/TestCase.cc @@ -186,7 +186,7 @@ void LoopDataFile(int test_data_pb_fd, bool is_input, const TestModelInfo& model f.SetCloseOnDelete(true); google::protobuf::io::CodedInputStream coded_input(&f); bool clean_eof = false; - int item_id = 1; + [[maybe_unused]] int item_id = 1; for (proto::TraditionalMLData data; ParseDelimitedFromCodedStream(&data, &coded_input, &clean_eof); ++item_id, data.Clear()) { diff --git a/tools/android_custom_build/Dockerfile b/tools/android_custom_build/Dockerfile index bc50e4fb0a..66b6a36e5a 100644 --- a/tools/android_custom_build/Dockerfile +++ b/tools/android_custom_build/Dockerfile @@ -55,7 +55,7 @@ WORKDIR /workspace # install Android SDK and tools ENV ANDROID_HOME=~/android-sdk -ENV NDK_VERSION=25.0.8775105 +ENV NDK_VERSION=26.0.10792818 ENV ANDROID_NDK_HOME=${ANDROID_HOME}/ndk/${NDK_VERSION} RUN aria2c -q -d /tmp -o cmdline-tools.zip \ diff --git a/tools/ci_build/github/azure-pipelines/templates/use-android-ndk.yml b/tools/ci_build/github/azure-pipelines/templates/use-android-ndk.yml index 0e034dff9d..8cc7f63a19 100644 --- a/tools/ci_build/github/azure-pipelines/templates/use-android-ndk.yml +++ b/tools/ci_build/github/azure-pipelines/templates/use-android-ndk.yml @@ -3,7 +3,7 @@ parameters: - name: AndroidNdkVersion type: string - default: "25.0.8775105" # LTS version + default: "26.0.10792818" # LTS version steps: - bash: |