/[packages]/cauldron/bzip2/current/SPECS/bzip2.spec
ViewVC logotype

Contents of /cauldron/bzip2/current/SPECS/bzip2.spec

Parent Directory Parent Directory | Revision Log Revision Log


Revision 241 - (show annotations) (download)
Fri Jan 7 12:50:50 2011 UTC (13 years, 4 months ago) by pterjan
File size: 3083 byte(s)
imported package bzip2
1 %define major 1
2 %define libname %mklibname %{name}_ %{major}
3 %define develname %mklibname %{name} -d
4
5 %define buildpdf 0
6
7 Summary: Extremely powerful file compression utility
8 Name: bzip2
9 Version: 1.0.5
10 Release: %mkrel 7
11 License: BSD
12 Group: Archiving/Compression
13 URL: http://www.bzip.org/index.html
14 Source0: http://www.bzip.org/%{version}/%{name}-%{version}.tar.bz2
15 Source1: bzgrep
16 Source2: bzme
17 Source3: bzme.1
18 Patch0: bzip2-1.0.5-makefile.patch
19 Requires: mktemp
20 Requires: %{libname} = %{version}-%{release}
21 %if %buildpdf
22 BuildRequires: tetex-dvips
23 BuildRequires: tetex-latex
24 %endif
25 BuildRequires: texinfo
26 BuildRequires: libtool
27 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-buildroot
28
29 %description
30 Bzip2 compresses files using the Burrows-Wheeler block-sorting text
31 compression algorithm, and Huffman coding. Compression is generally
32 considerably better than that achieved by more conventional LZ77/LZ78-based
33 compressors, and approaches the performance of the PPM family of statistical
34 compressors.
35
36 The command-line options are deliberately very similar to those of GNU Gzip,
37 but they are not identical.
38
39 %package -n %{libname}
40 Summary: Libraries for developing apps which will use bzip2
41 Group: System/Libraries
42
43 %description -n %{libname}
44 Library of bzip2 functions, for developing apps which will use the
45 bzip2 library (aka libz2).
46
47 %package -n %{develname}
48 Summary: Header files for developing apps which will use bzip2
49 Group: Development/C
50 Requires: %{libname} = %{version}-%{release}
51 Provides: lib%{name}-devel = %{version}-%{release}
52 Provides: %{name}-devel = %{version}-%{release}
53 Obsoletes: %{mklibname bzip2_ 1 -d} < 1.0.5-3
54 Provides: %{mklibname bzip2_ 1 -d}
55
56 %description -n %{develname}
57 Header files and static library of bzip2 functions, for developing apps which
58 will use the bzip2 library (aka libz2).
59
60 %prep
61
62 %setup -q
63 %patch0 -p1 -b .makefile
64
65 echo "lib = %{_lib}" >> config.in
66 echo "CFLAGS = %{optflags}" >> config.in
67 echo "LDFLAGS = %{ldflags}" >> config.in
68
69 cp %{SOURCE1} bzgrep
70 cp %{SOURCE2} bzme
71 cp %{SOURCE3} bzme.1
72
73 %build
74 %make -f Makefile-libbz2_so
75 %make
76
77 %if %buildpdf
78 texi2dvi --pdf manual.texi
79 %endif
80
81 %install
82 rm -rf %{buildroot}
83
84 %makeinstall_std
85
86 install -m0755 bzme %{buildroot}%{_bindir}/
87 install -m0755 bzgrep %{buildroot}%{_bindir}/
88 install -m0644 bzgrep.1 %{buildroot}%{_mandir}/man1/
89
90 cat > %{buildroot}%{_bindir}/bzless <<EOF
91 #!/bin/sh
92 %{_bindir}/bunzip2 -c "\$@" | %{_bindir}/less
93 EOF
94 chmod 755 %{buildroot}%{_bindir}/bzless
95 install -m 644 %{SOURCE3} %{buildroot}%{_mandir}/man1/
96
97 %if %mdkversion < 200900
98 %post -n %{libname} -p /sbin/ldconfig
99 %endif
100
101 %if %mdkversion < 200900
102 %postun -n %{libname} -p /sbin/ldconfig
103 %endif
104
105 %clean
106 rm -rf %{buildroot}
107
108 %files
109 %defattr(-,root,root,755)
110 %doc README LICENSE CHANGES
111 %{_bindir}/*
112 %{_mandir}/man1/*
113
114 %files -n %{libname}
115 %defattr(-,root,root,755)
116 %doc LICENSE
117 %{_libdir}/libbz2.so.%{major}*
118
119 %files -n %{develname}
120 %defattr(-,root,root,755)
121 %doc *.html LICENSE
122 %if %buildpdf
123 %doc manual.pdf
124 %endif
125 %{_libdir}/libbz2.a
126 %{_libdir}/libbz2.la
127 %{_libdir}/libbz2.so
128 %{_includedir}/*.h
129
130

  ViewVC Help
Powered by ViewVC 1.1.30