Native packages can be created with an early-access build of JDK-14 which contains the new jpackage tool. For this purpose, JDK-14 must be managed independently of other JDK versions. This can be done with Maven toolchains. For this purpose, a `toolchains.xml` file is required on the building machine. The default location of this file is `~/.m2/toolchains.xml`. It should look similar to this one (JDK paths must be adjusted):
By default, only a modular runtime image is created. However, if the early-access build of JDK-14 with the new jpackage tool is added to the toolchains, a native application package can be created by using the property `desktop-package`:
$ mvn clean install -Ddesktop-package
Usually, the predefined package formats are used: dmg for Mac OS, deb for Linux and msi and exe for Windows. An additional property `jlink-jpackager.package-type` can replace the predefined format of the native application package (only for Mac and Linux). The possible formats are:
- dmg
- pkg
- deb
- rpm
A native package with the `pkg` format can be created by using the following command:
The developer has to make sure that all necessary packaging tools are installed. In case of Windows, msi and exe packages are built. For this purpose, two additional tools are required:
-[WiX toolset](https://wixtoolset.org/) - to create msi installers
-[Inno Setup](http://www.jrsoftware.org/isinfo.php) - to create exe installers (Path environment variable must be set)
Build Profiles
--------------
The Open eCard project uses Maven profiles to modify how the build is
performed and which artifacts are created.
Maven profiles are selected on the commandline by adding the -P option as
follows:
$ mvn -Pprofile1,profile2 <Maven goals>
The following global profiles are defined:
*`release`
Remove debugging symbols from Java bytecode.
The following profiles are module specific:
Module `clients/applet`
*`trace-applet`
Bundle SLF4J extension artifact, so that the applet can emit trace logs.
Module `clients/richclient`
*`bundles-jar-cifs`
Usually the cifs are provided by a seperate artifact. This profile creates
a 'contains everything' jar file for direct execution.
Code Signing
------------
The `applet` and `richclient` modules produce signed artifacts. A dummy
certificate is included in the source distribution, so the build runs in any
case. If another certificate from a trusted CA should be used, then the
following fragment must be inserted into `$HOME/.m2/settings.xml`:
Native packages which are based on a modular runtime image can be built with the new [jpackage](https://openjdk.java.net/jeps/343) tool which is a candidate for JDK-14. Early-access builds are already [provided](https://jdk.java.net/jpackage/). Native packages for the Open eCard can be built by downloading the JDK-14 early-access build, referencing it as toolchain and by specifying the following property:
$ mvn clean install -Ddesktop-package
By default, the packager will take the predefined package types, such as dmg for Mac OS and deb for Linux-based systems. The package type can be overridden for Mac and Linux packages by using the following user property:
You have to make sure the required packaging tools are installed. In case of Windows, msi and exe packages are built. For this purpose, two additional tools are required:
-[WiX toolset](https://wixtoolset.org/) - to create msi installers
-[Inno Setup](http://www.jrsoftware.org/isinfo.php) - to create exe installers (Path environment variable must be set)
More information about the required JDK versions and the setup of the toolchain, can be found in the INSTALL.md file.
License
=======
The Open eCard App uses a Dual Licensing model. The software is always
distributed under the GNU General Public License v3 (GPLv3). Additionally the
software can be licensed in an individual agreement between the licenser and
the licensee.
Run the client
==============
Contributing
============
The build results in a fat jar which can be found under
New developers can find information on how to participate under