From: Rudolf Polzer Date: Fri, 9 Mar 2012 15:59:57 +0000 (+0100) Subject: use infozip to make patches due to symlinks X-Git-Tag: xonotic-v0.7.0~76 X-Git-Url: https://git.rm.cloudns.org/?a=commitdiff_plain;h=22d273247e5c4f7641eb915a63a97e9929b8129d;p=xonotic%2Fxonotic.git use infozip to make patches due to symlinks --- diff --git a/misc/tools/xzipdiff b/misc/tools/xzipdiff index eaaa1fa2..48ad7df6 100755 --- a/misc/tools/xzipdiff +++ b/misc/tools/xzipdiff @@ -31,7 +31,7 @@ makepatchname() echo "$prefix$fromversion"patch"$toversion$suffix" } -zipdiff -f "$from" -t "$to" -o "$output" -x "$excludes" +zipdiff -z "zip -9r" -f "$from" -t "$to" -o "$output" -x "$excludes" tempdir=`mktemp -d -t zipdiff.XXXXXX` cd "$tempdir" @@ -45,7 +45,7 @@ for x in $excludes; do patchname=`makepatchname "$x" "$fromname" "$toname"` patchdir="c/$patchname"; patchdir=${patchdir%/*} mkdir -p "$patchdir" - zipdiff -f a/"$fromname" -t b/"$toname" -o c/"$patchname" + zipdiff -z "zip -9r" -f a/"$fromname" -t b/"$toname" -o c/"$patchname" if [ -f c/"$patchname" ]; then (cd c && zip -0r "$output" "$patchname") fi diff --git a/misc/tools/zipdiff b/misc/tools/zipdiff index aa90c771..4b61c356 100755 --- a/misc/tools/zipdiff +++ b/misc/tools/zipdiff @@ -14,6 +14,7 @@ output= from= to= excludes= +ziptool="7za a -tzip -mx=9" while [ $# -gt 0 ]; do o=$1 @@ -35,6 +36,10 @@ while [ $# -gt 0 ]; do excludes="$excludes $1" shift ;; + -z) + ziptool=$1 + shift + ;; *) usage ;; @@ -163,8 +168,7 @@ case "$output" in ;; esac cd "$tempdir" - #zip -9r "$output" . - 7za a -tzip -mx=9 "$output" . + $ziptool "$output" . cd .. fi ;;