当前位置: 动力学知识库 > 问答 > 编程问答 >

Android duplicate entry ZipException error

问题描述:

When I try to build the signed apk I get the following error:

Error:Execution failed for task ':app:transformClassesWithJarMergingForRelease'.

> com.android.build.api.transform.TransformException: java.util.zip.ZipException: duplicate entry: android/support/v4/graphics/drawable/DrawableWrapper.class

I have the following dependencies:

dependencies {

compile fileTree(dir: 'libs', include: ['*.jar'])

testCompile 'junit:junit:4.12'

compile 'org.jraf:android-switch-backport:2.0.1'

compile files('libs/android-query.0.26.7.jar')

compile files('libs/cardio_new.jar')

compile files('libs/PayPalAndroidSDK-2.11.2.jar')

compile files('libs/splunk-mint-4.0.8.jar')

compile 'com.android.support:appcompat-v7:24.1.1'

compile 'com.android.support:cardview-v7:24.1.1'

compile 'com.android.support:design:24.1.1'

compile 'com.google.android.gms:play-services-maps:9.2.1'

compile 'com.google.android.gms:play-services-location:9.2.1'

compile 'com.google.android.gms:play-services-base:9.2.1'

compile 'com.google.android.gms:play-services-auth:9.2.1'

compile 'com.google.android.gms:play-services-gcm:9.2.1'

compile 'com.sromku:simple-fb:4.1.1'

compile 'com.mikhaellopez:circularimageview:2.1.1'

compile 'com.soundcloud.android:android-crop:[email protected]'

compile 'com.viewpagerindicator:library:[email protected]'

compile 'com.stripe:stripe-android:1.0.4'

compile 'com.mcxiaoke.volley:library:1.0.19'

compile ('org.apache.httpcomponents:httpmime:4.3.6') {

exclude module: 'httpclient'

}

compile files('libs/apache-mime4j-core-0.7.2.jar')

compile files('libs/httpclient-4.3.5.jar')

compile files('libs/httpcore-4.3.2.jar')

compile 'com.jakewharton:butterknife:7.0.1'

compile 'net.eunjae.android.modelmapper:ModelMapper:1.0.6'

compile 'org.springframework.android:spring-android-rest-template:2.0.0.M3'

compile 'com.android.support:percent:24.2.0'

compile('com.crashlytics.sdk.android:crashlytics:[email protected]') {

transitive = true;

}

compile 'com.android.support:multidex:1.0.0'

}

As far as I understand, I have more than one library which adds android.support.v4, so I tried to exclude this library from all projects, in order to check if any of these cause the error, but still I got the same problem.

So, how do I find the libraries that include one common library two times?

分享给朋友:
您可能感兴趣的文章:
随机阅读: