Opened 15 months ago

Last modified 13 months ago

#2729 new misc

Adopt JPackage for Windows and Mac installs

Reported by: Zlatin Balevsky Owned by:
Priority: minor Milestone: undecided
Component: installer Version: 0.9.45
Keywords: jlink jpackage Cc:
Parent Tickets: Sensitive: no


With Java 14 comes a tool called JPackage which promises to provide a single "right way" of packaging Java applications. More information and background available here

I'm already using it successfully in MuWire? on Windows for step 2 of the following 3-step process:

  1. Create a mini-JRE with JLink
  2. Create an executable with JPackage
  3. Create final installer with NSIS

(code available at

JPackage can take care of all three steps at once, but the necessity to place the reseed certificates and the geoip database in specific locations forces me to use good old NSIS for the third step. If that can somehow be resolved e.g. with a code change to be able to specify location for these resources I'll happily switch to JPackage for the whole process.

On Mac, JPackage supposedly can generate and sign .dmg images which are the preferred way of distributing applications on Mac.

According to Oracle will keep the Java 8 download available at least until end of 2020, so I think it's not too soon to start looking for an alternative to the current packaging process.


#2740: News feed enhancements for multiple productsnewzzz

Change History (7)

comment:1 Changed 15 months ago by zzz

Notes after discussion on IRC:

  • Auto-update the major unsolved problem
  • May require us to release every time JRE fixes come out
  • Would need to change our update scheme to have different feeds for different architectures
  • size isn't insane - 35 MB
  • definitely mac and windows only
  • JEP says it's an 'incubator module', no guarantees - probably don't want to jump on this until it stabilizes (15?)
  • seems odd that jpackage won't let you put arbitrary files in the installation directory? I think we have a config for the geoip file but definitely not for the certs dir. There's lots of things we expect in the intallation directory, not just those. In any case, those are straightforward to deal with if we want to.
  • wrapper issue unsolved also - although whatever the restarter/updater fix is may solve that also.

The update issue is about 90% of the uncertainty and work remaining here, sounds like you've solved the rest of it.

Last edited 15 months ago by zzz (previous) (diff)

comment:2 Changed 15 months ago by zzz

To clarify - not saying that full auto-update is definitely a requirement, but maybe it is. I guess the typical windows experience is that you get notified of an update, you download it manually, and go through the installer process again.

Even if that's sufficient, there's still changes required to our update system to handle arch-specific notifications and updates (bullet 3 above)

comment:3 Changed 15 months ago by Zlatin Balevsky

I don't really know what the typical windows experience is, but Firefox at least doesn't require the user to go through the installer again.

For MuWire I've implemented per-package-type update notification and in-network download of the respective installer, but do require the user to go through the installer process. This has benefits and drawbacks. The drawbacks are obvious, but the benefits are:

  • More flexibility in the update process as every component gets updated, incl. JRE and license
  • Less danger for the end-user should the package builder get coerced to make undesired changes. This is an unlikely, but not impossible scenario. (It's what happened with LimeWire)

comment:4 Changed 15 months ago by zzz

Added another version field to CoreVersion? so we would not publish the point release number in the netdb, in b179cda75e8ca8abf5bac3c4bee89dcac9e535e3 to be 0.9.45-18

comment:5 Changed 15 months ago by zzz

Add a subticket #2740 (News feed enhancements for multiple products).

comment:7 Changed 13 months ago by Zlatin Balevsky

Two Gradle plugins that may streamline the process. The Gradle system is sitting there doing nothing anyway as it stands.

Note: See TracTickets for help on using tickets.