I get a warning message at Build time in my gradle console:
warning: [options] bootstrap class path not set in conjunction with -source 1.7 1 warning
How can I fix this?
Any help is appreciated!
Simply put the following code inside the buildscript
tag of the project level build.gradle
:
tasks.withType(JavaCompile) {
targetCompatibility = '1.7'
sourceCompatibility = '1.7'
options.setBootClasspath("PATH_TO_JAVA_7_JRE/lib/rt.jar")
}
Just make sure to replace PATH_TO_JAVA_7_JRE
with the path to yours.
I've struggled with this issue myself a couple of weeks now and finally come up with a solution, which hopefully works for others as well. Hope it helps!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With