I'm submitting a…
Short description of the issue/suggestion:
Why uses a JRE lookup mechanism where it would search for a compatible JRE in a few places, one of which is the jvm_install specified in launcher.ini. In the case of bundling the jre, it would make sense to turn off this lookup by setting allow_system_java=false, allow_java_location_lookup=false and check_main_class=false in the generated launcher.ini (docs).
Now, this lookup will only run if why can't find a compatible JRE in the specified jvm_install path, however, I encountered a bug where this lookup ran regardless. Probably not a big deal if Why fix their bug, but overall feels like the more correct behavior.
Steps to reproduce the issue/enhancement:
javapackager {
bundleJre = true
jrePath = new File(System.properties['java.home'])
winConfig {
exeCreationTool = 'why'
}
}
What is the expected behavior?
Generate a launcher.ini with
allow_system_java=false
allow_java_location_lookup=false
What is the current behavior?
Generates a launcher.ini without the above fields.
Do you have outputs, screenshots, demos or samples which demonstrate the problem or enhancement?
What is the motivation / use case for changing the behavior?
There is no point in allowing why to perform a JRE lookup in the case of bundling a JRE with the app.
Please tell us about your environment:
- JavaPackager version: 1.6.7
- OS version: Windows 11
- JDK version: 1.8.0_271
- Build tool:
Other information (e.g. related issues, suggestions how to fix, links for us to have context)
I'm submitting a…
Short description of the issue/suggestion:
Why uses a JRE lookup mechanism where it would search for a compatible JRE in a few places, one of which is the
jvm_installspecified inlauncher.ini. In the case of bundling the jre, it would make sense to turn off this lookup by settingallow_system_java=false,allow_java_location_lookup=falseandcheck_main_class=falsein the generatedlauncher.ini(docs).Now, this lookup will only run if why can't find a compatible JRE in the specified
jvm_installpath, however, I encountered a bug where this lookup ran regardless. Probably not a big deal if Why fix their bug, but overall feels like the more correct behavior.Steps to reproduce the issue/enhancement:
What is the expected behavior?
Generate a
launcher.iniwithWhat is the current behavior?
Generates a
launcher.iniwithout the above fields.Do you have outputs, screenshots, demos or samples which demonstrate the problem or enhancement?
What is the motivation / use case for changing the behavior?
There is no point in allowing
whyto perform a JRE lookup in the case of bundling a JRE with the app.Please tell us about your environment:
Other information (e.g. related issues, suggestions how to fix, links for us to have context)