谷歌Android播放服务重复项 [英] Android google play services duplicate entry
问题描述
我想在我的Android应用程序使用谷歌的服务,但我发现了以下错误:
com.android.ide.common.process.ProcessException:org.gradle.process.internal.ExecException:处理'命令'C:\ Program Files文件\的Java \ jdk1.8.0_11 \ BIN \ java.exe的''非零退出值2结束
我被告知要尝试添加 multiDexEnabled = TRUE
现在错误已经改到这一点:
错误:未能执行任务:应用程序:packageAllDebugClassesForMultiDex。
> java.util.zip.ZipException:重复的条目:COM /谷歌/安卓/ GMS /认证/ GooglePlayServicesAvailabilityException.class
我看了看,通过我的库,但没有能够找到他们之间的任何冲突。
我的罐子:
gdata的客户端 - 1.0.jar
GDATA客户端 - 间1.0.jar
gdata的核心 - 1.0.jar
GDATA-S preadsheet-3.0.jar
GDATA-S preadsheet-元3.0.jar
谷歌播放的,services.jar
我的项目摇篮文件具有以下依存关系:
类路径com.android.tools.build:gradle:1.2.3
类路径com.google.gms:谷歌服务:1.3.0-β1
我的模块摇篮文件:
应用插件:com.android.application
应用插件:com.google.gms.google,服务
安卓{
compileSdkVersion 22
buildToolsVersion '22 .0.1
defaultConfig {
的applicationIDcom.mydomain.myproject
的minSdkVersion 15
targetSdkVersion 22
版本code 1
VERSIONNAME1.0
multiDexEnabled =真
}
buildTypes {
推出 {
minifyEnabled假
proguardFiles getDefaultProguardFile('ProGuard的-android.txt'),'proguard-rules.pro
}
}
}
依赖{
编译文件树(包括:['的* .jar'],DIR:库)
编译com.android.support:appcompat-v7:22.2.0
编译com.google.android.gms:播放服务:7.5.0
编译com.google code.gson:GSON:2.3.1
编译组:com.google.guava,名称:番石榴,版本:'18 0.0
}
在修复这些错误将AP preciated任何帮助。
我看了看,通过我的库,但没有能够找到他们之间的任何冲突
谷歌播放services.jar
似乎与来冲突编译com.google.android.gms:玩-服务:7.5。 0
。卸下JAR,看看有没有什么帮助。
I'm trying to use google services in my Android app, but I was getting the following error:
com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command 'C:\Program Files\Java\jdk1.8.0_11\bin\java.exe'' finished with non-zero exit value 2
I was told to try adding multiDexEnabled = true
and now the error has changed to this:
Error:Execution failed for task ':app:packageAllDebugClassesForMultiDex'.
> java.util.zip.ZipException: duplicate entry: com/google/android/gms/auth/GooglePlayServicesAvailabilityException.class
I looked through my libs but wasn't able to find any conflicts between them.
My jars:
gdata-client-1.0.jar
gdata-client-meta-1.0.jar
gdata-core-1.0.jar
gdata-spreadsheet-3.0.jar
gdata-spreadsheet-meta-3.0.jar
google-play-services.jar
My project gradle file has the following dependencies:
classpath 'com.android.tools.build:gradle:1.2.3'
classpath 'com.google.gms:google-services:1.3.0-beta1'
My module gradle file:
apply plugin: 'com.android.application'
apply plugin: 'com.google.gms.google-services'
android {
compileSdkVersion 22
buildToolsVersion '22.0.1'
defaultConfig {
applicationId "com.mydomain.myproject"
minSdkVersion 15
targetSdkVersion 22
versionCode 1
versionName "1.0"
multiDexEnabled = true
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile 'com.android.support:appcompat-v7:22.2.0'
compile 'com.google.android.gms:play-services:7.5.0'
compile 'com.google.code.gson:gson:2.3.1'
compile group: 'com.google.guava', name: 'guava', version: '18.0'
}
Any help on fixing these errors would be appreciated.
I looked through my libs but wasn't able to find any conflicts between them
google-play-services.jar
would appear to conflict with compile 'com.google.android.gms:play-services:7.5.0'
. Remove that JAR and see if that helps.
这篇关于谷歌Android播放服务重复项的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!