No toolchains found in the NDK toolchains folder for ABI with prefix: mips64el-linux-android [duplicate]

烈酒焚心 提交于 2019-11-30 08:45:24

If you are using NDK >= 18 you have to update your android gradle plugin to >=3.1.x

See the Known Issues section:

https://android.googlesource.com/platform/ndk/+/ndk-release-r18/CHANGELOG.md

C0D3JUNKIE

After looking around, the solution was to remove the NDK designation from my preferences.

Android Studio → Preferences → System Settings → Android SDK → SDK Tools → Unselect NDK → Apply button.

Project and Gradle compiled fine after that and I was able to move on with my project work.

As far as why this is happening, I do not know but for more info on NDK check out: https://developer.android.com/ndk/

I will go back and enable these libraries but for now.

for me, upgrade the Android Gradle plugin version to 3.2+ works.

  classpath 'com.android.tools.build:gradle:3.2.0'

Android Studio -> Preferences -> System Settings -> Android SDK -> SDK Tools -> Unselect NDK -> Apply button.

It works fine for me.

Updating the Android Gradle plugin is definitely the preferred solution. However, if for whatever reason you can't do that, it's easy to simply "fix" the error without downloading, copying, or symlinking anything, by just creating an empty directory:

mkdir -p $ANDROID_HOME/ndk-bundle/toolchains/mips64el-linux-android/prebuilt/linux-x86_64

$ANDROID_HOME points to the root of the Android SDK installation. On MacOS, replace linux-x86_64 with darwin-x86_64. Use windows-x86_64 on Windows.

It's Because of NDK Version You are selected Follow the steps which will help you to resolve

If you want to use NDK then Update the Gradle Plugin

In build script change Dependecies

classpath { 'com.android.tools.build:gradle:3.2.1'
classpath {'com.google.gms:google-services:3.2.0'}

if you are unaware of the NDK then simply disable it by selecting preferences>System settings>android sdk>Select SDK Tools > uncheck NDK there

Rebuild the project it works just fine

Happy Coding <3

If you don't want to update your gradle plugin you can do this. Download one of the older NDK releases, e.g. r17c. Open downloaded NDK archive, go to toolchains directory and copy missing toolchain folders to toolchains folder of your currently used NDK. In my case the folders I had to copy were mipsel-linux-android-4.9 and mips64el-linux-android-4.9.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!