我得到這個錯誤也與消息:錯誤:執行任務':app:transformClassesWithJarMergingForDebug'失敗。 > zznn.class
com.android.build.api.transform.TransformException: java.util.zip.ZipException: duplicate entry: com/google/android/gms/internal/zznn.class
這是我的Gradle依賴塊。請幫忙。我也有我的multidexenabled真
compile 'com.android.volley:volley:1.0.0'
compile project(':BaseGameUtils')
compile fileTree(dir: 'libs', include: ['*.jar'])
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
})
compile 'com.android.support:appcompat-v7:25.3.1'
testCompile 'junit:junit:4.12'
compile 'com.google.firebase:firebase-appindexing:11.0.2'
compile 'com.google.android.gms:play-services-ads:11.0.2'
compile 'com.android.support:recyclerview-v7:25.3.1'
compile 'com.android.support:design:25.3.1'
compile "com.squareup.picasso:picasso:2.4.0"
compile 'com.github.bumptech.glide:glide:3.5.2'
compile 'de.hdodenhof:circleimageview:1.3.0'
compile 'com.android.support:cardview-v7:25.3.1'
compile 'com.android.support:multidex:1.0.1'
請您可以指定庫,包應該被刪除? –
@AbhinavMasters在'compile'com.google.android.gms:play-services-ads:11.0.2'' – KeLiuyue
@AbhinavMasters之後加入'{ exclude group:'com.google.android.gms' }'另一種方式解決它,你可以看看這個[https://stackoverflow.com/questions/33209631/errorexecution-failed-for-task-apptransformclasseswithjarmergingfordebug](https://stackoverflow.com/questions/33209631/errorexecution-failed-for -task-apptransformclasseswithjarmergingfordebug) – KeLiuyue