Android app doesn't run noClassDefFoundError

I am creating a gps application for Android! And now I came across a problem. The application does not start at all ... Any ideas on how to fix this?

04-05 12:54:50.877: D/dalvikvm(540): Not late-enabling CheckJNI (already on) 04-05 12:54:51.018: I/dalvikvm(540): Turning on JNI app bug workarounds for target SDK version 5... 04-05 12:54:51.417: I/dalvikvm(540): Could not find method org.acra.ACRA.init, referenced from method com.kulplex.gaia.GaiaApp.onCreate 04-05 12:54:51.417: W/dalvikvm(540): VFY: unable to resolve static method 652: Lorg/acra/ACRA;.init (Landroid/app/Application;)V 04-05 12:54:51.417: D/dalvikvm(540): VFY: replacing opcode 0x71 at 0x0000 04-05 12:54:51.457: D/AndroidRuntime(540): Shutting down VM 04-05 12:54:51.457: W/dalvikvm(540): threadid=1: thread exiting with uncaught exception (group=0x409c01f8) 04-05 12:54:51.477: E/AndroidRuntime(540): FATAL EXCEPTION: main 04-05 12:54:51.477: E/AndroidRuntime(540): java.lang.NoClassDefFoundError: org.acra.ACRA 04-05 12:54:51.477: E/AndroidRuntime(540): at com.kulplex.gaia.GaiaApp.onCreate(GaiaApp.java:54) 04-05 12:54:51.477: E/AndroidRuntime(540): at android.app.Instrumentation.callApplicationOnCreate(Instrumentation.java:969) 04-05 12:54:51.477: E/AndroidRuntime(540): at android.app.ActivityThread.handleBindApplication(ActivityThread.java:3954) 04-05 12:54:51.477: E/AndroidRuntime(540): at android.app.ActivityThread.access$1300(ActivityThread.java:123) 04-05 12:54:51.477: E/AndroidRuntime(540): at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1185) 04-05 12:54:51.477: E/AndroidRuntime(540): at android.os.Handler.dispatchMessage(Handler.java:99) 04-05 12:54:51.477: E/AndroidRuntime(540): at android.os.Looper.loop(Looper.java:137) 04-05 12:54:51.477: E/AndroidRuntime(540): at android.app.ActivityThread.main(ActivityThread.java:4424) 04-05 12:54:51.477: E/AndroidRuntime(540): at java.lang.reflect.Method.invokeNative(Native Method) 04-05 12:54:51.477: E/AndroidRuntime(540): at java.lang.reflect.Method.invoke(Method.java:511) 04-05 12:54:51.477: E/AndroidRuntime(540): at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:784) 04-05 12:54:51.477: E/AndroidRuntime(540): at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:551) 04-05 12:54:51.477: E/AndroidRuntime(540): at dalvik.system.NativeStart.main(Native Method) 
+8
android android-emulator acra error-handling logcat
source share
2 answers

If you recently upgraded to ADT 17 and later, they changed the processing of the lib library.

so you need to rename your lib directory to libs , then right-click your project> properties> Java build path> Libraries> select all banks with error labels on them and click remove > click add JARs > select all banks from your new libs dir .

Hope this helps.

+18
source share

I had the same problem after updating to the latest Android tools.

In the project properties, in the section "Path, order and export Java" I had to check whether the private Android libraries were checked.

Then I had to clean up the project. After that it works.

This is really a problem with the "Order and Export" Java build paths.

When updating the "Order and Export" of new "Private Android Libraries" is not always checked. And android-support-v4.jar is now in this section "Android Private Libraries".

To fix this, go to the Order and Export section and select the Android Private Libraries check box. Then update / clean / rebuild.

After you have completed this “fix” for the library project, you may need to simply close and reopen any dependent project, because they may not see this “fix” immediately.

I found the answer here .

+21
source share

All Articles