Skip to content

Conversation

@tweksteen
Copy link
Member

There is a conflict between the compiler used for Java and Kotlin, even if this is defined in the root project's build.gradle. Explicitly note that the targeted jvm version is 1.8.

This was reported by Gradle and prevents the upgrade to Gradle 8.x.

There is a conflict between the compiler used for Java and Kotlin, even
if this is defined in the root project's build.gradle. Explicitly
note that the targeted jvm version is 1.8.

This was reported by Gradle and prevents the upgrade to Gradle 8.x.
@tweksteen
Copy link
Member Author

For an example of the build error message, see yesterday's CI execution on MacOS: https://github.com/google/conscrypt/actions/runs/12000790815/job/33450371030#step:15:43

@prbprbprb
Copy link
Contributor

This warning has been bugging me, but I'm not sure this is the right solution.

The Doclet is using the Java 11 javadoc APIs, so org.jetbrains.kotlin.gradle.dsl.JvmTarget.JVM_1_8 feels wrong. Although if it works, it works :)

@tweksteen
Copy link
Member Author

Yes, you are right. This is odd. I inspected the output .jar of api-doclet and it contains:

Source-Compatibility: 11                                                                                                                                                                                                                            
Target-Compatibility: 11

So I'm not sure if this is a bug in Gradle or in the Kotlin plugin. Either way, I think this is related to how we are currently sharing the logic between the project (aka, the root project build.gradle). I created #1263 which I reckon is the root cause here. Happy to close this PR and follow up with the right approach. Thanks.

@tweksteen tweksteen closed this Nov 25, 2024
@prbprbprb
Copy link
Contributor

#1263 Looks interesting but potentially a lot of work... Happy to go that way if you have the time to work on it.

@tweksteen tweksteen deleted the fix_jvm_kotlin_version branch November 27, 2024 03:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants