breautek commented on issue #1585: URL: https://github.com/apache/cordova-android/issues/1585#issuecomment-1505610800
> I'm seeing the the exact output when running `cordova requirements` and I'm major confused on how to solve this. Lastest Android Studio is installed, JAVA SKD 11, Gradle. > > But https://cordova.apache.org/docs/en/11.x/guide/platforms/android/index.html#requirements-and-support is not really clear and should have a section for all requirements - whats the avdmanager, what is behind those java issues. > > Its so frustrating when you fail on a hello world The OP describes two unrelated issues in their post. For the `cordova requirements` issue regarding `avdmanager`, it's a command line tool for managing AVDs (Android Virtual Devices). Android SDK ships two versions of this tool, one under `$ANDROID_HOME/tools/bin`, and another at `$ANDROID_HOME/cmdline-tools/<version>/bin`, where `$ANDROID_HOME` is the root folder of the Android SDK directory. All tools under ` $ANDROID_HOME/tools/bin` are legacy tools and shouldn't be used. If it prints: ``` Exception in thread "main" java.lang.NoClassDefFoundError: javax/xml/bind/annotation/XmlSchema ... ``` It means you're using the legacy tools. They aren't compatible with Java 11 runtimes. This is likely the result of having `$ANDROID_HOME/tools/bin` in your `PATH` environment variable. If so it should be removed. It should be also checked that `$ANDROID_HOME/cmdline-tools/<version>/bin` is in the `PATH`. The `<version>` depends on the version of cmdline-tools package you installed. Android Studio's SDK Manager also have the `latest` version that can be installed, which case the path will look like `$ANDROID_HOME/cmdline-tools/latest/bin`. However I'd recommend pinning it to a specific version so that upgrades are intentional to avoid things randomly breaking. The main issue this ticket describes is relating to HTTP calls, so and given there has been a lack of a response from the OP I'll assume this has been resolved. If you need further assistance on the `avdmanager` situation, please raise a new [Discussion](https://github.com/apache/cordova/discussions) for support, or if you think you have found a bug, you can raise a new [issue](https://github.com/apache/cordova-android/issues). Thank you. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
