I can't accept the Android SDK licenses
221
Just got the SDK Manager > SDK Tools > Install Command line Tool and then run the command for licenses.
Click that box icon it will take you to SDK manager
Author by
Vlad Poncea
Updated on December 20, 2022Comments
-
Vlad Poncea over 1 year
I just installed Flutter(2.2.1) on my MacBook(Big Sur 11.4). Here is the result when I run
flutter doctor
in the terminal.Doctor summary (to see all details, run flutter doctor -v): [✓] Flutter (Channel stable, 2.2.1, on macOS 11.4 20F71 darwin-x64, locale en-GB) [!] Android toolchain - develop for Android devices (Android SDK version 30.0.3) ✗ Android license status unknown. Run `flutter doctor --android-licenses` to accept the SDK licenses. See https://flutter.dev/docs/get-started/install/macos#android-setup for more details. [✗] Xcode - develop for iOS and macOS ✗ Xcode installation is incomplete; a full installation is necessary for iOS development. Download at: https://developer.apple.com/xcode/download/ Or install Xcode via the App Store. Once installed, run: sudo xcode-select --switch /Applications/Xcode.app/Contents/Developer sudo xcodebuild -runFirstLaunch ✗ CocoaPods not installed. CocoaPods is used to retrieve the iOS and macOS platform side's plugin code that responds to your plugin usage on the Dart side. Without CocoaPods, plugins will not work on iOS or macOS. For more info, see https://flutter.dev/platform-plugins To install see https://guides.cocoapods.org/using/getting-started.html#installation for instructions. [✓] Chrome - develop for the web [✓] Android Studio (version 4.2) [✓] VS Code (version 1.56.2) [✓] Connected device (3 available) ! Doctor found issues in 2 categories.
When I run
flutter doctor --android-licenses
here is the error that is givesException in thread "main" java.lang.NoClassDefFoundError: javax/xml/bind/annotation/XmlSchema at com.android.repository.api.SchemaModule$SchemaModuleVersion.<init>(SchemaModule.java:156) at com.android.repository.api.SchemaModule.<init>(SchemaModule.java:75) at com.android.sdklib.repository.AndroidSdkHandler.<clinit>(AndroidSdkHandler.java:81) at com.android.sdklib.tool.sdkmanager.SdkManagerCli.main(SdkManagerCli.java:73) at com.android.sdklib.tool.sdkmanager.SdkManagerCli.main(SdkManagerCli.java:48) Caused by: java.lang.ClassNotFoundException: javax.xml.bind.annotation.XmlSchema at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:581) at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178) at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:522) ... 5 more
I also installed Java JDK 16.0.1 and nothing changed. When I try to run an app on Android Studio here is the error that comes up
FAILURE: Build failed with an exception. * What went wrong: Could not determine the dependencies of task ':app:compileDebugJavaWithJavac'. > Failed to install the following Android SDK packages as some licences have not been accepted. build-tools;29.0.2 Android SDK Build-Tools 29.0.2 To build this project, accept the SDK license agreements and install the missing components using the Android Studio SDK Manager. Alternatively, to transfer the license agreements from one workstation to another, see http://d.android.com/r/studio-ui/export-licenses.html Using Android SDK: /Users/vladponcea/Library/Android/sdk * Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights. * Get more help at https://help.gradle.org BUILD FAILED in 1s Exception: Gradle task assembleDebug failed with exit code 1
I searched everywhere and I couldn't find a solution.
-
Vlad Poncea almost 3 yearsI can't find SDK Manager in Android Studio.
-
Ankit Tale almost 3 years@VladPoncea Please check image with box after project creation for SDK Manager