2

I have two Android Library Projects in Eclipse (yes, "Is library" is selected in both of them). One of those is ActionBarSherlock, the other one is ViewPagerIndicator

Now, ViewPagerIndicator must include ActionBarSherlock as a library dependence, so I add it under the "Android" settings of the project. Problem is, in the moment I add the library dependence, if I go to Java Build Path of the same project I can see that the dependence .jar of the added library is required but not present (of course, as it is a library project, no jars are created!).

What can be the problem? Furthermore, I have to add both libraries as dependences to an Android application, which presents the same issue.

Jake Wharton
  • 75,598
  • 23
  • 223
  • 230
frapontillo
  • 10,499
  • 11
  • 43
  • 54

1 Answers1

3

Are you using ADT14? If so, you probably need to migrate the library projects to the new structure. Right click the library project and select 'Fix project properties' from the Android tools menu.

Nikolay Elenkov
  • 52,576
  • 10
  • 84
  • 84
  • 1
    I was just going to recommend this. New versions of both of these libraries will be released (hopefully) tonight to update them to the ADT14 format. – Jake Wharton Oct 19 '11 at 15:50
  • There's only a "Fix project properties" in "Android Tools", and it doesn't change anything. The outcome is still the same: "Build success" but an empty apk. – frapontillo Oct 19 '11 at 16:01
  • 1
    I just tried it with a similar project (app->lib->ABS), and it works. 'Fix' both library projects, if you are `switch`-ing on a resource ID, change to if, and compile. Running fine on ICS :) (I've fixed the answer, it is indeed 'properties', not 'structure') – Nikolay Elenkov Oct 19 '11 at 16:07
  • @JakeWharton Cool, looking forward to it. – Nikolay Elenkov Oct 19 '11 at 16:07
  • It looks like it does nothing on my machine, by clicking on the "Fix" nothing happens. – frapontillo Oct 19 '11 at 16:09
  • 1
    Try this: https://github.com/JakeWharton/ActionBarSherlock/issues/79#issuecomment-2464701 You can extrapolate on the steps and perform them for the ViewPagerIndicator reference in your project as well. Also, ActionBarSherlock 3.3.1 has been released with ADT 14 support and metric boat-load of bug fixes! ViewPagerIndicator to be updated tomorrow... – Jake Wharton Oct 20 '11 at 05:14
  • Thank you very much Jake! I will try the steps you proposed. ;) – frapontillo Oct 20 '11 at 08:05
  • After all, it was an Eclipse error (for a change......). I deleted the .metadata folder (as suggested on http://stackoverflow.com/questions/4714711/android-packaging-problem-resources-ap-does-not-exist/7824904#7824904) and reimported my projects again, including ABS and ViewPagerIndicator. After three days spent on the issue, it's compiling again. – frapontillo Oct 21 '11 at 11:00