多个索引文件定义Landroid/support/v4/。。。错误

多个索引文件定义Landroid/support/v4/。。。错误,android,compiler-errors,Android,Compiler Errors,我只是包括了一些Glide库和Gradle构建 dependencies { compile fileTree(include: ['*.jar'], dir: 'libs') androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.1', { exclude group: 'com.android.support', module: 'support-annotations' }) compile

我只是包括了一些Glide库和Gradle构建

dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.1', {
    exclude group: 'com.android.support', module: 'support-annotations'
})
compile 'com.android.support:appcompat-v7:23.1.1'
testCompile 'junit:junit:4.12'
compile files('libs/glide-3.7.0.jar')
compile files('libs/glide-3.7.0-javadoc.jar')
compile files('libs/android-support-v4.jar')
annotationProcessor 'com.github.bumptech.glide:compiler:4.0.0-RC1'
}
但我遇到了这样的情况:

Error:Error converting bytecode to dex:
Cause: com.android.dex.DexException: Multiple dex files define Landroid/support/v4/app/ActivityCompatHoneycomb;
除此之外:

Error:Execution failed for task ':app:transformClassesWithDexForDebug'.
> com.android.build.api.transform.TransformException: com.android.ide.common.process.ProcessException: java.util.concurrent.ExecutionException: java.lang.UnsupportedOperationException

如果您有任何关于解决此问题的提示,将不胜感激。

有两个依赖项会导致冲突<代码>编译'com.android.support:appcompat-v7:23.1.1'和
编译文件('libs/android-support-v4.jar')

我手动将
libs/android-support-v4.jar
包含在库目录中,因为Glide需要它,然后删除了
编译文件('libs/android-support-v4.jar')
依赖项。在那之后,梯度同步良好,错误被清除