First Here\'s my Java Build Path in Eclipse:

These four jars \'common.jar,core
I use the following scenario, the perfect solution!
XXX.jar to LibraryFind this in your project .gradle:
allprojects {
repositories {
jcenter()
}
}
Change it to:
allprojects {
repositories {
jcenter()
}
gradle.projectsEvaluated {
tasks.withType(JavaCompile) {
options.compilerArgs.add('-Xbootclasspath/p:app\\libs\\XXX.jar')
}
}
}
In YourApplicationName.iml file, adjust the XXX.jar to top, like this
so, it's ok!