Cant Find SDK Path when trying to build Android app

Hello.

I know this topic has been requested by many and I have done my best to look for all possible answers as best i can.

I have tried to follow the instructions on Unity - Manual: Android environment setup as best I can as well, and can not see that I have done anything wrong.

When I try to build my game (I am new to unity and building apps) the error check if my SDK path is correct, with 5 more errors listed in console:

"Build Failure

Unable to list target platform, Please make sure the android sdk path is correct. See the Console for details"

I have installed the latest Android Studio and been to SDK Manager and downloaded all SDK Platforms down to Lollipop 5.0.
I have installed these from the SDK Tools section in Android Studio

  • Android SDK build-Tools 28-rc11
  • Android Emulator
  • Android SDK Platform-tools version 26.1.1
  • Google USB Driver
  • Instant Apps Development SDK
  • Interl x86 Emulator Accelerator

I have changed the SDK location from the default Appdata location because i have an SSD with limited space. So i changed it to my B drive and set all permission to be allowed for that disk by all users on the computer. All SDK files are installed on the B drive and the path is set correctly for both Unity in External Tools and in the Android Studio

In the Unity Console it looks like it tries to find B:/Unity/Android/SDK\tools\bin\avdmanager.bat

When i navigate manually to that location i can see the avdmanger.bat file in that location.

I have also tried to download the Command line tools only from Android Studio (https://developer.android.com/studio/#downloads) and set that folder as a path, however this does not work either.

Been at this for several hours and can not figure it out on my own.

Links to images:

try using older JDK (9 doesnt work with unity, probably 10 doesnt work either)

i’m using jdk1.8.0_151

1 Like

GET THIS MAN SOME CAKE!

Yes that DID WORK! Thank you stranger!

I did however have to uninstall all versions of java that i currently had, restart and then reinstall the version you have AND delete the - Android SDK build-Tools 28-rc11 update from Android Studio which seems to not be compatible with the downgraded JDK.

But now all went well. thank you again so much!