Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support jpackage #94

Open
sormuras opened this issue Dec 6, 2019 · 6 comments
Open

Support jpackage #94

sormuras opened this issue Dec 6, 2019 · 6 comments

Comments

@sormuras
Copy link
Owner

sormuras commented Dec 6, 2019

public ToolCall computeMainJPackageCall() {
return Command.builder("jpackage").build();
}

@sormuras
Copy link
Owner Author

jpackage shipped with JDK 15-ea+33-1546 still warns about Using incubator modules: jdk.incubator.jpackage

@sormuras
Copy link
Owner Author

sormuras commented Nov 9, 2020

Integrated according to https://openjdk.java.net/jeps/392

But, module jdk.jpackage reads java.desktop ... 🥴

@sormuras
Copy link
Owner Author

Learnings from using jlink and jpackage:

  • jpackage on Windows requires https://wixtoolset.org which in turn doesn't run on .NET 5, yet.
  • jlink module java.net.http also requires jdk.crypto.ec for SSL hand-shakes (HTTPS)
  • junit and other tools may required more system modules, like java.logging, java.management, etc.

Especially the last finding will prevent that Bach will ship as a self-contained Java application. A full JDK with all system modules is mandatory.

@sormuras
Copy link
Owner Author

sormuras commented Nov 13, 2020

When creating a custom runtime image via jlink that includes module jdk.compiler and its dependencies, the resulting javac tool of that image doesn't support the --release option.

The error message reads, using 16-ea+24 as the basis and --release 16 on the command:

  release version 16 not supported
    Usage: javac <options> <source files>
    use --help for a list of possible options

Running javac --help from within the custom image lacks all numbers:

[...]
  --release <release>
        Compile for the specified Java SE release. Supported releases:
  -s <directory>               Specify where to place generated source files
  --source <release>, -source <release>
        Provide source compatibility with the specified Java SE release.
        Supported releases: 7, 8, 9, 10, 11, 12, 13, 14, 15, 16
[...]

The help texts for options --source and --target do show all numbers.

Am I missing something? Perhaps an internal(?) module that contains the API definitions used by javac?

Tracked via https://bugs.openjdk.java.net/browse/JDK-8256343

@sormuras sormuras added this to the 16 milestone Nov 21, 2020
@sormuras
Copy link
Owner Author

@sormuras
Copy link
Owner Author

sormuras commented Nov 25, 2020

Next tests and results here: sormuras/bach-demo-javafx#1

Seems like keeping jpackage as dedidacted and platform-dependend job (including the build itself, due to "natives") is a better solution.

@sormuras sormuras removed this from the 16 milestone Dec 3, 2020
@sormuras sormuras added this to the 17 milestone Dec 29, 2020
@sormuras sormuras modified the milestones: 17, 17-ea-2, 17-ea-3 Mar 19, 2021
@sormuras sormuras modified the milestones: 17-ea-3, 17-ea-4 Apr 10, 2021
@sormuras sormuras modified the milestones: 17-ea-5, 18 Sep 1, 2021
@sormuras sormuras removed this from the 18 milestone Dec 19, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant