I want to create an avd, but facing java error while launching android 
PREBUILT tool. Please note that I am using Android Build System and not the 
sdk.

How to overcome this error so that I can create a new avd?

Error:

$ android -help

Exception in thread "main" java.lang.NoClassDefFoundError: 
com/android/sdklib/repository/SdkRepoConstants

at com.android.sdkmanager.SdkCommandLine.<init>(SdkCommandLine.java:340)
at com.android.sdkmanager.Main.init(Main.java:222)
at com.android.sdkmanager.Main.run(Main.java:148)
at com.android.sdkmanager.Main.main(Main.java:117)
Caused by: java.lang.ClassNotFoundException: 
com.android.sdklib.repository.SdkRepoConstants at 
java.base/jdk.internal.loader.BuiltinClassLoader.loadClass(BuiltinClassLoader.java:582)
 
at 
java.base/jdk.internal.loader.ClassLoaders$AppClassLoader.loadClass(ClassLoaders.java:185)
 
at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:496) ... 4 
more

Java version:

$ java -version
openjdk version "9" OpenJDK Runtime Environment (build 
9+181-androidxxxxxxx) OpenJDK 64-Bit Server VM (build 9+181-androidxxxxxxx, 
mixed mode)

Also tried with JDK - 8 and same error came

-- 
-- 
You received this message because you are subscribed to the "Android Building" 
mailing list.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-building?hl=en

--- 
You received this message because you are subscribed to the Google Groups 
"Android Building" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/android-building/4e71cf98-9756-439d-aa50-8d01a0ffa5de%40googlegroups.com.

Reply via email to