0

Now I was wondering if anyone has been able to accomplish reverting to a previous ADT plugin.

The reason for this is because I am using an open source jar and I am getting the following errors on my LogCat such as:

  1. unable to resolve virtual method
  2. unable to find class referenced in signature
  3. unable to resolve new-instance

The effect of this causes an error on running my android application on the debugger.

I was using android ADT 15 before now I am updated to 17.

Please help on finding a solution to resolve the issue.

Edit* Forgot to add in The error "java.lang.NoClassDefFoundError". In simple terms it can't find classes or methods the attached jar even though it allows it.

Edit* Logcat added

04-09 17:22:56.488: E/AndroidRuntime(4057): FATAL EXCEPTION: main
04-09 17:22:56.488: E/AndroidRuntime(4057): java.lang.NoClassDefFoundError: nl.siegmann.epublib.epub.EpubReader
04-09 17:22:56.488: E/AndroidRuntime(4057):     at ebook.holder.ReadWholeBook.amBook(ReadWholeBook.java:796)
04-09 17:22:56.488: E/AndroidRuntime(4057):     at ebook.holder.ReadWholeBook.firstPartBook(ReadWholeBook.java:720)
04-09 17:22:56.488: E/AndroidRuntime(4057):     at ebook.holder.ReadWholeBook.initializeLoading(ReadWholeBook.java:159)
04-09 17:22:56.488: E/AndroidRuntime(4057):     at ebook.holder.ReadWholeBook.onCreate(ReadWholeBook.java:109)
04-09 17:22:56.488: E/AndroidRuntime(4057):     at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1047)
04-09 17:22:56.488: E/AndroidRuntime(4057):     at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:1611)
04-09 17:22:56.488: E/AndroidRuntime(4057):     at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:1663)
04-09 17:22:56.488: E/AndroidRuntime(4057):     at android.app.ActivityThread.access$1500(ActivityThread.java:117)
04-09 17:22:56.488: E/AndroidRuntime(4057):     at android.app.ActivityThread$H.handleMessage(ActivityThread.java:931)
04-09 17:22:56.488: E/AndroidRuntime(4057):     at android.os.Handler.dispatchMessage(Handler.java:99)
04-09 17:22:56.488: E/AndroidRuntime(4057):     at android.os.Looper.loop(Looper.java:123)
04-09 17:22:56.488: E/AndroidRuntime(4057):     at android.app.ActivityThread.main(ActivityThread.java:3683)
04-09 17:22:56.488: E/AndroidRuntime(4057):     at java.lang.reflect.Method.invokeNative(Native Method)
04-09 17:22:56.488: E/AndroidRuntime(4057):     at java.lang.reflect.Method.invoke(Method.java:507)
04-09 17:22:56.488: E/AndroidRuntime(4057):     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:839)
04-09 17:22:56.488: E/AndroidRuntime(4057):     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:597)
04-09 17:22:56.488: E/AndroidRuntime(4057):     at dalvik.system.NativeStart.main(Native Method)

These are the warnings given:

04-09 17:22:56.158: W/dalvikvm(4057): VFY: unable to resolve new-instance 144 (Lnl/siegmann/epublib/epub/EpubReader;) in Lebook/holder/ReadWholeBook;
04-09 17:22:56.177: W/dalvikvm(4057): VFY: unable to find class referenced in signature (Lnl/siegmann/epublib/domain/Book;)
04-09 17:22:56.217: W/dalvikvm(4057): VFY: unable to find class referenced in signature (Lnl/siegmann/epublib/domain/Book;)
04-09 17:22:56.233: W/dalvikvm(4057): VFY: unable to resolve virtual method 433: Lnl/siegmann/epublib/domain/Book;.getSpine ()Lnl/siegmann/epublib/domain/Spine;
04-09 17:22:56.277: W/dalvikvm(4057): VFY: unable to find class referenced in signature (Lnl/siegmann/epublib/domain/Book;)
04-09 17:22:56.277: W/dalvikvm(4057): VFY: unable to resolve virtual method 433: Lnl/siegmann/epublib/domain/Book;.getSpine ()Lnl/siegmann/epublib/domain/Spine;
sdfwer
  • 1,022
  • 3
  • 10
  • 22

5 Answers5

6

You can revert to previous version of ADT plug-in with following steps:

  1. Download a previous version of ADT (zip archive). The official change log with a listing of historical ADT version numbers from Google: http://developer.android.com/tools/sdk/eclipse-adt.html .The exact filename and format to use when downloading older versions: (http://dl.google.com/android/ADT-16.0.1.zip, http://dl.google.com/android/ADT-21.0.0.zip, etc.), see How install old ADT13 in Eclipse for more details on the process. Choose version that you want revert to.

  2. In Eclipse menu go to Window -> Preferences -> Install/Update -> Available Software Sites and add recently downloaded archive to list by clicking on "Archive" button.

  3. In Eclipse menu go to Help -> About Eclipse -> Installation Details -> Installation history and choose appropriate item in list. Then click "Revert" button.

  4. After successful revert and restart Eclipse you get previous version of ADT, but this older version of ADT may be incompatible with Android SDK installed on your computer. You can "hack" checking of ADT version in Android SDK with "This verison of ADT requires Android SDK Tools in revision 17 or above." I can't get this error to go away.

  5. After all above steps you can work with reverted version of ADT, but if some parts of your project always relies on newer version of ADT or SDK you must solve this issues manually.

Community
  • 1
  • 1
Andrey
  • 435
  • 4
  • 9
  • Just used these instructions to revert from ADT v21 to ADT v20.0.3 to avoid this java.lang.NoSuchFieldError bug: https://groups.google.com/forum/?fromgroups=#!topic/adt-dev/Lfa9AgAXURQ. Thanks Andrey! – Theo Dec 17 '12 at 23:19
0

The first thing I'd do is delete all the outputs (gen, target, out) and do a full rebuild of the project.

Ollie C
  • 27,184
  • 33
  • 125
  • 211
0

To answer your question: No, it is not possible to revert to a previous version of the ADT Plugin. Even thought Eclipse can revert configurations, the required older version of the plugin is simply not available on the Google repos.

Unfortunately no hints with regards to your problem.

Draško Kokić
  • 1,185
  • 1
  • 18
  • 32
0

No choice no possible way to get everything back the way it is. Only solution is system restore.

sdfwer
  • 1,022
  • 3
  • 10
  • 22
0

I've got the problem and resolve it one week ago.

You must be using the adt22,right?

When you use the adt22,a library named Android Private Libraries will be shown if you have a folder named libs(with some third-party jars in it)。Unfortunately,when the project is compiled,this lib with the jars is not exported into apk,which the early plugins can do well.

So you need to export the jars manually.

Project->Build path->find the Order and Export tab,select the Android Private Libraries。Then delete the bin folder(make the project be compiled cleanly) and you will get a bigger apk with
the jars in it.

tianwei
  • 1,705
  • 1
  • 12
  • 17