summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorMichael R Sweet <michael.r.sweet@gmail.com>2019-05-15 17:07:55 -0400
committerMichael R Sweet <michael.r.sweet@gmail.com>2019-05-15 17:07:55 -0400
commit9914f0fe309caf7b80ecc396c903cd93c8e166ab (patch)
tree29a0d1b52c4813bd6bc28b027e239dbdf7593c6a /scripts
parentc8a5a28c0a17228d8e7f70d69b5834c4d47684eb (diff)
downloadcups-9914f0fe309caf7b80ecc396c903cd93c8e166ab.tar.gz
Use zopfli to further compress source archives, when available.
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/makesrcdist18
1 files changed, 13 insertions, 5 deletions
diff --git a/scripts/makesrcdist b/scripts/makesrcdist
index 1ef0442ec..33b2f37cc 100755
--- a/scripts/makesrcdist
+++ b/scripts/makesrcdist
@@ -83,7 +83,7 @@ else
fi
fileurl=`echo $fileurl | sed -e '1,$s/\\//\\\\\\//g'`
-file="cups-$fileversion-source.tar.gz"
+file="$HOME/cups-$fileversion-source.tar"
echo Exporting $fileversion...
rm -rf $TMPDIR/cups-$version
@@ -100,15 +100,23 @@ rm -rf .gitignore
cd ..
echo Archiving...
-tar czf $file cups-$version
+tar cf $file cups-$version
+
+echo Compressing...
+if (which zopfli >/dev/null); then
+ zopfli $file
+ rm -f $file
+else
+ gzip -v9 $file
+fi
if test $SIGNFILES = yes; then
echo Signing...
- test -f $file.sig && rm -f $file.sig
- gpg --detach-sign -u security@cups.org $file
+ test -f $file.gz.sig && rm -f $file.gz.sig
+ gpg --detach-sign -u security@cups.org $file.gz
fi
echo Removing temporary files...
rm -rf cups-$version
-echo "Done - files in $TMPDIR."
+echo "Done - files in $HOME."