我的应用程序出现问题! build.gradle同步并没有错误,但是当我想运行应用程序错误!这是错误:错误:执行任务失败':找到我:transformResourcesWithMergeJavaResForDebug'
Error:Execution failed for task ':Find Me:transformResourcesWithMergeJavaResForDebug'.
com.android.build.api.transform.TransformException: com.android.builder.packaging.DuplicateFileException: Duplicate files copied in APK META-INF/LICENSE File1: C:\Users****\workspace\Find Me\libs\httpclient-4.5.1.jar
File2: C:\Users****\workspace\Find Me\libs\httpclient-cache-4.5.1.jar
File3: C:\Users****\workspace\Find Me\libs\httpclient-win-4.5.1.jar
File4: C:\Users****\workspace\Find Me\libs\httpcore-4.4.3.jar
其的build.gradle:
apply plugin: 'com.android.application'
dependencies {
compile fileTree(dir: 'libs', include: '*.jar')
compile project(':android-support-v7-appcompat')
compile project(':CircularImageView')
compile project(':FacebookSDK')
compile project(':google-play-services_lib')
compile project(':google-play-services_lib')
compile project(':FacebookSDK')
compile project(':android-support-v7-appcompat')
compile project(':CircularImageView')
}
android {
compileSdkVersion 23
buildToolsVersion "25.0.1"
sourceSets {
main {
manifest.srcFile 'AndroidManifest.xml'
java.srcDirs = ['src']
resources.srcDirs = ['src']
aidl.srcDirs = ['src']
renderscript.srcDirs = ['src']
res.srcDirs = ['res']
assets.srcDirs = ['assets']
}
// Move the tests to tests/java, tests/res, etc...
instrumentTest.setRoot('tests')
// Move the build types to build-types/<type>
// For instance, build-types/debug/java, build-types/debug/AndroidManifest.xml, ...
// This moves them out of them default location under src/<type>/... which would
// conflict with src/ being used by the main source set.
// Adding new build types or product flavors should be accompanied
// by a similar customization.
debug.setRoot('build-types/debug')
release.setRoot('build-types/release')
}
}
谢谢
谢谢,但还是同样的错误! – user2003857
@ user2003857你能告诉我你使用编译项目的原因吗?你在编辑这些文件吗? –
@ user2003857检查我的编辑 –