gpt4 book ai didi

java - Android Studio - 错误 :Execution failed for task ':app: ... ase' duplicate entry: com/google/android/gms/internal/zznq. 类

转载 作者:太空宇宙 更新时间:2023-11-04 11:54:29 24 4
gpt4 key购买 nike

当我编译我的项目时,它写道:

Error:Execution failed for task ':app:transformClassesWithJarMergingForRelease'. com.android.build.api.transform.TransformException: java.util.zip.ZipException: duplicate entry: com/google/android/gms/internal/zznq.class

问题出在哪里?我添加到 AdMob 编译依赖项。

 dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile project(':BaseGameUtils2')
compile 'com.android.support:appcompat-v7:24.2.1'
compile 'com.android.support:design:24.2.1'
compile 'com.google.android.gms:play-services-ads:10.0.1'
}

apply plugin: 'com.google.gms.google-services'

谢谢您的回答。

最佳答案

删除应用插件:“com.google.gms.google-services”

compile 'com.google.android.gms:play-services:10.0.1' 替换为 applyplugin: 'compile 'com.google.android.gms:play-services:10.0.1'

问题在于您有重复的 Google 服务依赖项。

关于java - Android Studio - 错误 :Execution failed for task ':app: ... ase' duplicate entry: com/google/android/gms/internal/zznq. 类,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41492357/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com