]>
Commit | Line | Data |
---|---|---|
b74af457 | 1 | # |
2 | # Conditional build: | |
3 | %bcond_without static_libs # don't build static libraries | |
892cabbc ER |
4 | |
5 | Summary: Multi-format archive and compression library | |
da147f22 | 6 | Summary(pl.UTF-8): Biblioteka do archiwizacji i kompresji w wielu formatach |
ac600a23 | 7 | Name: libarchive |
8bb46c95 | 8 | Version: 3.6.1 |
b28cb0a8 | 9 | Release: 1 |
ac600a23 AG |
10 | License: BSD |
11 | Group: Libraries | |
78b9639a JB |
12 | # see main page, downloads index may be out of date |
13 | #Source0Download: http://www.libarchive.org/ | |
f64bdec0 | 14 | Source0: https://www.libarchive.org/downloads/%{name}-%{version}.tar.xz |
8bb46c95 | 15 | # Source0-md5: 9465f7995649c9ea84854a7fd8c76f30 |
417d5b05 | 16 | Patch0: %{name}-man_progname.patch |
ef8c2e9a | 17 | URL: http://www.libarchive.org/ |
e8285c16 JB |
18 | BuildRequires: acl-devel |
19 | BuildRequires: attr-devel | |
ac600a23 | 20 | BuildRequires: bzip2-devel |
e8285c16 | 21 | # for <ext2fs/ext2_fs.h> |
1f60048e | 22 | BuildRequires: e2fsprogs-devel |
b28cb0a8 | 23 | BuildRequires: libb2-devel |
d9046622 JB |
24 | BuildRequires: libxml2-devel >= 2 |
25 | BuildRequires: lz4-devel >= r131 | |
92d2b5ad | 26 | BuildRequires: lzo-devel >= 2 |
12667120 | 27 | BuildRequires: nettle-devel |
d9046622 | 28 | BuildRequires: pkgconfig |
3c25a433 | 29 | BuildRequires: richacl-devel |
00e5cded JB |
30 | BuildRequires: tar >= 1:1.22 |
31 | BuildRequires: xz | |
b28cb0a8 | 32 | BuildRequires: xz-devel >= 1:5.2 |
ac600a23 | 33 | BuildRequires: zlib-devel |
b28cb0a8 | 34 | BuildRequires: zstd-devel |
d9046622 | 35 | Requires: lz4-libs >= r131 |
b28cb0a8 | 36 | Requires: xz-libs >= 1:5.2 |
ac600a23 AG |
37 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
38 | ||
39 | %description | |
40 | Libarchive is a programming library that can create and read several | |
41 | different streaming archive formats, including most popular TAR | |
892cabbc ER |
42 | variants, several CPIO formats, and both BSD and GNU ar variants. It |
43 | can also write SHAR archives and read ISO9660 CDROM images and ZIP | |
44 | archives. | |
45 | ||
46 | See README for complete format support. | |
ac600a23 | 47 | |
36ad161a | 48 | %description -l pl.UTF-8 |
da147f22 JB |
49 | Libarchive to biblioteka potrafiąca tworzyć i odczytywać kilka różnych |
50 | formatów archiwów strumieniowych, w tym najbardziej popularne warianty | |
51 | archiwów TAR, kilka formatów CPIO oraz warianty BSD oraz GNU archiwów | |
52 | ar. Potrafi także zapisywać archiwa SHAR oraz odczytywać obrazy CDROM | |
53 | ISO9660 i archiwa ZIP. | |
54 | ||
55 | Pełny wykaz obsługiwanych formatów znajduje się w pliku README. | |
ac600a23 AG |
56 | |
57 | %package devel | |
58 | Summary: Header files for libarchive library | |
34f03146 | 59 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki libarchive |
ac600a23 AG |
60 | Group: Development/Libraries |
61 | Requires: %{name} = %{version}-%{release} | |
e8285c16 JB |
62 | Requires: acl-devel |
63 | Requires: attr-devel | |
64 | Requires: bzip2-devel | |
b28cb0a8 | 65 | Requires: libb2-devel |
92831ec2 | 66 | Requires: libxml2-devel |
d9046622 | 67 | Requires: lz4-devel >= r131 |
12667120 | 68 | Requires: nettle-devel |
b28cb0a8 JB |
69 | Requires: richacl-devel |
70 | Requires: xz-devel >= 1:5.2 | |
e8285c16 | 71 | Requires: zlib-devel |
b28cb0a8 | 72 | Requires: zstd-devel |
ac600a23 AG |
73 | |
74 | %description devel | |
75 | Header files for libarchive library. | |
76 | ||
36ad161a JR |
77 | %description devel -l pl.UTF-8 |
78 | Pliki nagłówkowe biblioteki libarchive. | |
ac600a23 AG |
79 | |
80 | %package static | |
81 | Summary: Static libarchive library | |
34f03146 | 82 | Summary(pl.UTF-8): Statyczna biblioteka libarchive |
ac600a23 AG |
83 | Group: Development/Libraries |
84 | Requires: %{name}-devel = %{version}-%{release} | |
85 | ||
86 | %description static | |
87 | Static libarchive library. | |
88 | ||
36ad161a | 89 | %description static -l pl.UTF-8 |
ac600a23 AG |
90 | Statyczna biblioteka libarchive. |
91 | ||
d9046622 JB |
92 | %package -n bsdcat |
93 | Summary: bsdcat - cat(1) implementation based on libarchive | |
94 | Summary(pl.UTF-8): bsdcat - implementacja programu cat(1) oparta na libarchive | |
95 | Group: Applications/Archiving | |
96 | Requires: %{name} = %{version}-%{release} | |
97 | ||
98 | %description -n bsdcat | |
99 | bsdcat - cat(1) implementation based on libarchive. | |
100 | ||
101 | %description -n bsdcat -l pl.UTF-8 | |
102 | bsdcat - implementacja programu cat(1), oparta na libarchive. | |
103 | ||
92831ec2 MB |
104 | %package -n bsdcpio |
105 | Summary: bsdcpio - cpio(1) implementation based on libarchive | |
106 | Summary(pl.UTF-8): bsdcpio - implementacja programu cpio(1) oparta na libarchive | |
107 | Group: Applications/Archiving | |
108 | Requires: %{name} = %{version}-%{release} | |
109 | ||
110 | %description -n bsdcpio | |
111 | bsdcpio - cpio(1) implementation based on libarchive. | |
112 | ||
113 | %description -n bsdcpio -l pl.UTF-8 | |
114 | bsdcpio - implementacja programu cpio(1), oparta na libarchive. | |
115 | ||
1f60048e | 116 | %package -n bsdtar |
117 | Summary: bsdtar - tar(1) implementation based on libarchive | |
34f03146 | 118 | Summary(pl.UTF-8): bsdtar - implementacja programu tar(1) oparta na libarchive |
1f60048e | 119 | Group: Applications/Archiving |
120 | Requires: %{name} = %{version}-%{release} | |
121 | ||
122 | %description -n bsdtar | |
123 | bsdtar - tar(1) implementation based on libarchive. | |
124 | ||
36ad161a | 125 | %description -n bsdtar -l pl.UTF-8 |
1f60048e | 126 | bsdtar - implementacja programu tar(1), oparta na libarchive. |
127 | ||
ac600a23 AG |
128 | %prep |
129 | %setup -q | |
1f60048e | 130 | %patch0 -p1 |
ac600a23 AG |
131 | |
132 | %build | |
e377f8a5 | 133 | CPPFLAGS="%{rpmcppflags} -I/usr/include/lz4" |
7458d87c | 134 | # disable openssl, nettle has all necessary functionality |
b74af457 | 135 | %configure \ |
92d2b5ad | 136 | --disable-silent-rules \ |
d9046622 | 137 | --enable-bsdcat=shared \ |
12667120 JB |
138 | --enable-bsdcpio=shared \ |
139 | --enable-bsdtar=shared \ | |
7458d87c JB |
140 | --enable-static%{!?with_static_libs:=no} \ |
141 | --with-lzo2 \ | |
142 | --without-openssl | |
50a596a2 | 143 | %{__make} |
ac600a23 AG |
144 | |
145 | %install | |
146 | rm -rf $RPM_BUILD_ROOT | |
147 | %{__make} install \ | |
148 | DESTDIR=$RPM_BUILD_ROOT | |
149 | ||
7458d87c JB |
150 | # obsoleted by pkg-config |
151 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/libarchive.la | |
152 | ||
ca4812a2 JB |
153 | %clean |
154 | rm -rf $RPM_BUILD_ROOT | |
155 | ||
ac600a23 AG |
156 | %post -p /sbin/ldconfig |
157 | %postun -p /sbin/ldconfig | |
158 | ||
159 | %files | |
160 | %defattr(644,root,root,755) | |
e377f8a5 | 161 | %doc NEWS COPYING |
ac600a23 | 162 | %attr(755,root,root) %{_libdir}/libarchive.so.*.*.* |
92d2b5ad | 163 | %attr(755,root,root) %ghost %{_libdir}/libarchive.so.13 |
ac600a23 AG |
164 | |
165 | %files devel | |
166 | %defattr(644,root,root,755) | |
167 | %attr(755,root,root) %{_libdir}/libarchive.so | |
c2f290c1 JB |
168 | %{_includedir}/archive*.h |
169 | %{_mandir}/man3/archive_*.3* | |
170 | %{_mandir}/man3/libarchive.3* | |
92d2b5ad | 171 | %{_mandir}/man3/libarchive_changes.3* |
c2f290c1 JB |
172 | %{_mandir}/man3/libarchive_internals.3* |
173 | %{_mandir}/man5/libarchive-formats.5* | |
174 | %{_mandir}/man5/cpio.5* | |
175 | %{_mandir}/man5/mtree.5* | |
176 | %{_mandir}/man5/tar.5* | |
92831ec2 | 177 | %{_pkgconfigdir}/libarchive.pc |
ac600a23 | 178 | |
b74af457 | 179 | %if %{with static_libs} |
ac600a23 AG |
180 | %files static |
181 | %defattr(644,root,root,755) | |
182 | %{_libdir}/libarchive.a | |
b74af457 | 183 | %endif |
1f60048e | 184 | |
d9046622 JB |
185 | %files -n bsdcat |
186 | %defattr(644,root,root,755) | |
187 | %attr(755,root,root) %{_bindir}/bsdcat | |
188 | %{_mandir}/man1/bsdcat.1* | |
189 | ||
92831ec2 MB |
190 | %files -n bsdcpio |
191 | %defattr(644,root,root,755) | |
192 | %attr(755,root,root) %{_bindir}/bsdcpio | |
193 | %{_mandir}/man1/bsdcpio.1* | |
194 | ||
1f60048e | 195 | %files -n bsdtar |
196 | %defattr(644,root,root,755) | |
197 | %attr(755,root,root) %{_bindir}/bsdtar | |
198 | %{_mandir}/man1/bsdtar.1* |