-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Module support for native-image building #1962
Comments
Being able to build Java 11 javac to a native-image is a good test-case for this issue. |
#2372 addresses the modularization of the image builder itself. |
In version 19.3 of GraalVM Native Image Java 11 support was added but without support for the Java Platform Module System (JPMS) and also no module introspection at image run time.
Thanks |
Hello @joerg-wille adding module support to native-image is actively being worked on. This will allow to build images on the module path (e.g. Currently the changes that enable this are only available when building GraalVM with a special environment variable While this will not be part of 21.2 we are working on getting this released as soon as possible. |
@olpaw I guess we have an update here, right?:) |
Correct. While the feature is still experimental, as of GraalVM 21.3, images can be built from Java modules. I.e. now As said, this is still experimental and we a look forward for feedback from early adopters.
|
The follow up PR for future improvements is #3935 |
The native-image source base needs to be modularized similar to what already happened for other parts of our GraalVM stack. This will help to get rid of all the
--add-exports
that we currently need when we run the image builder on Java 11+.Additionally we need support for specifying the application that we want to build an image from on the module path. I.e. we need to support
native-image --module-path
. Specifically we need-p <module path>
--module-path <module path>...
-m
or--module <module>
--add-opens
&--add-exports
Adding support for 'native-image ' would also be nice to have.
The text was updated successfully, but these errors were encountered: