Android Studio versions 2.2 and higher come with a JDK, so this should
already be done.

Open an elevated console window and run the following command to begin
signing licenses.
    
$ flutter doctor --android-licenses

Review the terms of each license carefully before agreeing to them.

Once you are done agreeing with licenses, run flutter doctor again
to confirm that you are ready to use Flutter.

Linux setup

Additional Linux requirements

For Linux desktop development,
you need the following in addition to the Flutter SDK:

Clang

CMake

GTK development headers

Ninja build

pkg-config

liblzma-dev This might be necessary

Run the following command

sudo apt-get