Open edigonzales opened 1 year ago
Does the resizing crash is reproduces only with the the used older, small Swing application, or it is able to reproduce the crash with a simple Swing application or a demo like SwingSet2 as well?
Did you use the native-image-agent to prepare the configuration files with all usages of dynamic features during the Swing application resizing? It needs to run the code below and resize the app:
java -agentlib:native-image-agent=config-output-dir=conf-dir -jar SwingApp.jar
and create the native image with the configuration files:
native-image -H:JNIConfigurationFiles=conf-dir/jni-config.json -H:ReflectionConfigurationFiles=conf-dir/reflect-config.json -H:ResourceConfigurationFiles=conf-dir/resource-config.json -H:SerializationConfigurationFiles=conf-dir/serialization-config.json ...
Does the resizing crash is reproduces only with the the used older, small Swing application, or it is able to reproduce the crash with a simple Swing application or a demo like SwingSet2 as well?
Will check that as soon as I'm able to login to oracle to download the demo...
Did you use the native-image-agent to prepare the configuration files with all usages of dynamic features during the Swing application resizing? It needs to run the code below and resize the app:
Yes.
I was able to compile an older, small Swing application with Liberica NIK. I used the agent as suggested in the docs. I'm able to run the application but trying to resizing the application ends with a crash. I tried it with different os and arch versions. Some combinations seem to work (but not always, which is odd): I was able to resize the window if I compiled and ran the application on Apple M1. But sometimes the app crashed even before showing the window.
Ubuntu 22.04 seems to work fine.
Using Liberica NIK 22.2 / Java 17.
Error message (compiled and ran on macOS Catalina):