Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added support for lzo and lz4 #45

Merged
merged 1 commit into from Apr 15, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
4 changes: 3 additions & 1 deletion README.md
Expand Up @@ -75,12 +75,14 @@ The syntax of makeself is the following:
* **--bzip2** : Use bzip2 instead of gzip for better compression. The bzip2 command must be available in the command path. It is recommended that the archive prefix be set to something like '.bz2.run', so that potential users know that they'll need bzip2 to extract it.
* **--pbzip2** : Use pbzip2 instead of gzip for better and faster compression on machines having multiple CPUs. The pbzip2 command must be available in the command path. It is recommended that the archive prefix be set to something like '.bz2.run', so that potential users know that they'll need bzip2 to extract it.
* **--xz** : Use xz instead of gzip for better compression. The xz command must be available in the command path. It is recommended that the archive prefix be set to something like '.xz.run' for the archive, so that potential users know that they'll need xz to extract it.
* **--lzo** : Use lzop instead of gzip for better compression. The lzop command must be available in the command path. It is recommended that the archive prefix be set to something like '.lzo.run' for the archive, so that potential users know that they'll need lzop to extract it.
* **--lz4** : Use lz4 instead of gzip for better compression. The lz4 command must be available in the command path. It is recommended that the archive prefix be set to something like '.lz4.run' for the archive, so that potential users know that they'll need lz4 to extract it.
* **--base64** : Encode the archive to ASCII in Base64 format (base64 command required).
* **--gpg-encrypt** : Encrypt the archive using "gpg -ac -z $COMPRESS_LEVEL". This will prompt for a password to encrypt with. Assumes that potential users have gpg installed.
* **--ssl-encrypt** : Encrypt the archive using "openssl aes-256-cbc -a -salt". This will prompt for a password to encrypt with. Assumes that the potential users have openssl installed.
* **--compress** : Use the UNIX "compress" command to compress the data. This should be the default on all platforms that don't have gzip available.
* **--nocomp** : Do not use any compression for the archive, which will then be an uncompressed TAR.
* **--complevel** : Specify the compression level for gzip,bzip2,pbzip2 and xz. (default to 9)
* **--complevel** : Specify the compression level for gzip,bzip2,pbzip2,xz,lzo or lz4. (default to 9)
* **--notemp** : The generated archive will not extract the files to a temporary directory, but in a new directory created in the current directory. This is better to distribute software packages that may extract and compile by themselves (i.e. launch the compilation through the embedded script).
* **--current** : Files will be extracted to the current directory, instead of in a subdirectory. This option implies **--notemp** above.
* **--follow** : Follow the symbolic links inside of the archive directory, i.e. store the files that are being pointed to instead of the links themselves.
Expand Down
8 changes: 7 additions & 1 deletion makeself.1
Expand Up @@ -33,14 +33,20 @@ Compress using pbzip2.
.B --xz
Compress using xz.
.TP
.B --lzo
Compress using lzop.
.TP
.B --lz4
Compress using lz4.
.TP
.B --compress
Compress using the UNIX 'compress' command.
.TP
.B --nocomp
Do not compress the data.
.TP
.B --complevel lvl
Specify the compression level for gzip,bzip2,pbzui2 or xz
Specify the compression level for gzip,bzip2,pbzui2,xz,lzo or lz4
.TP
.B --notemp
The archive will create archive_dir in the current directory and
Expand Down
20 changes: 19 additions & 1 deletion makeself.sh
Expand Up @@ -95,8 +95,10 @@ MS_Usage()
echo " --bzip2 : Compress using bzip2 instead of gzip"
echo " --pbzip2 : Compress using pbzip2 instead of gzip"
echo " --xz : Compress using xz instead of gzip"
echo " --lzo : Compress using lzop instead of gzip"
echo " --lz4 : Compress using lz4 instead of gzip"
echo " --compress : Compress using the UNIX 'compress' command"
echo " --complevel lvl : Compression level for gzip xz bzip2 and pbzip2 (default 9)"
echo " --complevel lvl : Compression level for gzip xz lzo lz4 bzip2 and pbzip2 (default 9)"
echo " --base64 : Instead of compressing, encode the data using base64"
echo " --gpg-encrypt : Instead of compressing, encrypt the data using GPG"
echo " --ssl-encrypt : Instead of compressing, encrypt the data using OpenSSL"
Expand Down Expand Up @@ -176,6 +178,14 @@ do
COMPRESS=xz
shift
;;
--lzo)
COMPRESS=lzo
shift
;;
--lz4)
COMPRESS=lz4
shift
;;
--compress)
COMPRESS=Unix
shift
Expand Down Expand Up @@ -367,6 +377,14 @@ xz)
GZIP_CMD="xz -c$COMPRESS_LEVEL"
GUNZIP_CMD="xz -d"
;;
lzo)
GZIP_CMD="lzop -c$COMPRESS_LEVEL"
GUNZIP_CMD="lzop -d"
;;
lz4)
GZIP_CMD="lz4 -c$COMPRESS_LEVEL"
GUNZIP_CMD="lz4 -d"
;;
base64)
GZIP_CMD="base64"
GUNZIP_CMD="base64 -d -i"
Expand Down