beryx / badass-runtime-plugin

Create a custom runtime image of your non-modular application
https://badass-runtime-plugin.beryx.org
Apache License 2.0
162 stars 21 forks source link

Use `BaseTask` java home in jpackage tasks #143

Closed fourlastor closed 1 year ago

fourlastor commented 1 year ago

This PR removes the java home in JPackageData and uses instead the one defined in BaseTask.

This is to fix an issue where specifying a different java home in the configuration doesn't apply to the jpackage task.

I tested it by using this branch and running the task test:packageWinX64 on Windows (which will run the jpackage task)

This requires to have a setup like the following:

/construo-gdx
    /jdk/jdk-17.0.8+7 (copy of jdk 17 here)
/badass-runtime-plugin
  1. The runtime plugin (included via composite builds in the project) requires Java 11 to be built (so the entire gradle project is running using java 11 by setting the gradle jvm in intellij)
  2. The jdk specified to the runtime plugin is 17

Checking out the master branch of the runtime plugin fails the build (as it tries to use the gradle jdk - 11, to run jpackage, which doesn't exist), while the fix branch succeeds

fourlastor commented 1 year ago

@hakanai not sure if you saw this pr

hakanai commented 1 year ago

@hakanai not sure if you saw this pr

I think I had, but I had a trip out of the country between seeing it and now, and I have been fighting to get on top of my email and other tasks since returning... 😅