java.util.zip.ZipException:packageAllDebugClassesForMultiDex 期

java.util.zip.ZipException: duplicate entry during packageAllDebugClassesForMultiDex(java.util.zip.ZipException:packageAllDebugClassesForMultiDex 期间出现重复条目)
本文介绍了java.util.zip.ZipException:packageAllDebugClassesForMultiDex 期间出现重复条目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我不确定这个错误是什么意思.

I am not sure what this error means.

Execution failed for task ':excelSior:packageAllDebugClassesForMultiDex'.
> java.util.zip.ZipException: duplicate entry: android/support/v4/util/TimeUtils.class

我目前正在为我的库使用 android-support-v4.jar

I am currently using android-support-v4.jar for my libraries

dependencies {
    compile project(':addThisSDK')
    compile project(':centeredContentButton')
    compile project(':googleplayservices_lib')
    compile files('libs/adxtag2.4.6.jar')
    compile files('libs/android-support-v4.jar')
    compile files('libs/aws-android-sdk-1.7.1.1-debug.jar')
    compile files('libs/commons-lang-2.6.jar')
    compile files('libs/crittercism_v4_4_0_sdkonly.jar')
    compile files('libs/dd-plist.jar')
    compile files('libs/FiksuAndroidSDK_4.1.1.jar')
    compile files('libs/iqengines-sdk-barcode.jar')
    compile files('libs/irEventTracker-1.2.jar')
    compile files('libs/jolt-core-0.0.7.jar')
    compile files('libs/json-utils-0.0.7.jar')
    compile files('libs/jsoup-1.7.2.jar')
    compile files('libs/kooaba-api-v4-java.jar')
    compile 'com.android.support:multidex:1.0.0'
}

在 gradle 同步期间不会出现错误.就在我尝试运行应用程序时

Error does not show up during gradle sync. Just when I try to run the application

可能是什么问题?

推荐答案

需要检查是否插入了v4库和编译库?您不得在您的应用或依赖程序中重复库.

You need to check that you have inserted v4 library and compile library? You must not repeat library in your app or your dependence program.

删除重复库,只保留一个 V4.

delete the repeat library so that just one V4 remains.

在您的应用程序目录 build.gradle 文件中添加此命令:

in your app dir build.gradle file add this command:

android{


    configurations {
        all*.exclude group: 'com.android.support', module: 'support-v4'
        all*.exclude group: 'com.android.support', module: 'support-annotations'
    }

}

它对我有用!你可以试试!

it works for me! You can try it!

这篇关于java.util.zip.ZipException:packageAllDebugClassesForMultiDex 期间出现重复条目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!

本站部分内容来源互联网,如果有图片或者内容侵犯您的权益请联系我们删除!

相关文档推荐

How to target newer versions in .gitlab-ci.yml using auto devops (java 11 instead of 8 and Android 31 instead of 29)(如何在.gitlab-ci.yml中使用自动开发工具(Java 11而不是8,Android 31而不是29)瞄准较新的版本)
Android + coreLibraryDesugaring: which Java 11 APIs can I expect to work?(Android+core LibraryDesugering:我可以期待哪些Java 11API能够工作?)
How to render something in an if statement React Native(如何在If语句中呈现某些内容Reaction Native)
How can I sync two flatList scroll position in react native(如何在本机Reaction中同步两个平面列表滚动位置)
Using Firebase Firestore in offline only mode(在仅脱机模式下使用Firebase FiRestore)
Crash on Google Play Pre-Launch Report: java.lang.NoSuchMethodError(Google Play发布前崩溃报告:java.lang.NoSuchMethodError)