Skip to content
New issue

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

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

Already on GitHub? # to your account

Use the --release option when compiling on JDK 9+ #266

Merged
merged 1 commit into from
Oct 4, 2022

Conversation

Ladicek
Copy link
Contributor

@Ladicek Ladicek commented Oct 4, 2022

When compiling with JDK 8, we still need to use -source and -target, because JDK 8 doesn't know the --release option. However, with JDK 9+, it is better to use --release, which not only instructs the compiler to treat the source code as Java 8 and emit Java 8 bytecode, but also compiles against JDK 8 core library signatures.

This is a follow-up on #265 and is a part of the resolution of #264.

When compiling with JDK 8, we still need to use `-source` and `-target`,
because JDK 8 doesn't know the `--release` option. However, with JDK 9+,
it is better to use `--release`, which not only instructs the compiler
to treat the source code as Java 8 and emit Java 8 bytecode, but also
compiles against JDK 8 core library signatures.
@Ladicek Ladicek added this to the 3.0.2 milestone Oct 4, 2022
@Ladicek Ladicek merged commit 58dd7e7 into smallrye:main Oct 4, 2022
@Ladicek Ladicek deleted the use-release-option branch October 4, 2022 08:18
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant