EdGs
EdGs

Reputation: 356

Android: Added project as library, getting (missing) .jar file in Build Path>Libraries>Library Projects

Ok, I've been trying to find a solution for this for about half a day now.

I have two projects in the workspace. One is the main, I'll call it Alpha, the other is used as a library to the main, I'll call it Delta.

Delta has "is Library" check marked, and has no errors (only yellow triangles with an exclamation mark).

Alpha has Delta added as a library (under the Android selection in Project Properties). Once that is done, I get a big, fat, red exclamation mark by Alpha. In Alpha's Build Path, under the Libraries tab, there's a red 'x' by "Library Projects." Upon expanding that option I see:

delta.jar - /Users/.../Delta/bin (missing)

I really can't understand why that would be missing. 1st, the bin folder is there. 2nd, I'm importing a project library, not a .jar. 3rd even if it's creating a .jar file of the project library, it seems to compile right, Delta has no erros.

I'm really in the dark here. Please help.

Thank you

Upvotes: 4

Views: 6570

Answers (2)

KnucklesTheDog
KnucklesTheDog

Reputation: 721

I had this problem specifically when I upgraded to Android SDK 18 on OSX. Neither marking a project as a library, or importing an existing library project would generate the jar file.

I upgraded to 19 and it went away, now the jars are generated and I've done absolutely nothing else to the project or settings at all.

Hope this helps someone, I struggled for hours just like the OP.

Upvotes: 0

rfsk2010
rfsk2010

Reputation: 8611

If you are running SDK Tools, revision 14, and ADT 14.0.0 and upwards, there are changes to how jar-based libraries are built. I encourage you to read library project revamp here

Upvotes: 2

Related Questions