我知道有几个线程处理同一个问题,但没有一个解决方案适合我。
我正在构建一个同时使用Google和Facebook SDK的应用。启动Eclipse时,我收到以下错误消息:
[2014-03-02 11:40:40 - ***] Found 2 versions of google-play-services.jar in the dependency list,
[2014-03-02 11:40:40 - ***] but not all the versions are identical (check is based on SHA-1 only at this time).
[2014-03-02 11:40:40 - ***] All versions of the libraries must be the same at this time.
[2014-03-02 11:40:40 - ***] Versions found are:
[2014-03-02 11:40:40 - ***] Path: /Users/***/Development/adt-bundle-mac-x86_64-20131030/sdk/extras/google/google_play_services/libproject/google-play-services_lib/libs/google-play-services.jar
[2014-03-02 11:40:40 - ***] Length: 1501528
[2014-03-02 11:40:40 - ***] SHA-1: e5f81129dfb3d02df80126512bc98278ed2bb40a
[2014-03-02 11:40:40 - ***] Path: /Users/***/Development/my-app/libs/google-play-services.jar
[2014-03-02 11:40:40 - ***] Length: 103227
[2014-03-02 11:40:40 - ***] SHA-1: 70356edea26cc0bec4870d2cbd0eec6f0d2ffcae
[2014-03-02 11:40:40 - ***] Jar mismatch! Fix your dependencies
我试过Android工具---> “添加支持库......”包含所有三个项目(Facebook SDK,Google SDK,My-App项目),但错误仍然存在。很多答案告诉人们删除一个罐子或复制/粘贴罐子......但我对此很新,我不想破坏任何东西。
最好的方式是什么?
答案 0 :(得分:0)
当项目中使用同一个jar文件的多个版本时(包括添加的库项目),会出现上述问题。最佳做法是删除以前的jar文件并在所有中添加一个新的更新的相同jar文件相应的项目。