Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set JDK versions when running the compiler frontend #1063

Merged
merged 2 commits into from
Jun 28, 2023

Conversation

swankjesse
Copy link
Contributor

This is necessary to load JPMS modules from the JDK.

Unfortunately there's no nice API to fetch the JDK version from the Gradle KotlinCompile task. It exposes an API to write this data but not to read it.

@@ -76,10 +79,10 @@ internal class KotlinFirLoader(
configuration.put(CommonConfigurationKeys.MODULE_NAME, targetName)
configuration.put(CLIConfigurationKeys.MESSAGE_COLLECTOR_KEY, messageCollector)
configuration.put(CommonConfigurationKeys.USE_FIR, true)
configuration.put(JVMConfigurationKeys.JDK_HOME, javaHome)
configuration.put(JVMConfigurationKeys.JDK_RELEASE, jdkRelease)
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@JakeWharton setting these two properties satisfies the removed TODO!

This is necessary to load JPMS modules from the JDK.

Unfortunately there's no nice API to fetch the JDK version
from the Gradle KotlinCompile task. It exposes an API to write
this data but not to read it.
@swankjesse swankjesse merged commit af21f4c into trunk Jun 28, 2023
6 checks passed
@swankjesse swankjesse deleted the jwilson.0628.jdk_versions branch June 28, 2023 20:30
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