问题
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?
回答1:
Looks like it found the library twice. You need to delete one.
回答2:
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
回答3:
Try to remove unnecessary .jar file of libs folder from your Android project.
来源:https://stackoverflow.com/questions/12540071/jar-mismatch-error-when-adding-library-in-eclipse