Fix (some) problems with libraries in the ADT 17 Plugin

Hey guys!

This will be a quick post. Did you update the ADT plugin to v17? Did you find that there are problems with libraries?

The solution (for some of those problems) is:

  1. If your jar libraries are in a lib folder, rename it to libs.
  2. Remove all your jar libraries from the Build Path of your project. Don’t need to add them again to the Build Path.
  3. In your libs folder, you should have just the jar libraries that your project is using. You can’t have different versions of a single library. This is because if you’ve noticed, Eclipse creates now a reference in the Build Path called “Android Dependecies” and he puts there all the jar files that are in your libs folder.
  4. Follow steps 1, 2 and 3 for each Android Library Project that your project is using.
  5. Make a project clean.

Hope it helps anybody! :D

I found some help here: http://android.foxykeep.com/dev/how-to-fix-the-classdefnotfounderror-with-adt-17

 

UPDATE: You can find official ¡nfo on Android Dependecies at this link: http://tools.android.com/recent/dealingwithdependenciesinandroidprojects

About these ads

Tags: , , , ,

About Xavi Rigau

I'm an Android enthusiast! I'm finishing a degree in IT science while I work as Android Developer in a company in Barcelona. I also try to develop my own apps. My dog Fiona helps me a lot in that! She's quite good.

10 responses to “Fix (some) problems with libraries in the ADT 17 Plugin”

  1. sergiandreplaceSergi says :

    Great Article!

    I’m quite sick of those Google upgrades with structural changes and no instructions on how adapt your projects.

  2. Mark Carter (@marcardar) says :

    This doesn’t seem to apply to jar files that are in Java-only projects.

    The only way I can get those to work is by manually editing the Android project’s .classpath file with exported=”true”

  3. shahzadrocks says :

    Google is always creating a problem without any prior information

  4. QFAN says :

    Automatic inclusion in Android Dependencies is nice. But it seems it doesn’t work with test project.

    All my testing ant scripts are ruined. I don’t know for how long will I have to manually test all updates before I or someone find solutions for buildxml someday…

  5. m3n0R says :

    Tio en serio, no puc compilar i m’estic desesperant, ja he perdut 3 o 4 hores provan coses diferents…

    Una de dos, o em dona error de Dalvik, o la activitat no se m’executa per què em dona error de mapView dins del Fragment…

    ho he provat tot, totes les combinacions, he seguit mil tutorials diferents i res…
    si vols agregam al gtalk i em faries un favor si parlessim del tema, perquè això dels mapes per mi es molt urgent xD
    cesaryomismo@gmail.com !!

  6. walker says :

    You’re a life saver. I’ve been struggling with this problem for a week.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.

%d bloggers like this: