com.android.build.api.transform.TransformException:com.android.builder.packaging.DuplicateFileException:重复文件 [英] com.android.build.api.transform.TransformException: com.android.builder.packaging.DuplicateFileException: Duplicate files

查看:405
本文介绍了com.android.build.api.transform.TransformException:com.android.builder.packaging.DuplicateFileException:重复文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用android studio 2.0版本。我使用gradle构建程序,请参考以下问题:



我知道这个问题Android Studio 0.7version也有同样的问题。我看到链接



但是这种方法对我不起作用!



你能帮我吗?我在等你!

,也许这是由gradle造成的。
请尝试以下操作:

  packagingOptions {
exclude'META-INF / maven / com.belerweb / pinyin4j / pom.xml'
exclude'META-INF / maven / com.belerweb / pinyin4j / pom.properties'
}

如果您解决了重复问题,但遇到了ClassNotFoundIssue,请转到此 topic


I use android studio 2.0 version. I use the gradle to build the program, take this the question:

I know this question in the Android studio 0.7version have the same question. I see the Link Duplicate files copied (Android Studio 0.4.0)

But, I follow this way:

But this method it doesn't work for me!

Could you help me? I am waiting for you!

解决方案

I came across the same issue and found the duplicate file is nothing to do with AndroidStudio 2.0 preview, maybe it's cause by gradle. please try following:

packagingOptions {
    exclude 'META-INF/maven/com.belerweb/pinyin4j/pom.xml'
    exclude 'META-INF/maven/com.belerweb/pinyin4j/pom.properties'
}

if you have resovled the duplicate issue but come across the ClassNotFoundIssue please refre to this topic.

这篇关于com.android.build.api.transform.TransformException:com.android.builder.packaging.DuplicateFileException:重复文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆