[FIXED] Azure pipeline ndk version error gradle build React Native Android

Issue

Azure pipeline getting ndk version error while gradle build React Native Android.

  • What went wrong:
    Execution failed for task ‘:app:stripReleaseDebugSymbols’.

No version of NDK matched the requested version 21.4.7075529. Versions available locally: 23.2.8568313, 24.0.8215888, 25.0.8775105, 25.0.8775105

  • Try:
    Run with –stacktrace option to get the stack trace. Run with –info or –debug option to get more log output. Run with –scan to get full insights.

  • Get more help at https://help.gradle.org

BUILD FAILED in 7m 15s
549 actionable tasks: 549 executed
Error: The process ‘/Users/runner/work/1/s/android/gradlew’ failed with exit code 1
at ExecState._setResult (/Users/runner/work/_tasks/Gradle_8d8eebd8-2b94-4c97-85af-839254cc6da4/2.200.2/node_modules/azure-pipelines-task-lib/toolrunner.js:944:25)
at ExecState.CheckComplete (/Users/runner/work/_tasks/Gradle_8d8eebd8-2b94-4c97-85af-839254cc6da4/2.200.2/node_modules/azure-pipelines-task-lib/toolrunner.js:927:18)
at ChildProcess. (/Users/runner/work/_tasks/Gradle_8d8eebd8-2b94-4c97-85af-839254cc6da4/2.200.2/node_modules/azure-pipelines-task-lib/toolrunner.js:840:19)
at ChildProcess.emit (events.js:198:13)
at maybeClose (internal/child_process.js:982:16)
at Socket.stream.socket.on (internal/child_process.js:389:11)
at Socket.emit (events.js:198:13)
at Pipe._handle.close (net.js:607:12)
##[error]Error: The process ‘/Users/runner/work/1/s/android/gradlew’ failed with exit code

here is image of error when pipeline fail

Solution

I have updated the NDK version from 21.4.7075529 to 25.0.8775105.
When we are updating the NDK version, we also need to update our project Gradle version which supports the updated NDK version.

Answered By – Vipan Kumar

Answer Checked By – Clifford M. (Easybugfix Volunteer)

Leave a Reply

(*) Required, Your email will not be published