Unity/Members,
I am trying to set up Android building in Unity, and I have the External tools setup with
SDK: C:\Users\rj_ma\AppData\Local\Android\sdk
Java: C:\Users\rj_ma\AppData\Local\Android\sdk
NDK: C:/Users/rj_ma/Downloads/android-ndk-r13b-windows-x86_64 (2)/android-ndk-r13b
But I either get the messages saying:
SDK Tools Version 0.0 < 24.0 and then when I try to “Update Android SDK” it gives me the message “Unable to resolve Builds Tools Directory”
Or when I “Use highest installed”, it gives me the error message of “Unable to list target platforms. Please make sure SDK path is correct”
Can anyone direct me which path to choose, or how to properly download/choose the SDK path?
First of all, if this is really the path you have set for java, it’s wrong
Please specify what java / android sdk versions you have installed. Did you get android sdk together with the android studio or did you download them separately?
Oh yeah, sorry that was a typo.
My Java path is: C:/Program Files/Java/jdk-10
My Android SDK tools are through Android Studio at first, then downloaded separately when that wasn’t working.
Android Studio SDK Manager shows 27 installed, but I just installed 28rc build tools even though I read somewhere to uninstall.
Ok, this is more clear now. The first obvious issue is your java version. Unfortunately currently the highest java version supported by android sdk is 8, so you will need that. If you don’t need jdk10 for other projects, I would suggest to uninstall it and install jdk8 instead. If you need jdk10, then just install jdk8 alongside and make sure that JAVA_HOME (if you have it) and any java paths added to Path environment variable are pointing to jdk8 instead of jdk10. Finally launch Unity editor and make sure to change the java path in the editor to point to jdk8 location as well. After this you should be able to build.
Ok thanks. I uninstalled JDK 10 and am using JDK 8 in the editor now.
I no longer get the error messages before, but the console says the below now. Any idea what this error message is?
Error building Player: Win32Exception: ApplicationName=‘C:/Program Files/Java/jdk-10\bin\java.exe’, CommandLine=‘-Xmx2048M -Dcom.android.sdkmanager.toolsdir=“C:/Users/rj_ma/AppData/Local/Android/sdk\tools” -Dfile.encoding=UTF8 -jar “C:\Program Files\Unity\Editor\Data\PlaybackEngines\AndroidPlayer/Tools\sdktools.jar” -’, CurrentDirectory=‘C:\Users\rj_ma\Desktop\SimpleMobilePlaceholder’
Hmm, it looks like jdk-10 location is still left somewhere. Did you change your java path in the Unity editor? Also please check your system environment variables. If you have JAVA_HOME there, make sure it’s pointing to jdk8. Also if you haven’t done that yet, try to restart your computer just in case.