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