]>
Commit | Line | Data |
---|---|---|
a7e1e844 | 1 | # |
30276236 | 2 | # Conditional build: |
bf1d5cdb | 3 | %bcond_without freetds # without FreeTDS (sybdb) DBD module |
48e7a7b5 AG |
4 | %bcond_without mysql # without MySQL DBD module |
5 | %bcond_without odbc # without ODBC DBD module | |
92c6255c JB |
6 | %bcond_with oracle # with Oracle DBD module (BR: proprietary libs) |
7 | %bcond_without pgsql # without PostgreSQL DBD module | |
8 | %bcond_with sqlite2 # with SQLite 2.x DBD module | |
9 | %bcond_without sqlite3 # without SQLite3 DBD module | |
10 | %bcond_without ldap # without LDAP module | |
b95223bc JB |
11 | %bcond_without nss # without NSS crypto module |
12 | %bcond_without openssl # without OpenSSL crypto module | |
13 | %bcond_without tests # don't perform "make check" | |
f53e9eb5 | 14 | |
b1802398 JB |
15 | # define dbver db50 |
16 | %if 0%{!?dbver:1} | |
f53e9eb5 | 17 | %if "%{pld_release}" == "th" |
4aaa3621 | 18 | %define dbver db53 |
f53e9eb5 ER |
19 | %endif |
20 | %if "%{pld_release}" == "ti" | |
21 | %define dbver db45 | |
22 | %endif | |
23 | %if "%{pld_release}" == "ac" | |
24 | %define dbver db42 | |
25 | %endif | |
b1802398 | 26 | %endif |
f53e9eb5 | 27 | |
fd6c259c ER |
28 | # files list broken, feel free to really fix |
29 | %ifarch alpha | |
30 | %undefine with_mysql | |
31 | %endif | |
32 | ||
72a05a99 | 33 | Summary: A companion library to Apache Portable Runtime |
1cdce4f9 | 34 | Summary(pl.UTF-8): Biblioteka towarzysząca Apache Portable Runtime |
72a05a99 | 35 | Name: apr-util |
bf1d5cdb JB |
36 | Version: 1.5.1 |
37 | Release: 1 | |
72a05a99 | 38 | Epoch: 1 |
30276236 | 39 | License: Apache v2.0 |
72a05a99 | 40 | Group: Libraries |
4078c8d7 | 41 | Source0: http://www.apache.org/dist/apr/%{name}-%{version}.tar.bz2 |
bf1d5cdb | 42 | # Source0-md5: 9c1db8606e520f201c451ec9a0b095f6 |
90687e98 | 43 | Patch0: %{name}-link.patch |
155bafb5 | 44 | Patch1: %{name}-config-noldap.patch |
16929f4d | 45 | Patch2: %{name}-libtool.patch |
d12a4eaf | 46 | Patch3: %{name}-flags.patch |
72a05a99 | 47 | URL: http://apr.apache.org/ |
92c6255c | 48 | BuildRequires: apr-devel >= 1:1.3.0 |
f7e14f7d | 49 | BuildRequires: autoconf >= 2.59 |
16929f4d | 50 | %if "%{pld_release}" == "th" |
92c6255c | 51 | BuildRequires: db-devel >= 4.7 |
16929f4d | 52 | %endif |
f53e9eb5 ER |
53 | %if "%{pld_release}" == "ti" |
54 | BuildRequires: db-devel >= 4.5 | |
55 | %endif | |
56 | %if "%{pld_release}" == "ac" | |
57 | BuildRequires: db-devel >= 4.2 | |
58 | BuildConflicts: db4.5-devel | |
7b70f674 | 59 | %endif |
77bbdc19 | 60 | BuildRequires: expat-devel |
92c6255c | 61 | %{?with_freetds:BuildRequires: freetds-devel} |
fed4b95d | 62 | BuildRequires: libtool |
e753ced3 | 63 | %{?with_mysql:BuildRequires: mysql-devel} |
b95223bc | 64 | %{?with_nss:BuildRequires: nss-devel} |
16929f4d | 65 | %{?with_ldap:BuildRequires: openldap-devel >= 2.3.0} |
b95223bc | 66 | %{?with_openssl:BuildRequires: openssl-devel} |
e753ced3 | 67 | %{?with_pgsql:BuildRequires: postgresql-devel} |
7b70f674 | 68 | BuildRequires: rpm >= 4.4.9-56 |
40238ac3 | 69 | %{?with_sqlite2:BuildRequires: sqlite-devel >= 2} |
4078c8d7 | 70 | %{?with_sqlite3:BuildRequires: sqlite3-devel >= 3} |
c10367e4 | 71 | %{?with_odbc:BuildRequires: unixODBC-devel} |
ab046b66 | 72 | BuildRequires: which |
92c6255c | 73 | Requires: apr >= 1:1.3.0 |
72a05a99 AM |
74 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
75 | ||
76 | %define _includedir /usr/include/apr-util | |
77 | ||
78 | %description | |
79 | A companion library to Apache Portable Runtime. | |
80 | ||
61c4246a JR |
81 | %description -l pl.UTF-8 |
82 | Biblioteka towarzysząca dla biblioteki Apache Portable Runtime | |
83 | (przenośnej biblioteki uruchomieniowej). | |
77bbdc19 | 84 | |
b95223bc JB |
85 | %package crypto-nss |
86 | Summary: APR cryptographic module using Mozilla NSS library | |
87 | Summary(pl.UTF-8): Moduł kryptograficzny APR wykorzystujący bibliotekę Mozilla NSS | |
c10367e4 AM |
88 | Group: Libraries |
89 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
90 | ||
b95223bc JB |
91 | %description crypto-nss |
92 | APR cryptographic module using Mozilla NSS library. | |
c10367e4 | 93 | |
b95223bc JB |
94 | %description crypto-nss -l pl.UTF-8 |
95 | Moduł kryptograficzny APR wykorzystujący bibliotekę Mozilla NSS. | |
96 | ||
97 | %package crypto-openssl | |
98 | Summary: APR cryptographic module using OpenSSL library | |
99 | Summary(pl.UTF-8): Moduł kryptograficzny APR wykorzystujący bibliotekę OpenSSL | |
100 | Group: Libraries | |
101 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
102 | ||
103 | %description crypto-openssl | |
104 | APR cryptographic module using OpenSSL library. | |
105 | ||
106 | %description crypto-openssl -l pl.UTF-8 | |
107 | Moduł kryptograficzny APR wykorzystujący bibliotekę OpenSSL. | |
c10367e4 | 108 | |
92c6255c JB |
109 | %package dbd-freetds |
110 | Summary: DBD driver for FreeTDS (Sybase/MS SQL) | |
111 | Summary(pl.UTF-8): Sterownik DBD dla FreeTDS (Sybase/MS SQL) | |
112 | Group: Libraries | |
113 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
114 | ||
115 | %description dbd-freetds | |
116 | DBD driver for FreeTDS (Sybase/MS SQL). | |
117 | ||
118 | %description dbd-freetds -l pl.UTF-8 | |
119 | Sterownik DBD dla FreeTDS (Sybase/MS SQL). | |
120 | ||
40238ac3 ER |
121 | %package dbd-mysql |
122 | Summary: DBD driver for MySQL | |
1cdce4f9 | 123 | Summary(pl.UTF-8): Sterownik DBD dla MySQL-a |
a7e1e844 | 124 | License: GPL |
40238ac3 ER |
125 | Group: Libraries |
126 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
40238ac3 ER |
127 | |
128 | %description dbd-mysql | |
129 | DBD driver for MySQL. | |
130 | ||
61c4246a | 131 | %description dbd-mysql -l pl.UTF-8 |
a7e1e844 JB |
132 | Sterownik DBD dla MySQL-a. |
133 | ||
48e7a7b5 AG |
134 | %package dbd-odbc |
135 | Summary: DBD driver for ODBC | |
136 | Summary(pl.UTF-8): Sterownik DBD dla ODBC | |
137 | License: GPL | |
138 | Group: Libraries | |
139 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
140 | ||
141 | %description dbd-odbc | |
142 | DBD driver for ODBC. | |
143 | ||
144 | %description dbd-odbc -l pl.UTF-8 | |
145 | Sterownik DBD dla ODBC. | |
146 | ||
92c6255c JB |
147 | %package dbd-oracle |
148 | Summary: DBD driver for Oracle | |
149 | Summary(pl.UTF-8): Sterownik DBD dla Oracle'a | |
150 | Group: Libraries | |
151 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
152 | ||
153 | %description dbd-oracle | |
154 | DBD driver for Oracle. | |
155 | ||
156 | %description dbd-oracle -l pl.UTF-8 | |
157 | Sterownik DBD dla Oracle'a. | |
158 | ||
40238ac3 ER |
159 | %package dbd-pgsql |
160 | Summary: DBD driver for PostgreSQL | |
1cdce4f9 | 161 | Summary(pl.UTF-8): Sterownik DBD dla PostgreSQL-a |
40238ac3 ER |
162 | Group: Libraries |
163 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
164 | ||
165 | %description dbd-pgsql | |
166 | DBD driver for PostgreSQL. | |
167 | ||
61c4246a | 168 | %description dbd-pgsql -l pl.UTF-8 |
a7e1e844 JB |
169 | Sterownik DBD dla PostgreSQL-a. |
170 | ||
40238ac3 ER |
171 | %package dbd-sqlite2 |
172 | Summary: DBD driver for SQLite 2 | |
1cdce4f9 | 173 | Summary(pl.UTF-8): Sterownik DBD dla SQLite 2 |
40238ac3 ER |
174 | Group: Libraries |
175 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
176 | ||
177 | %description dbd-sqlite2 | |
a7e1e844 JB |
178 | DBD driver for SQLite 2. |
179 | ||
61c4246a | 180 | %description dbd-sqlite2 -l pl.UTF-8 |
a7e1e844 | 181 | Sterownik DBD dla SQLite 2. |
40238ac3 ER |
182 | |
183 | %package dbd-sqlite3 | |
184 | Summary: DBD driver for SQLite 3 | |
1cdce4f9 | 185 | Summary(pl.UTF-8): Sterownik DBD dla SQLite 3 |
40238ac3 ER |
186 | Group: Libraries |
187 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
188 | ||
189 | %description dbd-sqlite3 | |
a7e1e844 JB |
190 | DBD driver for SQLite 3. |
191 | ||
61c4246a | 192 | %description dbd-sqlite3 -l pl.UTF-8 |
a7e1e844 | 193 | Sterownik DBD dla SQLite 3. |
40238ac3 | 194 | |
b95223bc JB |
195 | %package dbm-db |
196 | Summary: DBM driver for DB | |
197 | Summary(pl.UTF-8): Sterownik DBM dla DB | |
198 | Group: Libraries | |
199 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
200 | ||
201 | %description dbm-db | |
202 | DBM driver for DB. | |
203 | ||
204 | %description dbm-db -l pl.UTF-8 | |
205 | Sterownik DBM dla DB. | |
206 | ||
92c6255c JB |
207 | %package ldap |
208 | Summary: APR LDAP driver | |
209 | Summary(pl.UTF-8): Sterownik APR dla LDAP | |
210 | Group: Libraries | |
211 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
212 | ||
213 | %description ldap | |
214 | APR LDAP driver. | |
215 | ||
216 | %description ldap -l pl.UTF-8 | |
217 | Sterownik APR dla LDAP. | |
218 | ||
72a05a99 | 219 | %package devel |
77bbdc19 | 220 | Summary: Header files and development documentation for apr-util |
1cdce4f9 | 221 | Summary(pl.UTF-8): Pliki nagłówkowe i dokumentacja programisty do apr-util |
72a05a99 | 222 | Group: Development/Libraries |
77bbdc19 | 223 | Requires: %{name} = %{epoch}:%{version}-%{release} |
92c6255c | 224 | Requires: apr-devel >= 1:1.3.0 |
93be47f8 | 225 | Requires: expat-devel |
72a05a99 AM |
226 | |
227 | %description devel | |
77bbdc19 JB |
228 | Header files and development documentation for apr-util. |
229 | ||
61c4246a JR |
230 | %description devel -l pl.UTF-8 |
231 | Pliki nagłówkowe i dokumentacja programisty do apr-util. | |
72a05a99 AM |
232 | |
233 | %package static | |
234 | Summary: Static apr-util library | |
1cdce4f9 | 235 | Summary(pl.UTF-8): Statyczna biblioteka apr-util |
72a05a99 | 236 | Group: Development/Libraries |
77bbdc19 | 237 | Requires: %{name}-devel = %{epoch}:%{version}-%{release} |
72a05a99 AM |
238 | |
239 | %description static | |
240 | Static apr-util library. | |
241 | ||
61c4246a | 242 | %description static -l pl.UTF-8 |
77bbdc19 JB |
243 | Statyczna biblioteka apr-util. |
244 | ||
72a05a99 | 245 | %prep |
33c0565f | 246 | %setup -q |
90687e98 | 247 | %patch0 -p1 |
2a086b24 | 248 | %patch1 -p1 |
16929f4d | 249 | %patch2 -p1 |
b1802398 | 250 | %patch3 -p1 |
d77c67c3 | 251 | |
b95223bc | 252 | # ensure system expat is used |
f7e14f7d | 253 | %{__rm} -r xml/expat |
ce5f5d28 | 254 | |
ad0b28d7 AM |
255 | echo ' |
256 | <Layout PLD> | |
257 | prefix: %{_prefix} | |
258 | exec_prefix: %{_exec_prefix} | |
259 | bindir: %{_bindir} | |
260 | sbindir: %{_sbindir} | |
261 | libdir: %{_libdir} | |
262 | libexecdir: %{_libdir}/apr | |
263 | mandir: %{_mandir} | |
264 | sysconfdir: %{_sysconfdir} | |
265 | datadir: %{_datadir} | |
266 | installbuilddir: %{_datadir}/build | |
267 | includedir: %{_includedir} | |
268 | localstatedir: %{_localstatedir} | |
269 | runtimedir: %{_localstatedir}/run | |
2c9c8118 | 270 | libsuffix: -${APRUTIL_MAJOR_VERSION} |
ad0b28d7 AM |
271 | </Layout> |
272 | ' > config.layout | |
273 | ||
72a05a99 | 274 | %build |
d94db474 AM |
275 | ./buildconf \ |
276 | --with-apr=%{_datadir}/apr | |
33c0565f | 277 | |
72a05a99 | 278 | %configure \ |
ad0b28d7 | 279 | --enable-layout=PLD \ |
33c0565f | 280 | --with-apr=%{_bindir}/apr-1-config \ |
7e89f5b8 | 281 | --with-berkeley-db=%{_prefix} \ |
b95223bc | 282 | --with-crypto \ |
b1802398 | 283 | --with-dbm=%{dbver} \ |
92c6255c JB |
284 | --with-iconv=%{_prefix} \ |
285 | %if %{with ldap} | |
286 | --with-ldap \ | |
287 | --with-ldap-include=%{_prefix}/include \ | |
288 | --with-ldap-lib=%{_libdir} \ | |
7b70f674 | 289 | %endif |
b95223bc JB |
290 | %{?with_nss:--with-nss} \ |
291 | %{?with_openssl:--with-openssl} \ | |
92c6255c | 292 | %{!?with_freetds:--without-freetds} \ |
dbda5121 | 293 | %{?with_mysql:--with-mysql=%{_prefix}} \ |
48e7a7b5 | 294 | %{!?with_odbc:--without-odbc} \ |
92c6255c | 295 | %{?with_oracle:--with-oracle} \ |
e753ced3 | 296 | %{!?with_pgsql:--without-pgsql} \ |
40238ac3 | 297 | %{!?with_sqlite2:--without-sqlite2} \ |
c31ea3e4 | 298 | %{!?with_sqlite3:--without-sqlite3} |
33c0565f | 299 | |
d77c67c3 ER |
300 | %{__make} \ |
301 | CC="%{__cc}" | |
302 | ||
1f395ae1 AM |
303 | %{?with_tests:%{__make} -j1 check} |
304 | ||
72a05a99 AM |
305 | %install |
306 | rm -rf $RPM_BUILD_ROOT | |
307 | ||
308 | %{__make} install \ | |
309 | DESTDIR=$RPM_BUILD_ROOT | |
48e7a7b5 | 310 | |
f7e14f7d | 311 | %{__rm} $RPM_BUILD_ROOT%{_libdir}/apr-util-1/*.{la,a} |
72a05a99 | 312 | |
72a05a99 AM |
313 | %clean |
314 | rm -rf $RPM_BUILD_ROOT | |
315 | ||
77bbdc19 JB |
316 | %post -p /sbin/ldconfig |
317 | %postun -p /sbin/ldconfig | |
318 | ||
72a05a99 AM |
319 | %files |
320 | %defattr(644,root,root,755) | |
92c6255c | 321 | %doc CHANGES NOTICE README |
27418c3e JB |
322 | %attr(755,root,root) %{_libdir}/libaprutil-1.so.*.*.* |
323 | %attr(755,root,root) %ghost %{_libdir}/libaprutil-1.so.0 | |
92c6255c JB |
324 | %dir %{_libdir}/apr-util-1 |
325 | ||
b95223bc JB |
326 | %if %{with nss} |
327 | %files crypto-nss | |
c10367e4 | 328 | %defattr(644,root,root,755) |
b95223bc JB |
329 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_crypto_nss-1.so |
330 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_crypto_nss.so | |
331 | %endif | |
332 | ||
333 | %if %{with openssl} | |
334 | %files crypto-openssl | |
335 | %defattr(644,root,root,755) | |
336 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_crypto_openssl-1.so | |
337 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_crypto_openssl.so | |
338 | %endif | |
c10367e4 | 339 | |
92c6255c JB |
340 | %if %{with freetds} |
341 | %files dbd-freetds | |
342 | %defattr(644,root,root,755) | |
343 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_freetds-1.so | |
344 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_freetds.so | |
345 | %endif | |
40238ac3 | 346 | |
40238ac3 ER |
347 | %if %{with mysql} |
348 | %files dbd-mysql | |
349 | %defattr(644,root,root,755) | |
92c6255c JB |
350 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_mysql-1.so |
351 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_mysql.so | |
352 | %endif | |
353 | ||
58900fcc | 354 | %if %{with odbc} |
48e7a7b5 AG |
355 | %files dbd-odbc |
356 | %defattr(644,root,root,755) | |
357 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_odbc-1.so | |
358 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_odbc.so | |
359 | %endif | |
360 | ||
92c6255c JB |
361 | %if %{with oracle} |
362 | %files dbd-oracle | |
363 | %defattr(644,root,root,755) | |
364 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_oracle-1.so | |
365 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_oracle.so | |
40238ac3 ER |
366 | %endif |
367 | ||
368 | %if %{with pgsql} | |
369 | %files dbd-pgsql | |
370 | %defattr(644,root,root,755) | |
92c6255c JB |
371 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_pgsql-1.so |
372 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_pgsql.so | |
40238ac3 ER |
373 | %endif |
374 | ||
375 | %if %{with sqlite2} | |
376 | %files dbd-sqlite2 | |
377 | %defattr(644,root,root,755) | |
92c6255c JB |
378 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_sqlite2-1.so |
379 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_sqlite2.so | |
40238ac3 ER |
380 | %endif |
381 | ||
382 | %if %{with sqlite3} | |
383 | %files dbd-sqlite3 | |
384 | %defattr(644,root,root,755) | |
92c6255c JB |
385 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_sqlite3-1.so |
386 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_sqlite3.so | |
40238ac3 | 387 | %endif |
92c6255c | 388 | |
b95223bc JB |
389 | %files dbm-db |
390 | %defattr(644,root,root,755) | |
391 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbm_db-1.so | |
392 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbm_db.so | |
393 | ||
92c6255c JB |
394 | %if %{with ldap} |
395 | %files ldap | |
396 | %defattr(644,root,root,755) | |
397 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_ldap-1.so | |
398 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_ldap.so | |
40238ac3 | 399 | %endif |
72a05a99 AM |
400 | |
401 | %files devel | |
402 | %defattr(644,root,root,755) | |
27418c3e JB |
403 | %attr(755,root,root) %{_bindir}/apu-1-config |
404 | %attr(755,root,root) %{_libdir}/libaprutil-1.so | |
405 | %{_libdir}/libaprutil-1.la | |
72a05a99 AM |
406 | %{_libdir}/aprutil.exp |
407 | %{_includedir} | |
33c0565f | 408 | %{_pkgconfigdir}/apr-util-1.pc |
72a05a99 AM |
409 | |
410 | %files static | |
411 | %defattr(644,root,root,755) | |
27418c3e | 412 | %{_libdir}/libaprutil-1.a |