任务':app:transformClassesWithJarMergingForRelease的执行失败

时间:2017-09-29 07:15:58

标签: android android-studio

任务执行失败':app:transformClassesWithJarMergingForRelease

  

Com.android.build.api.transform.TransformException:java.util.zip.ZipException:重复条目:android / support / v4 / printHelper $ printHelperStublmpl.class

我的gradle属性

android {
    compileSdkversion 26
    BuildToolsversion "26.0.1"
    defaultConfig {
        applicationID "com.blaze.buildbox"
        MinSdkversion 14
        Targeted Sdkversion 26
        MultiDexEnabled true

        ndk {
            moduleName "player_shared"
        }

        dexOptions{
            JavaMaxHeapSize "4g"
        }
    }
    BuildTypes {
        Release {
            minifyEnabled false
            ProgaurdFile getDefaultProgaurdFile('progaurd-android.txt'),'progaurd-rules.txt'
        }
    }
    sourceSets.main{
        Jni.srcDirs=[]
    }
}

dependencies

    Compile ('com.google.android.gms:play-service:+) { exclude module : 'support-v4'}
    Compile files ('Libs/javax.inject-1.2.2.jar')
    Compile files('Libs/nineoldandroids-2.4.0.jar')
    Compile files('Libs/support-v4-19.0.1.jar')

}

1 个答案:

答案 0 :(得分:0)

您似乎为printHelper添加了多个库。

每次遇到重复输入错误时都会运行./gradlew app:dependencies并确保没有相同模块的重复版本。