When I run command flutter doctor --android-licenses, it shows the following error. I have already installed JDK 21 and Android SDK Command-line Tools (latest). JDK also included in the path as well. Also another suggestion from stackoverflow recommend to install older version of command-line tools. Which I did as well. Any suggestion for this?
??: ?????? com.android.sdklib.tool.sdkmanager.SdkManagerCli ??? LinkageError
java.lang.UnsupportedClassVersionError: com/android/sdklib/tool/sdkmanager/SdkManagerCli has been compiled by a more recent version of the Java Runtime (class file version 61.0), this version of the Java Runtime only recognizes class file versions up to 55.0
Android sdkmanager tool was found, but failed to run (C:\Users\Dan\AppData\Local\Android\sdk\cmdline-tools\latest\bin\sdkmanager.bat): "exited code 1".
Try re-installing or updating your Android SDK,
visit https://flutter.dev/docs/get-started/install/windows#android-setup for detailed instructions.