Use older JDK toolchains for compiling stdlib and stdlib-jdk7

To prevent using newer JDK API in kotlin sources of these projects.
Note that java sources (of stdlib mainly) are still compiled with JDK 8.

#KT-51907
This commit is contained in:
Ilya Gorbunov
2022-08-30 22:29:06 +02:00
committed by Space
parent 3d9c77efa8
commit 12d3ef41dc
3 changed files with 4 additions and 16 deletions
+2
View File
@@ -57,6 +57,8 @@ artifacts {
}
compileKotlin {
kotlinJavaToolchain.toolchain.use(JvmToolchain.getToolchainLauncherFor(project, JdkMajorVersion.JDK_1_7))
kotlinOptions.jvmTarget = "1.8"
kotlinOptions.freeCompilerArgs = [
"-Xallow-kotlin-package",
"-Xmultifile-parts-inherit",
+2
View File
@@ -105,7 +105,9 @@ DexMethodCountKt.dexMethodCount(project) { task ->
}
compileKotlin {
kotlinJavaToolchain.toolchain.use(JvmToolchain.getToolchainLauncherFor(project, JdkMajorVersion.JDK_1_6))
kotlinOptions {
jvmTarget = "1.8"
freeCompilerArgs = [
"-Xallow-kotlin-package",
"-Xmultifile-parts-inherit",