fvarrui / JavaPackager

:package: Gradle/Maven plugin to package Java applications as native Windows, MacOS, or Linux executables and create installers for them.
GNU General Public License v3.0
1.07k stars 133 forks source link

Incorrect `jvm_path` param used when bundling with `why` #249

Closed ykrasik closed 1 year ago

ykrasik commented 2 years ago

I'm submitting a…

Short description of the issue/suggestion: Trying to bundle an app with a JRE using why on Windows results in a file that cannot be launched.

That's (partly) because the generated launcher.ini file uses a property jvm_path to point to the jre dir, but the why docs say it should be called jvm_install.

Steps to reproduce the issue/enhancement:

javapackager {
    bundleJre = true
    jrePath = new File(System.properties['java.home'])
    winConfig {
        exeCreationTool = 'why'
    }
}

What is the expected behavior?

What is the current behavior?

Do you have outputs, screenshots, demos or samples which demonstrate the problem or enhancement?

What is the motivation / use case for changing the behavior?

Please tell us about your environment:

Other information (e.g. related issues, suggestions how to fix, links for us to have context)

fvarrui commented 2 years ago

Hi @ykrasik! Sorry for my late reply... Yes, you are right, since JavaPackager is using the last why launcher version, but launcher.ini is not updated. Thanks! I'll fix it in 1.7.0

fvarrui commented 2 years ago

Fixed in issue-250 branch.

fvarrui commented 1 year ago

JavaPackager 1.7.0 released to Maven Central