I am building my Java product in Windows and generating an MSI installer for my product.
Is it possible to build an .MSI installer file for my product in Ubuntu, which would run on Windows?
I am building my Java product in Windows and generating an MSI installer for my product.
Is it possible to build an .MSI installer file for my product in Ubuntu, which would run on Windows?
AFAIK there are no tools to create MSI packages on Ubuntu (MS in MSI stands for "Microsoft", and MSI is pretty much limited to the Windows platform). You can package Ubuntu (and other flavours) in packages of various forms (apt, snap, tarballs, etc.) -- see http://packaging.ubuntu.com/html/packaging-new-software.html, for example. But using the same package for Windows and Linux (or other Unixen) is not really a realistic option, given the vast fundamental differences between the two OS platforms.
javapackager performs tasks related to packaging and signing Java and JavaFX applications. javapackager is provided by openjfx in Ubuntu 16.04 and Ubuntu 18.04.
From the results of man javapackager
.
SYNOPSIS javapackager command [options] command The task that should be performed. options One or more options for the command separated by spaces. COMMANDS You can specify one of the following commands. After the command, specify the options for it. -createbss Converts CSS files into binary form. -createjar Produces a JAR archive according to other parameters. -deploy Assembles the application package for redistribution. By default, the deploy task generates the base application package, but it can also generate a self-contained application package if requested. -makeall Performs compilation, createjar, and deploy steps as one call, with most arguments predefined, and attempts to generate all applicable self-contained application packages. The source files must be located in a folder called src, and the resulting files (JAR, JNLP, HTML, and self-contained application packages) are put in a folder called dist. This command can only be configured in a minimal way and is as automated as possible. -signjar Signs JAR file(s) with a provided certificate.
In Ubuntu 18.10 and later javapackager has been removed from OpenJFX. You can replace it with msi-packager.