2017-05-26 2 views
7

Fehler: Ausführung fehlgeschlagen für Task ': app: transformResourcesWithMergeJavaResForDevDebug'.Kopieren von doppelten Dateien in APK error_prone/Annotations.gwt.xml in interactimedia

com.android.build.api.transform.TransformException: com.android.builder.packaging.DuplicateFileException: Duplicate files copied in APK error_prone/Annotations.gwt.xml File1: /Users/manmohansingh/.android/build-cache/c5c673e638724b8a150c9a07f761f05b8fef0253/output/jars/classes.jar File2: /Users/manmohansingh/.gradle/caches/modules-2/files-2.1/com.google.ads.interactivemedia.v3/interactivemedia/3.6.0/76bc1544c67335c4bb38631001fd05a3e70004e4/interactivemedia-3.6.0.jar

+0

ich habe ein gleiches Problem: { – do01

Antwort

15

Nach drei Stunden kämpfen, bekamen diese Lösung:

packagingOptions { 
    exclude 'error_prone/Annotations.gwt.xml' 
    exclude 'third_party/java_src/error_prone/project/annotations/Annotations.gwt.xml' 
    exclude 'third_party/java_src/error_prone/project/annotations/Google_internal.gwt.xml' 
} 

FINAL diese Zeilen in

hinzufügen:

packagingOptions { 
    exclude 'META-INF/DEPENDENCIES.txt' 
    exclude 'META-INF/LICENSE.txt' 
    exclude 'META-INF/NOTICE.txt' 
    exclude 'META-INF/NOTICE' 
    exclude 'META-INF/LICENSE' 
    exclude 'META-INF/DEPENDENCIES' 
    exclude 'META-INF/notice.txt' 
    exclude 'META-INF/license.txt' 
    exclude 'META-INF/dependencies.txt' 
    exclude 'META-INF/LGPL2.1' 
    exclude 'META-INF/rxjava.properties' 

    exclude 'error_prone/Annotations.gwt.xml' 
    exclude 'third_party/java_src/error_prone/project/annotations/Annotations.gwt.xml' 
    exclude 'third_party/java_src/error_prone/project/annotations/Google_internal.gwt.xml' 
} 
+0

Thank you! Das hat enorm geholfen. –

Verwandte Themen