-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
Add documentation to handle Java preview features for building natives #23172
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, thanks. I added a few suggestions.
[NOTE] | ||
.Java preview features | ||
==== | ||
Java code might that relies on preview features requires special attention. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Java code might that relies on preview features requires special attention. | |
Java code that relies on preview features requires special attention. |
==== | ||
Java code might that relies on preview features requires special attention. | ||
To produce a native executable, this means that the `--enable-preview` flag needs to be passed to the underlying native image invocation. | ||
You can do so by prepending the flag with `-J` and passing it as additional native builder argument: `-Dquarkus.native.additional-build-args=-J--enable-preview`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can do so by prepending the flag with `-J` and passing it as additional native builder argument: `-Dquarkus.native.additional-build-args=-J--enable-preview`. | |
You can do so by prepending the flag with `-J` and passing it as additional native build argument: `-Dquarkus.native.additional-build-args=-J--enable-preview`. |
[NOTE] | ||
.Java preview features | ||
==== | ||
Java code might that relies on preview features requires special attention. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Java code might that relies on preview features requires special attention. | |
Java code that relies on preview features requires special attention. |
==== | ||
Java code might that relies on preview features requires special attention. | ||
To test a native executable, this means that the `--enable-preview` flag needs to be passed to surefire plugin. | ||
Adding `<argLine>--enable-preview</argLine>` to surefire plugin `configuration` section is one way to do so. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Adding `<argLine>--enable-preview</argLine>` to surefire plugin `configuration` section is one way to do so. | |
Adding `<argLine>--enable-preview</argLine>` to the Surefire plugin `configuration` section is one way to do so. |
.Java preview features | ||
==== | ||
Java code might that relies on preview features requires special attention. | ||
To test a native executable, this means that the `--enable-preview` flag needs to be passed to surefire plugin. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To test a native executable, this means that the `--enable-preview` flag needs to be passed to surefire plugin. | |
To test a native executable, this means that the `--enable-preview` flag needs to be passed to the Surefire plugin. |
b62361a
to
d04bc0b
Compare
d04bc0b
to
bc9bb38
Compare
@gsmet Fixed comments |
Thanks! |
Based on the feedback in this Zulip stream.