<AWT Dev> RFR: 8254024: Enhance native libs for AWT and Swing to work with GraalVM Native Image [v3]
Magnus Ihse Bursie
ihse at openjdk.java.net
Tue Dec 15 21:01:59 UTC 2020
On Mon, 30 Nov 2020 17:53:26 GMT, Andrii Rodionov <github.com+1538227+arodionov at openjdk.org> wrote:
>> The following PR fixes https://bugs.openjdk.java.net/browse/JDK-8254024
>> Starting from version 11.0.9, all JDK libraries also build as static libraries (JEP 178: Statically-Linked JNI Libraries).
>> The purpose of using static libraries is to build GraalVM Native image statically linked with Java native libraries, to shipping single executable without runtime dependencies from JRE.
>> For some static libraries, it leads to an issue: if one static library is trying to load another static library in runtime using `dlopen` (and then uses `dlsym` to find symbols). With static libraries, this is not possible and all dynamic calls should be replaced.
>> This happens in `libawt` while it loads `awt-xawt` or `awt_headless` and in `mlib_image`.
>> Current PR fixes this issue for AWT libraries that allow building Swing/AWT applications as a Native image and have no runtime dependencies from JRE.
> Andrii Rodionov has updated the pull request with a new target base due to a merge or a rebase. The pull request now contains one commit:
> 8254024: Enhance native libs for AWT and Swing to work with GraalVM Native Image
This makes sense from a build PoV, but you'll need approval from the client team as well.
Marked as reviewed by ihse (Reviewer).
More information about the awt-dev