Miguel Oliveira
08/16/2023, 5:47 PMCannot inline bytecode built with JVM target 17 into bytecode that is being built with JVM target 1.8. Please specify proper '-jvm-target' option
in lines such as
@Mock
val someService = mock(classOf<SomeService>())
How can I specify this '-jvm-target'?
Currently using kotlin multiplatform 1.9.0 and ksp 1.9.0-1.0.13 plugins. The kmp module is configured with:
kotlin {
targetHierarchy.default()
androidTarget {
compilations.all {
kotlinOptions {
languageVersion = "1.6"
apiVersion = "1.6"
jvmTarget = "1.8"
}
}
}
iosX64()
iosArm64()
iosSimulatorArm64()
...
}
...
android {
...
compileOptions {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
}
}
Sorry if this is not at all related to ksp.Nicklas Jensen
08/16/2023, 8:14 PMMiguel Oliveira
08/16/2023, 10:42 PMNicklas Jensen
08/17/2023, 4:57 AMNicklas Jensen
08/17/2023, 7:47 AM2.0.1
this morning that aims to address the issue you're experiencing. Please let me know if it resolves your issue 🙂Miguel Oliveira
08/17/2023, 9:14 AM