Affects Version/s: 4.3.3
Fix Version/s: None
Enhancement: Add a small utility script 'izpack2sh' which creates a self-extracting linux script or binary. Similar to izpack2exe for Windows or izpack2app for Mac.
- It should allow an optionally bundled JRE as izpack2exe now does, see enhancement IZPACK-561.
- It should have the best possible compression ratio, as good as izpack2exe which uses 7zip.
- It should add minimal overhead to the .jar installer.
- It should require minimal extra /tmp space to unpack itself.
- The RAM required for decompression should be reasonable.
- The utility script should run on as many platforms as possible, not only Linux.
======= PATCH DESCRIPTION =======
Attached is my implementation, which aims to fulfil the above requirements. The utility script is written in Java, but uses native 'tar' and 'xz' to compress the package.
The self-extracting package consists of three parts concatenated together:
(1) sh script (dynamically generated from Java) which extracts parts (2) and (3), launches IzPack installer. About 200 bytes.
(2) xzminidec Linux binary supporting LZMA2 and X86 BCJ decompression. About 9K bytes.
(3) .tar.xz compressed archive, containing IzPack .jar file, optional bundled JRE, etc.
We assume that the Linux end user has certain basic tools available (sh, head/tail, chmod, mkdir, rm, tar).
Utility written by me: