source: spec/trunk/SPECS/gzip.spec@ 150

Last change on this file since 150 was 150, checked in by Yuri Dario, 15 years ago

spec: add target cpu field in cache file.

  • Property svn:eol-style set to native
File size: 2.9 KB
Line 
1Summary: The GNU data compression program
2Name: gzip
3Version: 1.4
4Release: 3%{?dist}
5# info pages are under GFDL license
6License: GPLv3+ and GFDL
7Group: Applications/File
8Source: http://ftp.gnu.org/gnu/gzip/gzip-%{version}.tar.gz
9
10Patch0: gzip-1.3.12-openbsd-owl-tmp.patch
11Patch1: gzip-1.3.5-zforce.patch
12Patch2: gzip-1.3.9-stderr.patch
13Patch3: gzip-1.3.10-zgreppipe.patch
14Patch4: gzip-1.3.13-rsync.patch
15Patch5: gzip-1.3.9-addsuffix.patch
16Patch6: gzip-1.3.5-cve-2006-4338.patch
17Patch7: gzip-1.3.13-cve-2006-4337.patch
18Patch8: gzip-1.3.5-cve-2006-4337_len.patch
19# Fixed in upstream code.
20# http://thread.gmane.org/gmane.comp.gnu.gzip.bugs/378
21Patch11: gzip-1.3.13-noemptysuffix.patch
22
23Patch100: gzip-os2.diff
24
25URL: http://www.gzip.org/
26#Requires: /sbin/install-info
27#Requires: mktemp less
28#BuildRequires: texinfo
29Buildroot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
30
31%description
32The gzip package contains the popular GNU gzip data compression
33program. Gzipped files have a .gz extension.
34
35Gzip should be installed on your system, because it is a
36very commonly used data compression program.
37
38%prep
39%setup -q
40%patch0 -p1 -b .owl-tmp~
41%patch1 -p1 -b .zforce~
42%patch2 -p1 -b .stderr~
43%patch3 -p1 -b .nixi~
44%patch4 -p1 -b .rsync~
45%patch5 -p1 -b .addsuffix~
46%patch6 -p1 -b .4338~
47%patch7 -p1 -b .4337~
48%patch8 -p1 -b .4337l~
49%patch11 -p1 -b .noemptysuffix~
50
51%patch100 -p1 -b .os2~
52
53%build
54export MAKESHELL=/bin/sh
55export CONFIG_SHELL=/bin/sh
56export DEFS="NO_ASM"
57export CPPFLAGS="-DHAVE_LSTAT"
58export LDFLAGS="-Zbin-files -Zhigh-mem -Zomf -Zexe -Zargs-wild -Zargs-resp"
59%configure \
60 --bindir=/@unixroot/bin \
61 "--cache-file=%{_topdir}/cache/%{name}-%{_target_cpu}.cache"
62
63make %{?smp_mflags}
64#make gzip.info
65
66%install
67rm -rf ${RPM_BUILD_ROOT}
68%makeinstall bindir=${RPM_BUILD_ROOT}/@unixroot/bin
69mkdir -p ${RPM_BUILD_ROOT}%{_bindir}
70#make DESTDIR=${RPM_BUILD_ROOT} install
71
72rm ${RPM_BUILD_ROOT}%{_libdir}/charset.alias
73
74#cp ${RPM_BUILD_ROOT}%{_bindir}/gzip.exe ${RPM_BUILD_ROOT}%{_bindir}/gunzip.exe
75#cp ${RPM_BUILD_ROOT}%{_bindir}/gzip.exe ${RPM_BUILD_ROOT}%{_bindir}/uncomress.exe
76
77for i in zcmp zegrep zforce zless znew gzexe zdiff zfgrep zgrep zmore ; do
78 mv ${RPM_BUILD_ROOT}/@unixroot/bin/$i ${RPM_BUILD_ROOT}%{_bindir}/$i
79done
80
81gzip -9nf ${RPM_BUILD_ROOT}%{_infodir}/gzip.info*
82
83# we don't ship it, so let's remove it from ${RPM_BUILD_ROOT}
84rm -f ${RPM_BUILD_ROOT}%{_infodir}/dir
85# uncompress is a part of ncompress package
86rm -f ${RPM_BUILD_ROOT}/bin/uncompress
87
88%clean
89rm -rf ${RPM_BUILD_ROOT}
90
91%post
92#if [ -f %{_infodir}/gzip.info* ]; then
93# /sbin/install-info %{_infodir}/gzip.info.gz %{_infodir}/dir || :
94#fi
95
96%preun
97#if [ $1 = 0 ]; then
98# if [ -f %{_infodir}/gzip.info* ]; then
99# /sbin/install-info --delete %{_infodir}/gzip.info.gz %{_infodir}/dir || :
100# fi
101#fi
102
103%files
104%defattr(-,root,root)
105%doc NEWS README AUTHORS ChangeLog THANKS TODO
106/@unixroot/bin/*
107%{_bindir}/*
108%{_mandir}/*/*
109%{_infodir}/gzip.info*
110
111%changelog
Note: See TracBrowser for help on using the repository browser.