Gson Noclassdeffounderror After Adt and Sdk Tools Update to V17

Gson NoClassDefFoundError after ADT and SDK Tools update to v17

I faced a similar problem today.

This fixed it for me:

  • Remove all Android Library projects and external jars from the build path.
  • Create a folder named 'libs' in your project.
  • Place all external .jars in that folder, the ADT should now place them under 'Android Dependencies'.
  • Re-import all your previous Android Library projects the normal way.

The issue is that external jars are not placed in the 'libs' folder by default when using Properties - Java Build Path- Add External Jar, instead they are placed under 'Referenced Libraries' instead of 'Android Dependencies' and this causes the NoClassDefFoundError.

Please, check Dealing with dependencies in Android projects for more details.

Getting ClassNotFound Error after updating from ADT 16 to ADT 17

This issue occurs because the "lib" folder is renamed to "libs" now by Android People.
And as soon as we place our external jars to this "libs" folder then it will automatically be added to the build path of the application.

java.lang.NoClassDefFoundError: how do I fix this error?

You need to go into Build Path/Order and Export, and check the libs as of SDK 17. Then clean your project.

NoClassDefFoundError when project imported to Eclipse?

I think there are "lib" folder in your project directory so just change it "libs" instead of "lib" and clean project and check it..

> Note: No need to build path for any third party library

java.lang.NoClassDefFoundError: com.urbanairship.UAirship

Found a solution !

This indeed caused by ADT update.

I just created a new android project and noticed that the structure is different from my previous project from SVN.

After that I followed this post Gson NoClassDefFoundError after ADT and SDK Tools update to v17

And copied the old files to the new project. Finally all worked fine.

I hope this will help people with the same problem.



Related Topics



Leave a reply



Submit