diff options
author | Stephane Peter <megastep@megastep.org> | 2013-04-12 16:49:15 -0700 |
---|---|---|
committer | Stephane Peter <megastep@megastep.org> | 2013-04-12 16:49:15 -0700 |
commit | d8769e6ce1a51768550c0452838b7dfb7e8e3277 (patch) | |
tree | 6654be778589c06945753ea137c6c2226679355c | |
parent | 3ce8e4a29273ab40d5b6d6e8f336b8adfabcc382 (diff) | |
parent | 247190868ad4fa3cba7169afa716151fde668c7c (diff) | |
download | makeself-d8769e6ce1a51768550c0452838b7dfb7e8e3277.tar.gz |
Merge branch 'master' of github.com:megastep/makeself
Conflicts:
README.md
makeself.sh
-rw-r--r-- | README.md | 3 | ||||
-rw-r--r-- | makeself.1 | 6 | ||||
-rwxr-xr-x | makeself.sh | 22 |
3 files changed, 22 insertions, 9 deletions
@@ -74,10 +74,11 @@ The syntax of makeself is the following: * **--gzip** : Use gzip for compression (the default on platforms on which gzip is commonly available, like Linux) * **--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** : Compress using xz instead of gzip. + * **--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. * **--base64** : Encode the archive to ASCII in Base64 format (base64 command required). * **--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) * **--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. @@ -30,12 +30,18 @@ Compress using bzip2. .B --pbzip2 Compress using pbzip2. .TP +.B --xz +Compress using xz. +.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 +.TP .B --notemp The archive will create archive_dir in the current directory and uncompress in ./archive_dir. diff --git a/makeself.sh b/makeself.sh index 930efd3..c0e53b1 100755 --- a/makeself.sh +++ b/makeself.sh @@ -96,7 +96,7 @@ MS_Usage() echo " --pbzip2 : Compress using pbzip2 instead of gzip" echo " --xz : Compress using xz instead of gzip" echo " --compress : Compress using the UNIX 'compress' command" - echo " --tar-extra opt : Append more options to the tar command line" + echo " --complevel lvl : Compression level for gzip xz bzip2 and pbzip2 (default 9)" echo " --base64 : Instead of compressing, encode the data using base64" echo " --nocomp : Do not compress the data" echo " --notemp : The archive will create archive_dir in the" @@ -105,10 +105,11 @@ MS_Usage() echo " a temporary directory" echo " --append : Append more files to an existing Makeself archive" echo " The label and startup scripts will then be ignored" - echo " --current : Files will be extracted to the current directory." - echo " both --current and --target dir imply --notemp." echo " --target dir : Extract directly to a target directory" echo " directory path can be either absolute or relative" + echo " --current : Files will be extracted to the current directory" + echo " Both --current and --target imply --notemp" + echo " --tar-extra opt : Append more options to the tar command line" echo " --nomd5 : Don't calculate an MD5 for archive" echo " --nocrc : Don't calculate a CRC for archive" echo " --header file : Specify location of the header script" @@ -131,6 +132,7 @@ if type gzip 2>&1 > /dev/null; then else COMPRESS=Unix fi +COMPRESS_LEVEL=9 KEEP=n CURRENT=n NOX11=n @@ -186,6 +188,10 @@ do COMPRESS=none shift ;; + --complevel) + COMPRESS_LEVEL="$2" + if ! shift 2; then MS_Help; exit 1; fi + ;; --notemp) KEEP=y shift @@ -331,19 +337,19 @@ fi case $COMPRESS in gzip) - GZIP_CMD="gzip -c9" + GZIP_CMD="gzip -c$COMPRESS_LEVEL" GUNZIP_CMD="gzip -cd" ;; pbzip2) - GZIP_CMD="pbzip2 -c9" + GZIP_CMD="pbzip2 -c$COMPRESS_LEVEL" GUNZIP_CMD="bzip2 -d" ;; bzip2) - GZIP_CMD="bzip2 -9" + GZIP_CMD="bzip2 -$COMPRESS_LEVEL" GUNZIP_CMD="bzip2 -d" ;; xz) - GZIP_CMD="xz -c9" + GZIP_CMD="xz -c$COMPRESS_LEVEL" GUNZIP_CMD="xz -d" ;; base64) @@ -351,7 +357,7 @@ base64) GUNZIP_CMD="base64 -d -i" ;; gpg) - GZIP_CMD="gpg -ac -z9" + GZIP_CMD="gpg -ac -z$COMPRESS_LEVEL" GUNZIP_CMD="gpg -d" ;; Unix) |