1
votes

Error:Execution failed for task

':app:transformResourcesWithMergeJavaResForDebug'.

com.android.build.api.transform.TransformException: com.android.builder.packaging.DuplicateFileException: Duplicate files copied in APK META-INF/LICENSE File1: C:\Users\Jithin-PC.gradle\caches\modules-2\files-2.1\com.fasterxml.jackson.core\jackson-core\2.2.2\d20be6a5ddd6f8cfd36ebf6dea329873a1c41f1b\jackson-core-2.2.2.jar File2: C:\Users\Jithin-PC.gradle\caches\modules-2\files-2.1\com.fasterxml.jackson.core\jackson-databind\2.2.2\3c8f6018eaa72d43b261181e801e6f8676c16ef6\jackson-databind-2.2.2.jar File3: C:\Users\Jithin-PC.gradle\caches\modules-2\files-2.1\com.fasterxml.jackson.core\jackson-annotations\2.2.2\285cb9c666f0f0f3dd8a1be04e1f457eb7b15113\jackson-annotations-2.2.2.jar

Before updating of Android studio to 2.2 it works well. pls help me..

1

1 Answers

2
votes

I also faced the same issue a couple of days ago. This is not a proper solution but more of a hack.

android {
    packagingOptions {
//        exclude 'META-INF/LICENSE.txt'
//        exclude 'META-INF/LICENSE'
//        exclude 'META-INF/license.txt'
        pickFirst  'META-INF/LICENSE'
    }
}

Try it.