简体   繁体   中英

DuplicateFileException

I have tried all type of packagingOptions , but nothing worked. That is why posting a new question with my error.

Error:

Error:Execution failed for task ':ChatOn_Chat:transformResourcesWithMergeJavaResForDebug'. com.android.build.api.transform.TransformException: com.android.builder.packaging.DuplicateFileException: Duplicate files copied in APK org.jivesoftware.smack/version
File1: C:\\Users\\rashid.android\\build-cache\\11fbeabe7e4519c3c4539d013b76fb32545ef43d\\output\\jars\\classes.jar
File2: F:\\changes SKyCHat\\SkyChat\\HeyYapp-Android\\ChatOn_core\\build\\intermediates\\bundles\\default\\classes.jar

Dependenies of my Main Project:

compile fileTree(dir: "$buildDir/native-libs", include: 'native-libs.jar')
compile fileTree(dir: 'libs', include: '*.jar')
compile project(':ChatOn_core')
compile project(':cropper')
compile project(':stickyListHeaders')
compile "com.nostra13.universalimageloader:universal-image-loader:${rootProject.universalImageLoaderVersion}"
compile "com.google.android.gms:play-services:${rootProject.googlePlayServicesVersion}"
compile('de.keyboardsurfer.android.widget:crouton:1.8.4@aar') {
    exclude group: 'com.google.android', module: 'support-v4'
}
compile "com.nineoldandroids:library:${rootProject.nineoldandroidsVersion}"
compile 'com.github.chrisbanes.actionbarpulltorefresh:library:+'
compile 'com.crashlytics.android:crashlytics:1.1.13'
compile 'com.android.support:appcompat-v7:25.3.1'  

Dependencies of my other Module:

compile 'io.pristine:libjingle:10839@aar'
compile files('libs/quickblox-android-sdk-chat-3.4.jar')
compile files('libs/quickblox-android-sdk-content-3.4.jar')
compile files('libs/quickblox-android-sdk-core-3.4.jar')
compile files('libs/quickblox-android-sdk-messages-3.4.jar')
compile files('libs/quickblox-android-sdk-videochat-webrtc-3.4.jar')

I just solved my problem. I was using same Jar and Dependency.

1st: compile files('libs/quickblox-android-sdk-chat-3.4.jar')
2nd: compile 'com.quickblox:quickblox-android-sdk-chat:3.4'

Thanks everyone!

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM