]>
Commit | Line | Data |
---|---|---|
a7e1e844 | 1 | # |
30276236 | 2 | # Conditional build: |
92c6255c | 3 | %bcond_with freetds # with FreeTDS (sybdb) DBD module (unfinished) |
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 | |
30276236 | 11 | # |
72a05a99 | 12 | Summary: A companion library to Apache Portable Runtime |
1cdce4f9 | 13 | Summary(pl.UTF-8): Biblioteka towarzysząca Apache Portable Runtime |
72a05a99 | 14 | Name: apr-util |
48e7a7b5 | 15 | Version: 1.3.2 |
92c6255c | 16 | Release: 1 |
72a05a99 | 17 | Epoch: 1 |
30276236 | 18 | License: Apache v2.0 |
72a05a99 | 19 | Group: Libraries |
4078c8d7 | 20 | Source0: http://www.apache.org/dist/apr/%{name}-%{version}.tar.bz2 |
48e7a7b5 | 21 | # Source0-md5: aa782fb9ced8b59c8e99419d8cdd1981 |
90687e98 | 22 | Patch0: %{name}-link.patch |
92c6255c | 23 | Patch1: %{name}-db47.patch |
72a05a99 | 24 | URL: http://apr.apache.org/ |
92c6255c | 25 | BuildRequires: apr-devel >= 1:1.3.0 |
77bbdc19 | 26 | BuildRequires: autoconf |
ec97abe4 | 27 | %if "%{pld_release}" == "ti" |
7b70f674 | 28 | BuildRequires: db-devel >= 4.5 |
29 | %else | |
92c6255c | 30 | BuildRequires: db-devel >= 4.7 |
7b70f674 | 31 | %endif |
77bbdc19 | 32 | BuildRequires: expat-devel |
92c6255c | 33 | %{?with_freetds:BuildRequires: freetds-devel} |
fed4b95d | 34 | BuildRequires: libtool |
e753ced3 | 35 | %{?with_mysql:BuildRequires: mysql-devel} |
315bdeba | 36 | %{?with_ldap:BuildRequires: openldap-devel >= 2.4.6} |
48e7a7b5 | 37 | %{?with_odbc:BuildRequires: unixODBC-devel} |
e753ced3 | 38 | %{?with_pgsql:BuildRequires: postgresql-devel} |
7b70f674 | 39 | BuildRequires: rpm >= 4.4.9-56 |
40238ac3 | 40 | %{?with_sqlite2:BuildRequires: sqlite-devel >= 2} |
4078c8d7 | 41 | %{?with_sqlite3:BuildRequires: sqlite3-devel >= 3} |
92c6255c | 42 | Requires: apr >= 1:1.3.0 |
72a05a99 AM |
43 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
44 | ||
45 | %define _includedir /usr/include/apr-util | |
46 | ||
47 | %description | |
48 | A companion library to Apache Portable Runtime. | |
49 | ||
61c4246a JR |
50 | %description -l pl.UTF-8 |
51 | Biblioteka towarzysząca dla biblioteki Apache Portable Runtime | |
52 | (przenośnej biblioteki uruchomieniowej). | |
77bbdc19 | 53 | |
92c6255c JB |
54 | %package dbd-freetds |
55 | Summary: DBD driver for FreeTDS (Sybase/MS SQL) | |
56 | Summary(pl.UTF-8): Sterownik DBD dla FreeTDS (Sybase/MS SQL) | |
57 | Group: Libraries | |
58 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
59 | ||
60 | %description dbd-freetds | |
61 | DBD driver for FreeTDS (Sybase/MS SQL). | |
62 | ||
63 | %description dbd-freetds -l pl.UTF-8 | |
64 | Sterownik DBD dla FreeTDS (Sybase/MS SQL). | |
65 | ||
40238ac3 ER |
66 | %package dbd-mysql |
67 | Summary: DBD driver for MySQL | |
1cdce4f9 | 68 | Summary(pl.UTF-8): Sterownik DBD dla MySQL-a |
a7e1e844 | 69 | License: GPL |
40238ac3 ER |
70 | Group: Libraries |
71 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
40238ac3 ER |
72 | |
73 | %description dbd-mysql | |
74 | DBD driver for MySQL. | |
75 | ||
61c4246a | 76 | %description dbd-mysql -l pl.UTF-8 |
a7e1e844 JB |
77 | Sterownik DBD dla MySQL-a. |
78 | ||
48e7a7b5 AG |
79 | %package dbd-odbc |
80 | Summary: DBD driver for ODBC | |
81 | Summary(pl.UTF-8): Sterownik DBD dla ODBC | |
82 | License: GPL | |
83 | Group: Libraries | |
84 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
85 | ||
86 | %description dbd-odbc | |
87 | DBD driver for ODBC. | |
88 | ||
89 | %description dbd-odbc -l pl.UTF-8 | |
90 | Sterownik DBD dla ODBC. | |
91 | ||
92c6255c JB |
92 | %package dbd-oracle |
93 | Summary: DBD driver for Oracle | |
94 | Summary(pl.UTF-8): Sterownik DBD dla Oracle'a | |
95 | Group: Libraries | |
96 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
97 | ||
98 | %description dbd-oracle | |
99 | DBD driver for Oracle. | |
100 | ||
101 | %description dbd-oracle -l pl.UTF-8 | |
102 | Sterownik DBD dla Oracle'a. | |
103 | ||
40238ac3 ER |
104 | %package dbd-pgsql |
105 | Summary: DBD driver for PostgreSQL | |
1cdce4f9 | 106 | Summary(pl.UTF-8): Sterownik DBD dla PostgreSQL-a |
40238ac3 ER |
107 | Group: Libraries |
108 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
109 | ||
110 | %description dbd-pgsql | |
111 | DBD driver for PostgreSQL. | |
112 | ||
61c4246a | 113 | %description dbd-pgsql -l pl.UTF-8 |
a7e1e844 JB |
114 | Sterownik DBD dla PostgreSQL-a. |
115 | ||
40238ac3 ER |
116 | %package dbd-sqlite2 |
117 | Summary: DBD driver for SQLite 2 | |
1cdce4f9 | 118 | Summary(pl.UTF-8): Sterownik DBD dla SQLite 2 |
40238ac3 ER |
119 | Group: Libraries |
120 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
121 | ||
122 | %description dbd-sqlite2 | |
a7e1e844 JB |
123 | DBD driver for SQLite 2. |
124 | ||
61c4246a | 125 | %description dbd-sqlite2 -l pl.UTF-8 |
a7e1e844 | 126 | Sterownik DBD dla SQLite 2. |
40238ac3 ER |
127 | |
128 | %package dbd-sqlite3 | |
129 | Summary: DBD driver for SQLite 3 | |
1cdce4f9 | 130 | Summary(pl.UTF-8): Sterownik DBD dla SQLite 3 |
40238ac3 ER |
131 | Group: Libraries |
132 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
133 | ||
134 | %description dbd-sqlite3 | |
a7e1e844 JB |
135 | DBD driver for SQLite 3. |
136 | ||
61c4246a | 137 | %description dbd-sqlite3 -l pl.UTF-8 |
a7e1e844 | 138 | Sterownik DBD dla SQLite 3. |
40238ac3 | 139 | |
92c6255c JB |
140 | %package ldap |
141 | Summary: APR LDAP driver | |
142 | Summary(pl.UTF-8): Sterownik APR dla LDAP | |
143 | Group: Libraries | |
144 | Requires: %{name} = %{epoch}:%{version}-%{release} | |
145 | ||
146 | %description ldap | |
147 | APR LDAP driver. | |
148 | ||
149 | %description ldap -l pl.UTF-8 | |
150 | Sterownik APR dla LDAP. | |
151 | ||
72a05a99 | 152 | %package devel |
77bbdc19 | 153 | Summary: Header files and development documentation for apr-util |
1cdce4f9 | 154 | Summary(pl.UTF-8): Pliki nagłówkowe i dokumentacja programisty do apr-util |
72a05a99 | 155 | Group: Development/Libraries |
77bbdc19 | 156 | Requires: %{name} = %{epoch}:%{version}-%{release} |
92c6255c | 157 | Requires: apr-devel >= 1:1.3.0 |
93be47f8 JB |
158 | Requires: db-devel |
159 | Requires: expat-devel | |
72a05a99 AM |
160 | |
161 | %description devel | |
77bbdc19 JB |
162 | Header files and development documentation for apr-util. |
163 | ||
61c4246a JR |
164 | %description devel -l pl.UTF-8 |
165 | Pliki nagłówkowe i dokumentacja programisty do apr-util. | |
72a05a99 AM |
166 | |
167 | %package static | |
168 | Summary: Static apr-util library | |
1cdce4f9 | 169 | Summary(pl.UTF-8): Statyczna biblioteka apr-util |
72a05a99 | 170 | Group: Development/Libraries |
77bbdc19 | 171 | Requires: %{name}-devel = %{epoch}:%{version}-%{release} |
72a05a99 AM |
172 | |
173 | %description static | |
174 | Static apr-util library. | |
175 | ||
61c4246a | 176 | %description static -l pl.UTF-8 |
77bbdc19 JB |
177 | Statyczna biblioteka apr-util. |
178 | ||
72a05a99 | 179 | %prep |
33c0565f | 180 | %setup -q |
90687e98 | 181 | %patch0 -p1 |
2a086b24 | 182 | %patch1 -p1 |
d77c67c3 ER |
183 | |
184 | rm -rf xml/expat | |
ce5f5d28 | 185 | |
ad0b28d7 AM |
186 | echo ' |
187 | <Layout PLD> | |
188 | prefix: %{_prefix} | |
189 | exec_prefix: %{_exec_prefix} | |
190 | bindir: %{_bindir} | |
191 | sbindir: %{_sbindir} | |
192 | libdir: %{_libdir} | |
193 | libexecdir: %{_libdir}/apr | |
194 | mandir: %{_mandir} | |
195 | sysconfdir: %{_sysconfdir} | |
196 | datadir: %{_datadir} | |
197 | installbuilddir: %{_datadir}/build | |
198 | includedir: %{_includedir} | |
199 | localstatedir: %{_localstatedir} | |
200 | runtimedir: %{_localstatedir}/run | |
2c9c8118 | 201 | libsuffix: -${APRUTIL_MAJOR_VERSION} |
ad0b28d7 AM |
202 | </Layout> |
203 | ' > config.layout | |
204 | ||
72a05a99 | 205 | %build |
d94db474 AM |
206 | ./buildconf \ |
207 | --with-apr=%{_datadir}/apr | |
33c0565f | 208 | |
72a05a99 | 209 | %configure \ |
ad0b28d7 | 210 | --enable-layout=PLD \ |
33c0565f | 211 | --with-apr=%{_bindir}/apr-1-config \ |
7e89f5b8 | 212 | --with-berkeley-db=%{_prefix} \ |
ec97abe4 | 213 | %if "%{pld_release}" == "ti" |
7b70f674 | 214 | --with-dbm=db45 \ |
215 | %else | |
92c6255c JB |
216 | --with-dbm=db47 \ |
217 | %endif | |
218 | --with-iconv=%{_prefix} \ | |
219 | %if %{with ldap} | |
220 | --with-ldap \ | |
221 | --with-ldap-include=%{_prefix}/include \ | |
222 | --with-ldap-lib=%{_libdir} \ | |
7b70f674 | 223 | %endif |
92c6255c | 224 | %{!?with_freetds:--without-freetds} \ |
dbda5121 | 225 | %{?with_mysql:--with-mysql=%{_prefix}} \ |
48e7a7b5 | 226 | %{!?with_odbc:--without-odbc} \ |
92c6255c | 227 | %{?with_oracle:--with-oracle} \ |
e753ced3 | 228 | %{!?with_pgsql:--without-pgsql} \ |
40238ac3 | 229 | %{!?with_sqlite2:--without-sqlite2} \ |
c31ea3e4 | 230 | %{!?with_sqlite3:--without-sqlite3} |
33c0565f | 231 | |
d77c67c3 ER |
232 | %{__make} \ |
233 | CC="%{__cc}" | |
234 | ||
72a05a99 AM |
235 | %install |
236 | rm -rf $RPM_BUILD_ROOT | |
237 | ||
238 | %{__make} install \ | |
239 | DESTDIR=$RPM_BUILD_ROOT | |
48e7a7b5 | 240 | |
92c6255c | 241 | rm $RPM_BUILD_ROOT%{_libdir}/apr-util-1/*.{la,a} |
72a05a99 | 242 | |
72a05a99 AM |
243 | %clean |
244 | rm -rf $RPM_BUILD_ROOT | |
245 | ||
77bbdc19 JB |
246 | %post -p /sbin/ldconfig |
247 | %postun -p /sbin/ldconfig | |
248 | ||
72a05a99 AM |
249 | %files |
250 | %defattr(644,root,root,755) | |
92c6255c | 251 | %doc CHANGES NOTICE README |
27418c3e JB |
252 | %attr(755,root,root) %{_libdir}/libaprutil-1.so.*.*.* |
253 | %attr(755,root,root) %ghost %{_libdir}/libaprutil-1.so.0 | |
92c6255c JB |
254 | %dir %{_libdir}/apr-util-1 |
255 | ||
256 | %if %{with freetds} | |
257 | %files dbd-freetds | |
258 | %defattr(644,root,root,755) | |
259 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_freetds-1.so | |
260 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_freetds.so | |
261 | %endif | |
40238ac3 | 262 | |
40238ac3 ER |
263 | %if %{with mysql} |
264 | %files dbd-mysql | |
265 | %defattr(644,root,root,755) | |
27418c3e | 266 | %doc README.MySQL |
92c6255c JB |
267 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_mysql-1.so |
268 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_mysql.so | |
269 | %endif | |
270 | ||
48e7a7b5 AG |
271 | %if %{with_odbc} |
272 | %files dbd-odbc | |
273 | %defattr(644,root,root,755) | |
274 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_odbc-1.so | |
275 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_odbc.so | |
276 | %endif | |
277 | ||
92c6255c JB |
278 | %if %{with oracle} |
279 | %files dbd-oracle | |
280 | %defattr(644,root,root,755) | |
281 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_oracle-1.so | |
282 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_oracle.so | |
40238ac3 ER |
283 | %endif |
284 | ||
285 | %if %{with pgsql} | |
286 | %files dbd-pgsql | |
287 | %defattr(644,root,root,755) | |
92c6255c JB |
288 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_pgsql-1.so |
289 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_pgsql.so | |
40238ac3 ER |
290 | %endif |
291 | ||
292 | %if %{with sqlite2} | |
293 | %files dbd-sqlite2 | |
294 | %defattr(644,root,root,755) | |
92c6255c JB |
295 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_sqlite2-1.so |
296 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_sqlite2.so | |
40238ac3 ER |
297 | %endif |
298 | ||
299 | %if %{with sqlite3} | |
300 | %files dbd-sqlite3 | |
301 | %defattr(644,root,root,755) | |
92c6255c JB |
302 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_sqlite3-1.so |
303 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_dbd_sqlite3.so | |
40238ac3 | 304 | %endif |
92c6255c JB |
305 | |
306 | %if %{with ldap} | |
307 | %files ldap | |
308 | %defattr(644,root,root,755) | |
309 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_ldap-1.so | |
310 | %attr(755,root,root) %{_libdir}/apr-util-1/apr_ldap.so | |
40238ac3 | 311 | %endif |
72a05a99 AM |
312 | |
313 | %files devel | |
314 | %defattr(644,root,root,755) | |
27418c3e JB |
315 | %attr(755,root,root) %{_bindir}/apu-1-config |
316 | %attr(755,root,root) %{_libdir}/libaprutil-1.so | |
317 | %{_libdir}/libaprutil-1.la | |
72a05a99 AM |
318 | %{_libdir}/aprutil.exp |
319 | %{_includedir} | |
33c0565f | 320 | %{_pkgconfigdir}/apr-util-1.pc |
72a05a99 AM |
321 | |
322 | %files static | |
323 | %defattr(644,root,root,755) | |
27418c3e | 324 | %{_libdir}/libaprutil-1.a |