mbonnin
08/26/2021, 4:06 PM'compileJava' task (current target is 11) and 'compileKotlin' task (current target is 1.8) jvm target compatibility should be set to the same Java version.
Except that I don't have any java source in this project. Can I disable the javaCompile task somehow?edrd
08/26/2021, 4:27 PMtasks.withType<JavaCompile> {
onlyIf { false }
}
mbonnin
08/26/2021, 4:29 PMedrd
08/26/2021, 4:30 PMmbonnin
08/26/2021, 4:31 PMmbonnin
08/26/2021, 4:32 PMtargetCompatibility = 1.8
in my gradle script but that feels kind of misleading since there's no java to be foundedrd
08/26/2021, 4:34 PMmbonnin
08/26/2021, 4:36 PMVampire
08/27/2021, 10:42 AMenabled = false
over onlyIf { false }
:-)edrd
08/27/2021, 12:10 PMenabled
Dariusz Kuc
08/27/2021, 10:11 PM1.5.30
(multi module pure kotlin project)...
I'm using SDKMAN and got both Java 8 and 11 (default) installed locally - when I set the toolchain version to Java 8 kapt blew up (when processing spring annotation) unable to find java.lang
packages - without toolchain config it run fine just with the warning above.
Might be unrelated but my test android (using Android tools 7.0.1) build also blew up on version update (without setting java toolchain) with Cannot have abstract method KotlinJavaToolchain.getJdk()
- works fine with 1.5.21
Dariusz Kuc
08/27/2021, 10:11 PMtapchicoma
09/06/2021, 9:02 AMkotlin.jvm.target.validation.mode=ignore
into gradle.properties
mbonnin
09/06/2021, 9:03 AMmbonnin
09/06/2021, 9:03 AMtapchicoma
09/06/2021, 9:03 AMtapchicoma
09/14/2021, 9:17 AMthere is a bug that KGP creates java tasks as well when no java sources are available.Actually KGP apply
java-library
plugin, but should not trigger creation of registered Java tasks when Java sourceset is empty