DEV Community

Cover image for Android cmdline-tools component is missing - Flutter installation issue
Julia 👩🏻‍💻 GDE
Julia 👩🏻‍💻 GDE

Posted on

Android cmdline-tools component is missing - Flutter installation issue

When I installed Flutter, I worked my way through all the steps that the command line spit out when running

flutter doctor.

So following the instructions in the command line provided enough information about what to do next to check all the boxes and install Flutter successfully.

But one point didn't seem to be as easy to fulfill as the others 😥.

Error that the Android Studio cmdline-tools component is missing.

Error 👾



[!] Android toolchain - develop for Android devices (Android SKD version 34.0.0)
  x cmdline-tools component is missing
    Run `path/to/sdkmanager --install "cmdline-tools:latest"`
    See https://developer.android.com/studio/command-line for more details.


Enter fullscreen mode Exit fullscreen mode

Running the command path/to/sdkmanager --install "cmdline-tools;latest" as suggested did not work 😓.

After some research, I found out that no additional installation is required, just a change of settings in Android Studio.

To overcome the issue

  • open Android Studio
  • go to Tools in the menu bar and choose SDK Manager (opens the settings)
  • go to Android SDK in the left sidebar
  • in the middle choose SKD Tools (second tab in tab bar)
  • and check Android SDK Command-line Tools (latest)

Android Studio workflow.

After checking this box and running flutter doctor again, everything worked just fine and the installation was successfully completed.

All checkmarks are successfully checked.

Note ⚠️: The second issue Android license status unknown, which is marked with an x in the image worked without any problems when running flutter doctor --android-licenses as suggested in the console.


Thanks for your time and reading. I really appreciate it.

Top comments (2)

Collapse
 
lnahrf profile image
Lev N.

Tackled this myself a couple of days ago, took me some trial and error to understand it has to be installed through your Android Studio GUI.
Thanks for sharing!

Collapse
 
yuridevat profile image
Julia 👩🏻‍💻 GDE

Thanks for your comment. I feel you 🥲