After installing Xamarin Studio I went to the options to make sure the Android SDK, JDK and NDK were all found. The first two in fact were, but the NDK was not found. It asked to specify location, and I did specify the location (when I clicked "browse" it took me to the folder where the NDK actually was). Yet, it still does not recognize it and says NDK not found at the specified location.
When using Xamarin Studio, if you are getting the error XA5101 error ("Missing Android NDK toolchains directory") you would need to download the Android NDK separately from:
http://developer.android.com/tools/sdk/ndk/index.html
Then he should unzip downloaded file and open the Xamarin IDE and go to the following menu location:
Tools ==> Options ==> SDK Locations ==> Android
Select the location of the unzipped folder.
Then close the IDE and reopen it (force close/restart if it persists in task/process manager).
Alternate to try:
Not finding NDK may also be caused because of mismatched configuration for AVD Manager. More specifically, the Xamarin may be creating devices & AVDs in your %USERPROFILE%.android while the debugger/runtime emulation EXPECTS the AVDs in the ADT directory. You can try copying ZAVD2-related files and directories into the %USERPROFILE%.android\avd and see if that resolves the issue.
===== Initial post ======
[In case of eclipse] I think the answer is here: https://stackoverflow.com/a/11825963/918535
//goto Preference → Android → NDK
and choose your ndk location
//If your NDK location is already set, the builder in the toolchain editor may be wrong. Go to project properties, C/C++ Build | Tool Chain Editor
and select Android Builder as current builder.
// in your .bashsrc
file, you may also need to add the env variable:
NDK_HOME=/opt/android-ndk-r8
export NDK_HOME
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With