Thomas Engelmeier
04/07/2023, 12:00 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 kotlin(INLINE_FROM_HIGHER_PLATFORM)
or the versions other way around.. Any hints to get it to work?Chris Lee
04/07/2023, 3:02 PMjava {
toolchain { languageVersion.set(JavaLanguageVersion.of(17))
}
}
wakingrufus
04/08/2023, 1:59 AMThomas Engelmeier
04/08/2023, 12:27 PMClass 'kotlin.reflect.KClass' was compiled with an incompatible version of Kotlin. The binary version of its metadata is 1.8.0, expected version is 1.6.0.
Thomas Engelmeier
04/08/2023, 12:31 PMimport org.jetbrains.kotlin.gradle.tasks.KotlinCompile
plugins {
id 'org.springframework.boot' version '3.0.5'
id 'io.spring.dependency-management' version '1.1.0'
id 'org.jetbrains.kotlin.jvm' version '1.8.20'
id 'org.jetbrains.kotlin.plugin.spring' version '1.8.20'
}
group = 'com.example'
version = '0.0.1-SNAPSHOT'
sourceCompatibility = '17'
configurations {
compileOnly {
extendsFrom annotationProcessor
}
}
repositories {
mavenCentral()
}
java {
toolchain { languageVersion.set(JavaLanguageVersion.of(17))
}
}
dependencies {
implementation 'org.springframework.boot:spring-boot-starter'
implementation 'org.jetbrains.kotlin:kotlin-reflect'
compileOnly 'org.projectlombok:lombok'
developmentOnly 'org.springframework.boot:spring-boot-devtools'
annotationProcessor 'org.projectlombok:lombok'
testImplementation 'org.springframework.boot:spring-boot-starter-test'
}
tasks.withType(KotlinCompile) {
kotlinOptions {
freeCompilerArgs = ['-Xjsr305=strict']
jvmTarget = '17'
}
}
tasks.named('test') {
useJUnitPlatform()
}
wakingrufus
04/08/2023, 12:39 PM