-1

Recently I upgraded my Mac to Catalina.

I installed Java, set JAVA_HOME to $(/usr/libexec/java_home) as per the documentation. I installed Android Studio and SDK tools and set the ANDROID_HOME variable to /Users/username/Library/Android/sdk.

I downloaded flutter, and added flutter/bin to my env variable $PATH, and when I run flutter doctor, it's running fine and giving me the results as expected, without all the features checked however as I am setting it up for the first time.

But when I run flutter doctor --android-licenses, it's giving me an error which says:

Android sdkmanager tool was not found, try re-installing or upgrading your Android SDK.

  • I was able to get one step further by installing the cmdline-tools from android studio sdk manager and copying the contents of sdk/cmdline-tools/latest to sdk/tools directory. But even after that when I run the command it says "A newer version of Android SDK is required". When I run the mentioned command "./sdkmanager --update" it says "JDK command not found". – Priyabrata Pati Mar 23 '20 at 09:59

1 Answers1

2

Run the command flutter upgrade.

Then run the command flutter doctor --android-licenses.

Actually it was the then latest version of Flutter 1.12.13+hotfix.8 installed, which was not reading the cmdline-tools folder from the latest Android SDK home.

Also to be on the safer side, just create a folder tools inside <path-to-sdk-home>, and copy the contents of <path-to-sdk-home>/cmdline-tools/latest/ to the folder <path-to-sdk-home>/tools/.