I have installed Android Studio with the idea of developing applications with Cordova and Phonegap thanks to the help of my partner @karel who showed me this question:
How to install Android Studio on Ubuntu?
I followed the instructions exactly, but even so I have several errors.
When you start Android Studio with the following command, sudo -E /opt/google/android-studio/bin/studio.sh
this shows the first error:
Gtk-Message: 09:07:14.283: Failed to load module "canberra-gtk-module"
(java:13968): IBUS-WARNING **: 09:07:14.566:
The owner of /home/miguel/.config/ibus/bus is not root!
I installed the SDK, (I think I installed the necessary ones) and when I returned to a Cordova project, and I ran cordova requirements
to see if everything was OK, the result was the following:
Android Studio project detected
Requirements check results for android:
Java JDK: installed 11.0.2
Android SDK: installed true
Android target: not installed
avdmanager: Command failed with exit code 1 Error output:
Exception 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.AvdManagerCli.run(AvdManagerCli.java:213)
at com.android.sdklib.tool.AvdManagerCli.main(AvdManagerCli.java:200)
Caused by: java.lang.ClassNotFoundException: javax.xml.bind.annotation.XmlSchema
at java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:583)
at java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:178)
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:521)
... 5 more
Gradle: not installed
Could not find an installed version of Gradle either in Android Studio,
or on your system to install the gradle wrapper. Please include gradle
in your path, or install Android Studio
Some of requirements check failed
miguel@miguel:~/todo-codigos/proyectos-2019/cordova/zombies$
What did I do wrong? What can I do to correct this and be able to run my applications on Cordova and Phonegap?
0 Answers