Feature request
Please include the following information:
Is your feature request related to a problem? Please describe.
On Windows (maybe also on other systems, didn't check that), when creating a native image and then double-clicking the built executable, I couldn't find a way to not display a console/terminal (for example, when your native image opens a window/GUI with Swing/JavaFX/SWT).
The additionnal option should behave the same way the "javaw" command works on Windows : being able to start the program without opening a console/terminal if your program doesn't need it.
Describe the solution you'd like.
An option while calling native-image ?
Describe who do you think will benefit the most.
GraalVM users that doesn't need a console/terminal to open each time they double-click their native-image program (programs with GUI, services in background, etc)
Describe alternatives you've considered.
None
Additional context.
Example SWT Hello world project : https://github.com/mbarbeaux/graalvm-swt-native-image/
Just set your JAVA_HOME to a GraalVM 20.0.0 java8 on Windows, and then do mvnw.cmd -Pnative clean package to build the native image, and double click the result. A console prompt opens and stays in background of the SWT window. If you close the console prompt, programs is stopped.
Express whether you'd like to help contributing this feature
If you'd like to contribute, please read the contribution guide.
This is the answer I got on slack and I don't know why it's not mentioned here, so leaving it here, for anyone else who runs into this issue
The compiled executable can be easily modified with a tool that comes with windows SDK:
EDITBIN /SUBSYSTEM:WINDOWS executable.exe
I was able to get it working by tunning that command on the already built executable.
Most helpful comment
This is the answer I got on slack and I don't know why it's not mentioned here, so leaving it here, for anyone else who runs into this issue
The compiled executable can be easily modified with a tool that comes with windows SDK:
I was able to get it working by tunning that command on the already built executable.