290 lines
10 KiB
RPMSpec
290 lines
10 KiB
RPMSpec
#
|
|
# spec file for package gzip (Version 1.3.12)
|
|
#
|
|
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
|
|
#
|
|
# All modifications and additions to the file contributed by third parties
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
# upon. The license for this file, and modifications and additions to the
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
# license for the pristine package is not an Open Source License, in which
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
# published by the Open Source Initiative.
|
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
#
|
|
|
|
|
|
|
|
Name: gzip
|
|
Url: http://www.gzip.org/
|
|
License: GPL v2 or later
|
|
Group: Productivity/Archiving/Compression
|
|
AutoReqProv: on
|
|
PreReq: %{install_info_prereq}
|
|
Version: 1.3.12
|
|
Release: 99
|
|
Summary: GNU Zip Compression Utilities
|
|
Source: %{name}-%{version}.tar.gz
|
|
Patch: zgrep.diff
|
|
Patch1: tempfile.diff
|
|
Patch2: zmore.diff
|
|
Patch3: non-exec-stack.diff
|
|
Patch4: http://rsync.samba.org/ftp/unpacked/rsync/patches/gzip-rsyncable.diff
|
|
Patch5: futimens.diff
|
|
Patch6: zdiff.diff
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
|
|
%description
|
|
Gzip reduces the size of the named files using Lempel-Ziv coding LZ77.
|
|
Whenever possible, each file is replaced by one with the extension .gz,
|
|
while keeping the same ownership modes and access and modification
|
|
times.
|
|
|
|
|
|
|
|
Authors:
|
|
--------
|
|
Jean-loup Gailly <gzip@prep.ai.mit.edu>
|
|
|
|
%prep
|
|
%setup -q
|
|
%patch
|
|
%patch1
|
|
%patch2
|
|
%patch3
|
|
%patch4 -p1
|
|
%patch5
|
|
%patch6
|
|
|
|
%build
|
|
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}
|
|
profile_gzip()
|
|
{
|
|
tmpfile=$(mktemp)
|
|
trap "rm -f $tmpfile $tmpfile.gz" EXIT
|
|
tar -cf $tmpfile /usr || true
|
|
time ./gzip $tmpfile
|
|
time ./gzip -d < $tmpfile.gz > /dev/null
|
|
}
|
|
%if %{do_profiling}
|
|
make CFLAGS="$CFLAGS -fprofile-generate"
|
|
profile_gzip
|
|
make clean
|
|
make CFLAGS="$CFLAGS -fprofile-use"
|
|
%else
|
|
make
|
|
%endif
|
|
|
|
%check
|
|
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
|
|
|
|
%install
|
|
make DESTDIR=$RPM_BUILD_ROOT install
|
|
mkdir -p $RPM_BUILD_ROOT/bin
|
|
mv $RPM_BUILD_ROOT/usr/bin/{gzip,gunzip,zcat} $RPM_BUILD_ROOT/bin
|
|
sed -i 's:/usr/bin:/bin:' $RPM_BUILD_ROOT/bin/{gunzip,zcat}
|
|
ln -sf /bin/gzip /bin/gunzip /bin/zcat $RPM_BUILD_ROOT/usr/bin
|
|
ln -sf zmore $RPM_BUILD_ROOT/usr/bin/zless
|
|
ln -sf zmore.1 $RPM_BUILD_ROOT%{_mandir}/man1/zless.1
|
|
|
|
%files
|
|
%defattr(-, root, root)
|
|
/bin/*
|
|
/usr/bin/*
|
|
%doc README README-alpha AUTHORS ChangeLog TODO NEWS THANKS
|
|
%doc %{_infodir}/*.gz
|
|
%doc %{_mandir}/man*/*.gz
|
|
|
|
%post
|
|
%install_info --info-dir=%{_infodir} %{_infodir}/%{name}.info.gz
|
|
|
|
%postun
|
|
%install_info_delete --info-dir=%{_infodir} %{_infodir}/%{name}.info.gz
|
|
|
|
%changelog
|
|
* Tue Mar 10 2009 sf@suse.de
|
|
- added doc files (README, TODO, ...) (bnc #414305)
|
|
* Wed Jan 07 2009 schwab@suse.de
|
|
- Fixup rsyncable patch.
|
|
* Thu May 08 2008 schwab@suse.de
|
|
- Fix zdiff with two compressed files.
|
|
* Sun May 20 2007 schwab@suse.de
|
|
- Fix compiling with glibc 2.6.
|
|
* Sat Apr 14 2007 schwab@suse.de
|
|
- Update to gzip 1.3.12.
|
|
* znew now uses $TMPDIR (default /tmp) instead of always using /tmp.
|
|
* Tue Mar 27 2007 dmueller@suse.de
|
|
- reenable profile feedback
|
|
- remove hardcoded -mcpu=pentiumpro for x86
|
|
* Tue Feb 06 2007 schwab@suse.de
|
|
- Update to gzip 1.3.11.
|
|
* As per the GNU coding standards, the behavior of gzip and its
|
|
companion executables no longer depend on the name used to invoke them.
|
|
For example, 'gzip' and 'gunzip' are no longer hard links;
|
|
instead, 'gunzip' is now a small program that invokes 'gzip -d'.
|
|
* zdiff now checks for subsidiary gzip failures, and works around
|
|
bugs in IRIX 6 sh, Tru64 4.0F ksh, and Solaris 8 bash.
|
|
* 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.
|
|
* Tue Dec 12 2006 schwab@suse.de
|
|
- Update to gzip 1.3.8.
|
|
* Fix some gzip problems:
|
|
- A security fix from Debian 1.3.5-5 was inadvertently omitted.
|
|
- The assembler is now invoked with --noexecstack if supported,
|
|
so that gzip can better resist stack-smashing attacks.
|
|
* Thu Dec 07 2006 schwab@suse.de
|
|
- Update to gzip 1.3.7.
|
|
* Fix some gzip problems:
|
|
- Refuse to compress setuid or setgid files, or files with the sticky bit.
|
|
- Fix more race conditions in setting file permissions and owner,
|
|
removing output files, following symbolic links, and dealing with
|
|
special files.
|
|
- Remove most of the code working around ENAMETOOLONG deficiencies.
|
|
Systems with those deficiencies are long-dead, and the workarounds
|
|
had race conditions on modern hosts.
|
|
- Catch CPU time and file size limit signals, too.
|
|
- Check for read errors when closing files.
|
|
- Fix a core dump caused by a stray abort mistakenly introduced in 1.3.6.
|
|
* Fix some gzexe problems:
|
|
- Improve resistance to denial-of-service attacks.
|
|
- Fix some quoting and escaping bugs.
|
|
- Do not assume /tmp is sticky (though it should be!).
|
|
- Do not assume the working directory can be written.
|
|
- Rely on PATH in the generated executable, as the man page says.
|
|
- Don't assume IFS is sane.
|
|
- Exit with signal's status, if signaled.
|
|
* Mon Dec 04 2006 schwab@suse.de
|
|
- Update to gzip 1.3.6.
|
|
* Fix some race conditions in setting file time stamps, permissions, and owner.
|
|
* Fix some race conditions in signal handling.
|
|
* When gzip exits due to a signal, it exits with the signal's status, not 1.
|
|
* gzip now restores file time stamps to the resolution supported by the
|
|
time-setting primitives of the operating system, typically 1 microsecond.
|
|
Formerly it restored them only to the nearest second.
|
|
* gzip -r no longer attempts to reset the last-access times of directories
|
|
it reads, as this messes up when other processes are reading the directories.
|
|
* The options --version and --help now work on all gzip-installed executables,
|
|
and now use a format similar to other GNU programs.
|
|
* The manual is now distributed under the terms of the GNU Free
|
|
Documentation License without invariant sections or cover texts.
|
|
* Port to current versions of Autoconf, Automake, and Gnulib.
|
|
* Wed Sep 13 2006 schwab@suse.de
|
|
- Verify hash tables when unpacking [#202365].
|
|
* Mon Mar 13 2006 schwab@suse.de
|
|
- Add rsyncable patch [#155442].
|
|
* Wed Jan 25 2006 mls@suse.de
|
|
- converted neededforbuild to BuildRequires
|
|
* Fri Nov 11 2005 pth@suse.de
|
|
- Don't obsolete compress.
|
|
* Mon Oct 31 2005 dmueller@suse.de
|
|
- build with non-executable stack
|
|
* Tue Jul 26 2005 schwab@suse.de
|
|
- Ignore directory part on saved file name [#79292].
|
|
* Tue Apr 19 2005 kukuk@suse.de
|
|
- Remove uncompress symlink [#78331]
|
|
* Thu Mar 24 2005 werner@suse.de
|
|
- Add support for bzip2 and simply pager options to zmore
|
|
* Mon May 03 2004 schwab@suse.de
|
|
- Fix quoting issues in zgrep [#39329].
|
|
* Fri Feb 27 2004 schwab@suse.de
|
|
- Add %%defattr.
|
|
* Tue Dec 02 2003 pthomas@suse.de
|
|
- Remove the patch for tail syntax as it's wrong and unnecessary.
|
|
* Thu Sep 18 2003 mmj@suse.de
|
|
- Fix tail syntax in gzexe [#31229]
|
|
* Thu Aug 28 2003 kukuk@suse.de
|
|
- Make sure we have no hardlinks from /bin to /usr/bin [Bug #29522]
|
|
* Tue Jun 17 2003 pthomas@suse.de
|
|
- Update to 1.3.5
|
|
- gzip now removes any output symlink before writing output file.
|
|
- zgrep etc. scripts now port to POSIX 1003.1-2001 hosts.
|
|
- zforce no longer assumes 14-byte file name length limit.
|
|
- zless is now implemented using less and LESSOPEN, not zmore and PAGER.
|
|
- assembly-language speedups reenabled; were mistakenly disabled in 1.3.
|
|
- Less output is lost when decompressing a truncated file.
|
|
- zgrep now supports --, -H, -h, -L, -l, -C, -d, -m and their long
|
|
equivalents.
|
|
* Wed Jun 04 2003 jh@suse.de
|
|
- Enable profile feedback
|
|
* Thu Apr 24 2003 ro@suse.de
|
|
- fix install_info --delete call and move from preun to postun
|
|
* Tue Apr 15 2003 coolo@suse.de
|
|
- use BuildRoot
|
|
* Sat Feb 08 2003 kukuk@suse.de
|
|
- Readded prereq for install-info, else we cannot install info
|
|
pages
|
|
- Add dir entry to info page
|
|
* Sat Feb 08 2003 ro@suse.de
|
|
- removed prereq for texinfo to avoid prereq-cycle
|
|
* Fri Feb 07 2003 ro@suse.de
|
|
- added install_info macros
|
|
* Wed Jan 29 2003 kukuk@suse.de
|
|
- Remove mimencode requires, it is optional
|
|
* Tue Dec 17 2002 werner@suse.de
|
|
- The `:' line of zgrep will be removed by configure
|
|
- zgrep requzires mimencode from metamail
|
|
* Tue Sep 17 2002 ro@suse.de
|
|
- removed bogus self-provides
|
|
* Thu Mar 14 2002 kukuk@suse.de
|
|
- Add uncompress compat link
|
|
* Wed Feb 06 2002 coolo@suse.de
|
|
- use %%suse_update_config
|
|
* Thu Jan 24 2002 okir@suse.de
|
|
- fixed tempfile race in zdiff (current code used bash noclobber
|
|
which is inherently racey)
|
|
* Wed Jun 06 2001 werner@suse.de
|
|
- Make zgrep knowing about bzip2
|
|
* Tue Apr 03 2001 uli@suse.de
|
|
- fixed for gcc >2.96
|
|
* Tue Mar 27 2001 bk@suse.de
|
|
- use i686 insn scheduling on i386 and strip binaries(performance)
|
|
- make tmpfiles in gzexe secure and improve znew tempdir creation
|
|
- remove unnessary expr use and fix gzip output checking in zforce
|
|
- add simple tests if gzip/gunzip work
|
|
* Mon Nov 27 2000 aj@suse.de
|
|
- Update to gzip 1.3.
|
|
* Wed Aug 23 2000 werner@suse.de
|
|
- Security changes for the znew script
|
|
* Mon May 01 2000 kukuk@suse.de
|
|
- LSB-FHS requires /bin/gunzip and /bin/zcat to /bin/gzip
|
|
* Tue Apr 18 2000 kukuk@suse.de
|
|
- Add /bin/zcat (required by FHS 2.1)
|
|
* Fri Feb 25 2000 schwab@suse.de
|
|
- cleanup spec file, get rid of Makefile.Linux
|
|
- define _GNU_SOURCE for basename declaration
|
|
- /usr/man -> /usr/share/man
|
|
- add gzip.info to file list
|
|
* Mon Sep 13 1999 bs@suse.de
|
|
- ran old prepare_spec on spec file to switch to new prepare_spec.
|
|
* Fri Mar 06 1998 florian@suse.de
|
|
- fixed security bug posted on Dez 27 to bugtraq
|
|
* Thu Jan 08 1998 bs@suse.de
|
|
- fixed "double" /bin/gzip & /usr/bin/gzip
|
|
* Thu Apr 24 1997 bs@suse.de
|
|
- added symlink /bin/gunzip
|
|
* Sun Apr 13 1997 florian@suse.de
|
|
- add bug-fixes from gnu.utils.bugs
|