13

This is not a question because I already found the answer.

The new Android SDK 17 has a stricter dependency check on jar files.

At the same time, they added a jar that I think wasn't there before. My project encountered a conflict between the new annotations.jar in the SDK and one that I already used. Replacing one by the other would work, if they have the same origin.

My annotations.jar is from jetbrains, via a Guice dependency, so replacing it doesn't work. This is the error I got:

[2012-03-22 10:54:27 - MyApp] Jar mismatch! Fix your dependencies
[2012-03-22 10:54:46 - MyApp] Found 2 versions of annotations.jar in the dependency list,
[2012-03-22 10:54:46 - MyApp] but not all the versions are identical (check is based on SHA-1 only at this time).
[2012-03-22 10:54:46 - MyApp] All versions of the libraries must be the same at this time.
[2012-03-22 10:54:46 - MyApp] Versions found are:
[2012-03-22 10:54:46 - MyApp] Path: /opt/android-sdk-linux_x86/tools/support/annotations.jar
[2012-03-22 10:54:46 - MyApp]   Length: 1463
[2012-03-22 10:54:46 - MyApp]   SHA-1: 6f59fa3a223df6f332bee8b8bffb526f7445018b
[2012-03-22 10:54:46 - MyApp] Path: /home/christine/workspace/MyApp/libs/annotations.jar
[2012-03-22 10:54:46 - MyApp]   Length: 7593
[2012-03-22 10:54:46 - MyApp]   SHA-1: e28fe9e70610beb9ef49226a9e56fed7a86e742a
[2012-03-22 10:54:46 - MyApp] Jar mismatch! Fix your dependencies
Christine
  • 5,617
  • 4
  • 38
  • 61
  • http://groups.google.com/group/actionbarsherlock/browse_thread/thread/b00f96062f61ea9e – Vivek Apr 21 '12 at 14:15
  • @Christine HAve u solved it ? – Shahzad Imam Jul 05 '12 at 11:26
  • Yes, as I said, I renamed the annotations.jar that I had to jetbrains-annotations.jar, then it worked. – Christine Jul 23 '12 at 12:53
  • 7
    Please post this in a question and answer format. As it stands right now, it should be closed. Your question should contain only the question and your answer should answer the question. It is ok to answer your own question, but be sure to follow the guidelines. Thank you! =) – prolink007 Jul 27 '12 at 19:09

1 Answers1

2

My annotations.jar is from jetbrains, via a Guice dependency. I renamed this file to jetbrains-annotation.jar which solved my problem.

Christine
  • 5,617
  • 4
  • 38
  • 61