Hacker News new | ask | show | jobs
by Atomskun 1406 days ago
What's the problem with jpackage for, say, shipping Windows binaries?

I just let it package a "portable" (no need to install) directory of all dependencies and that's it. Users just download a ZIP and can use my programs.

1 comments

They don't have FX installed. No one does.

The whole idea of using Java is to support something other than Windows. I use a Mac and all companies I worked with had all common OS's on desktops. The edge cases are the problem. This isn't a product for other engineers. At least not engineers who have experience with JVM conflict issues.

For end users and to get a smooth installer experience there's a huge distance. Customizing the installer in the packager is a nightmarish problem... Or at least it was the last time I did it.

I can't use jpackage on Windows to build Mac binaries, but not having FX installed is what kind of problem? Just use jpackage to create an .app for Mac, an installer or portable build for Windows, and a .deb or executable binary for Linux. It bundles all dependencies and users can just click and run it.
That's indeed what we do in our CI but it gets very hairy and the end result is often subpar in nuanced ways. E.g. signing a bundle which required us to upgrade our whole CI infrastructure because we had to move to a newer VM.

The bundle is huge because it needs to include a JRE and JavaFX. The install process and bundle building is complex. Especially with signing. And you need to do it all for every platform.

I see, thanks for the insights.