Android strict dependency checks in SDK 17(SDK 17 中的 Android 严格依赖检查)
问题描述
这不是一个问题,因为我已经找到了答案.
This is not a question because I already found the answer.
新的 Android SDK 17 对 jar 文件有更严格的依赖检查.
The new Android SDK 17 has a stricter dependency check on jar files.
同时,他们添加了一个我认为以前没有的罐子.我的项目在 SDK 中的新 annotations.jar
与我已经使用的项目之间遇到了冲突.如果它们具有相同的来源,则可以将它们替换为另一个.
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.
我的 annotations.jar 来自 jetbrains,通过 Guice 依赖项,所以替换它不起作用.这是我得到的错误:
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
推荐答案
我的 annotations.jar 来自 jetbrains,通过 Guice 依赖.我将此文件重命名为 jetbrains-annotation.jar 解决了我的问题.
My annotations.jar is from jetbrains, via a Guice dependency. I renamed this file to jetbrains-annotation.jar which solved my problem.
这篇关于SDK 17 中的 Android 严格依赖检查的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!
本文标题为:SDK 17 中的 Android 严格依赖检查
基础教程推荐
- 如何在 UIImageView 中异步加载图像? 2022-01-01
- UIWebView 委托方法 shouldStartLoadWithRequest:在 WKWebView 中等效? 2022-01-01
- 如何在没有IB的情况下将2个按钮添加到右侧的UINavigationbar? 2022-01-01
- Kivy Buildozer 无法构建 apk,命令失败:./distribute.sh -m “kivy"d 2022-01-01
- 如何让对象对 Cocos2D 中的触摸做出反应? 2022-01-01
- 当从同一个组件调用时,两个 IBAction 触发的顺序是什么? 2022-01-01
- android 应用程序已发布,但在 google play 中找不到 2022-01-01
- Android:对话框关闭而不调用关闭 2022-01-01
- 如何在 iPhone 上显示来自 API 的 HTML 文本? 2022-01-01
- 在 gmail 中为 ios 应用程序检索朋友的朋友 2022-01-01