diff --git a/gzip-1.3.10.tar.gz b/gzip-1.3.10.tar.gz new file mode 100644 index 0000000..7cbc362 --- /dev/null +++ b/gzip-1.3.10.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4470b390d87855863689865593e02f4e2694337393046cc6a6bdb27e47fa6d31 +size 426699 diff --git a/gzip-1.3.9.tar.gz b/gzip-1.3.9.tar.gz deleted file mode 100644 index b8225a0..0000000 --- a/gzip-1.3.9.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:a6fdbe5ce21f5e4ce219375c29e842da517e61a56900a678cf258b4fdd603e72 -size 420737 diff --git a/gzip.changes b/gzip.changes index 5f0fc2d..26c129e 100644 --- a/gzip.changes +++ b/gzip.changes @@ -1,3 +1,15 @@ +------------------------------------------------------------------- +Mon Jan 8 18:13:21 CET 2007 - schwab@suse.de + +- Update to gzip 1.3.10. + * gzip -c and zcat now work on special files, files with special mode bits, + and files with multiple hard links. + * gzip -q now exits with status 2 (not 1) when SIGPIPE is received. + * zcmp and zdiff did not work in the usual case, due to a typo. + * zgrep has many bugs fixed with argument handling, special characters, + and exit status. + * zless no longer mishandles $%=~ in file names. + ------------------------------------------------------------------- Fri Dec 15 11:48:41 CET 2006 - schwab@suse.de diff --git a/gzip.spec b/gzip.spec index c001287..58481bb 100644 --- a/gzip.spec +++ b/gzip.spec @@ -1,7 +1,7 @@ # -# spec file for package gzip (Version 1.3.9) +# spec file for package gzip (Version 1.3.10) # -# Copyright (c) 2006 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2007 SUSE LINUX Products GmbH, Nuernberg, Germany. # This file and all modifications and additions to the pristine # package are under the same license as the package itself. # @@ -17,7 +17,7 @@ License: GNU General Public License (GPL) Group: Productivity/Archiving/Compression Autoreqprov: on PreReq: %{install_info_prereq} -Version: 1.3.9 +Version: 1.3.10 Release: 1 Summary: GNU Zip Compression Utilities Source: %{name}-%{version}.tar.gz @@ -57,10 +57,9 @@ CFLAGS="$RPM_OPT_FLAGS -fomit-frame-pointer \ -W -Wall -Wno-unused-parameter -Wstrict-prototypes -Wpointer-arith" ./configure CFLAGS="$CFLAGS" \ --prefix=%{_prefix} --infodir=%{_infodir} --mandir=%{_mandir} -%if %{do_profiling} - make CFLAGS="$CFLAGS -fprofile-arcs" - for i in 1 2 3 4 5 6 7 8 9 - do +test_gzip() +{ + for i in 1 2 3 4 5 6 7 8 9; do for f in build-aux/texinfo.tex /bin/bash; do basef=${f##*/} time ./gzip -$i < $f > $basef.gz @@ -69,21 +68,16 @@ CFLAGS="$RPM_OPT_FLAGS -fomit-frame-pointer \ cmp $f $basef.test$i done done - make clean - make CFLAGS="$CFLAGS -fbranch-probabilities" +} +%if %{do_profiling} +make CFLAGS="$CFLAGS -fprofile-arcs" +test_gzip +make clean +make CFLAGS="$CFLAGS -fbranch-probabilities" %else - make +make %endif -for i in 1 2 3 4 5 6 7 8 9 -do - for f in build-aux/texinfo.tex /bin/bash; do - basef=${f##*/} - time ./gzip -$i < $f > $basef.gz - ./gzip --test $basef.gz - ./gzip -d < $basef.gz > $basef.test$i - cmp $f $basef.test$i - done -done +test_gzip %install make DESTDIR=$RPM_BUILD_ROOT install @@ -111,6 +105,15 @@ ln -sf zmore.1 $RPM_BUILD_ROOT%{_mandir}/man1/zless.1 %install_info_delete --info-dir=%{_infodir} %{_infodir}/%{name}.info.gz %changelog -n gzip +* Mon Jan 08 2007 - schwab@suse.de +- Update to gzip 1.3.10. + * gzip -c and zcat now work on special files, files with special mode bits, + and files with multiple hard links. + * gzip -q now exits with status 2 (not 1) when SIGPIPE is received. + * zcmp and zdiff did not work in the usual case, due to a typo. + * zgrep has many bugs fixed with argument handling, special characters, + and exit status. + * zless no longer mishandles $%%=~ in file names. * Fri Dec 15 2006 - schwab@suse.de - Update to gzip 1.3.9. * No major changes; only porting fixes. diff --git a/tempfile.diff b/tempfile.diff index e09d723..1b7b375 100644 --- a/tempfile.diff +++ b/tempfile.diff @@ -1,26 +1,6 @@ ---- zdiff.in -+++ zdiff.in -@@ -59,12 +59,12 @@ - case "$2" in - *[-.]gz* | *[-.][zZ] | *.t[ga]z) - F=`echo "$2" | sed 's|.*/||;s|[-.][zZtga]*||'` -- set -C -- trap 'rm -f /tmp/"$F".$$; exit 2' HUP INT PIPE TERM 0 -- gzip -cdfq -- "$2" > /tmp/"$F".$$ || exit -- gzip -cdfq -- "$1" | $comp $OPTIONS - /tmp/"$F".$$ -+ TF=`/bin/mktemp -t "$F".XXXXXXXX` || exit 1 -+ trap 'rm -f "$TF"; exit 2' HUP INT PIPE TERM 0 -+ gzip -cdfq -- "$2" > "$TF" || exit -+ gzip -cdfq -- "$1" | $comp $OPTIONS - "$TF" - STAT="$?" -- /bin/rm -f /tmp/"$F".$$ || STAT=2 -+ /bin/rm -f "$TF" || STAT=2 - trap - HUP INT PIPE TERM 0 - exit $STAT;; - --- znew.in +++ znew.in -@@ -56,8 +56,9 @@ +@@ -55,8 +55,9 @@ # block is the disk block size (best guess, need not be exact) warn="(does not preserve modes and timestamp)" @@ -32,7 +12,7 @@ echo hi > $tmp || exit if test -z "`(${CPMOD-cpmod} $tmp $tmp) 2>&1`"; then cpmod=${CPMOD-cpmod} -@@ -73,7 +74,8 @@ +@@ -72,7 +73,8 @@ # check if GZIP env. variable uses -S or --suffix gzip -q $tmp ext=`echo $tmp* | sed "s|$tmp||"` diff --git a/zgrep.diff b/zgrep.diff index 762bf62..a08156b 100644 --- a/zgrep.diff +++ b/zgrep.diff @@ -1,33 +1,9 @@ --- zgrep.in +++ zgrep.in -@@ -102,13 +102,36 @@ - fi +@@ -149,10 +149,18 @@ - if test $# -eq 0; then -- gzip -cdfq | $grep $opt "$pat" -- exit $? -+ if type -p dd > /dev/null 2>&1 && -+ type -p mimencode > /dev/null 2>&1 && -+ type -p file > /dev/null 2>&1 -+ then -+ uncompress=gzip -+ x=`dd bs=20 count=1 2> /dev/null | mimencode -b` -+ case `echo -n $x | mimencode -u -b | file -b -` in -+ bzip2*) -+ uncompress=bzip2 -+ ;; -+ esac -+ (echo -n $x | mimencode -u -b; cat -) | $uncompress -cdfq | $grep $opt "$pat" -+ exit $? -+ else -+ gzip -cdfq | $grep $opt "$pat" -+ exit $? -+ fi - fi - - res=0 - for i do -- gzip -cdfq -- "$i" | + for i + do + case $i in + *.bz2) + uncompress=bzip2 @@ -36,7 +12,11 @@ + uncompress=gzip + ;; + esac -+ $uncompress -cdfq "$i" | + # Fail if gzip or grep (or sed) fails. + gzip_status=$( + exec 5>&1 +- (gzip -cdfq -- "$i" 5>&-; echo $? >&5) 3>&- | ++ ($uncompress -cdfq -- "$i" 5>&-; echo $? >&5) 3>&- | if test $files_with_matches -eq 1; then - $grep $opt "$pat" > /dev/null && printf '%s\n' "$i" + eval "$grep" >/dev/null && { printf '%s\n' "$i" || exit 2; } elif test $files_without_matches -eq 1; then