If you encounter errors like these two:

/Library/Frameworks/Mono.framework/External/xbuild/Xamarin/Android/Xamarin.Android.Common.targets(574,2): error :  Error finding Android/Java SDKs

/Library/Frameworks/Mono.framework/External/xbuild/Xamarin/Android/Xamarin.Android.Common.targets(574,2): error :   at Xamarin.Android.Build.Utilities.AndroidSdkBase.Initialize (System.String androidSdkPath, System.String androidNdkPath, System.String javaSdkPath) 

This is because Visual Studio for Mac and Xamarin Studio do not automatically search for system Android SDK and NDK locations. You will need to add the SDK or NDK path that is missing in your build definition.

Add the SDK and NDK path to your build

  • The correct Android SDK path for Xamarin.Android is: "/usr/local/opt/android-sdk"

  • The correct Android NDK path for Xamarin.Android is "/usr/local/opt/android-ndk"

You can first try restarting your agent through the web portal. Every time the agent is restarted the above path is configured.

If you continue to face difficulties, please contact our support staff so we can help you to permanently resolve this issue by overwrite the default SDK and NDK path for your Xamarin.Android builds.