10

I am new to Android and I am trying to add a library for viewPagerIndicator as this tutorial instructs me to do. However, when I add the library I get an error stating:

Versions found are:
Path: C:\Users\Bryan\workspace\MyPager\libs\android-support-v4.jar
Length: 349252
SHA-1: 612846c9857077a039b533718f72db3bc041d389
Path: C:\Users\Bryan\git\Android-ViewPagerIndicator\library\libs\android-support-v4.jar
Length: 271754
SHA-1: 53307dc2bd2b69fd5533458ee11885f55807de4b
Jar mismatch! Fix your dependencies 

How do I resolve this without messing up my build path?

Adinia
  • 3,722
  • 5
  • 40
  • 58
Mr. Bojangles
  • 348
  • 2
  • 6
  • 15

3 Answers3

22

Looks like it found the library twice. You need to delete one.

James McCracken
  • 15,488
  • 5
  • 54
  • 62
  • What is the correct procedure for doing that? I only see one library in my dependencies folder – Mr. Bojangles Sep 22 '12 at 03:34
  • 3
    If you've already added some external libraries (like ActionBarSherlock) they sometimes include the support library so you don't even need to add it. Also, if you set up your SDK targets correctly in your manifest (target the newest SDK and set minSDK) then use the built in activity creater (new file->other->android activity) then it will add the support library for you. – James McCracken Sep 22 '12 at 03:38
  • 6
    Just delete the one added to the libs folder of your app – maephisto Jan 14 '13 at 21:48
1

You are using two different revisions of the support library. Delete all of the support library jars and re-copy them into your app (and any other dependencies, if have).

The android-support-v4.jar will be compiled again automatically.

Edit : Should remove Android Dependencies and Android Private Libraries in Libraries index in Java Build Path

Huy Tower
  • 7,769
  • 16
  • 61
  • 86
0

Try to remove unnecessary .jar file of libs folder from your Android project.

Addon.mahesh
  • 107
  • 5