Switching library projects to java 8 compilation with exceptions for stdlib/runtime/reflect/test

This commit is contained in:
Ilya Chernikov
2017-08-03 15:42:28 +02:00
parent fca9478fd8
commit 3caa426b76
9 changed files with 47 additions and 9 deletions
+27
View File
@@ -15,6 +15,33 @@ String jdkPath(String version) {
//}
ext.configureJvmProject = { Project project ->
project.configure(project) {
task sourcesJar(type: Jar, dependsOn: classes) {
classifier = 'sources'
from sourceSets.main.kotlin
}
tasks.withType(JavaCompile) {
// sourceCompatibility = 1.6
// targetCompatibility = 1.6
options.fork = true
options.forkOptions.javaHome = file(JDK_18)
}
tasks.withType(project.compileKotlin.class) {
kotlinOptions.jdkHome = JDK_18
doFirst {
System.setProperty("kotlin.colors.enabled", "false")
}
}
test {
executable = "$JDK_16/bin/java"
}
}
}
ext.configureJvm6Project = { Project project ->
project.configure(project) {
task sourcesJar(type: Jar, dependsOn: classes) {
classifier = 'sources'