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