]>
Commit | Line | Data |
---|---|---|
e42fa043 AM |
1 | # |
2 | # Conditional build: | |
31397b7d | 3 | %bcond_without apidocs # do not build and package API docs |
ee5514d7 | 4 | %bcond_without java # don't build Java bindings |
e42fa043 | 5 | %bcond_without tcl # don't build Tcl bindings |
e42fa043 | 6 | %bcond_without static_libs # don't build static libraries |
f1ee6134 | 7 | %bcond_with default_db # use this db as default system db [Th uses DB 5.3] |
d3c3fe80 ER |
8 | |
9 | %define libver 4.7 | |
ee5514d7 | 10 | %define ver %{libver}.25 |
9f42e124 | 11 | %define patchlevel 4 |
0db17e6a | 12 | %{?with_java:%include /usr/lib/rpm/macros.java} |
e42fa043 AM |
13 | Summary: Berkeley DB database library for C |
14 | Summary(pl.UTF-8): Biblioteka C do obsługi baz Berkeley DB | |
8cf606eb | 15 | Name: db4.7 |
d3c3fe80 | 16 | Version: %{ver}.%{patchlevel} |
9c807b03 | 17 | Release: 10 |
d685cba6 | 18 | License: GPL-like (see LICENSE) |
e42fa043 | 19 | Group: Libraries |
ee5514d7 | 20 | #Source0Download: http://www.oracle.com/technetwork/database/berkeleydb/downloads/index-082944.html |
d3c3fe80 | 21 | Source0: http://download.oracle.com/berkeley-db/db-%{ver}.tar.gz |
8cf606eb | 22 | # Source0-md5: ec2b87e833779681a0c3a814aa71359e |
ee5514d7 | 23 | %patchset_source -f http://download.oracle.com/berkeley-db/patches/db/%{ver}/patch.%{ver}.%g 1 %{patchlevel} |
52f71c64 | 24 | Patch0: %{name}-format-security.patch |
ee5514d7 | 25 | URL: http://www.oracle.com/technetwork/database/berkeleydb/downloads/index.html |
e42fa043 AM |
26 | BuildRequires: automake |
27 | BuildRequires: ed | |
be6de178 | 28 | %if %{with java} |
c023886b | 29 | BuildRequires: jdk |
be6de178 | 30 | BuildRequires: rpm-javaprov |
31 | %endif | |
e42fa043 | 32 | BuildRequires: libstdc++-devel |
d3c3fe80 | 33 | BuildRequires: rpmbuild(macros) >= 1.426 |
e42fa043 AM |
34 | BuildRequires: sed >= 4.0 |
35 | %{?with_tcl:BuildRequires: tcl-devel >= 8.4.0} | |
2a340a9d | 36 | Requires: uname(release) >= 2.6.0 |
554ba8b9 | 37 | %if %{with default_db} |
7c49495e | 38 | Provides: db = %{libver} |
0db17e6a | 39 | Provides: db = %{version}-%{release} |
e42fa043 | 40 | Obsoletes: db4 |
554ba8b9 | 41 | %endif |
e42fa043 AM |
42 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) |
43 | ||
554ba8b9 JB |
44 | %if %{without default_db} |
45 | %define _includedir %{_prefix}/include/db%{libver} | |
46 | %endif | |
47 | ||
e42fa043 AM |
48 | %description |
49 | The Berkeley Database (Berkeley DB) is a programmatic toolkit that | |
50 | provides embedded database support for both traditional and | |
51 | client/server applications. Berkeley DB is used by many applications, | |
52 | including Python and Perl, so this should be installed on all systems. | |
53 | ||
54 | %description -l pl.UTF-8 | |
55 | Berkeley Database (Berkeley DB) to zestaw narzędzi programistycznych | |
56 | zapewniających obsługę baz danych w aplikacjach tradycyjnych jak i | |
57 | klient-serwer. Berkeley db jest używana w wielu aplikacjach, w tym w | |
58 | Pythonie i Perlu. | |
59 | ||
60 | %package devel | |
61 | Summary: Header files for Berkeley database library | |
62 | Summary(pl.UTF-8): Pliki nagłówkowe do biblioteki Berkeley Database | |
63 | Group: Development/Libraries | |
0db17e6a | 64 | Requires: %{name} = %{version}-%{release} |
554ba8b9 | 65 | %if %{with default_db} |
e42fa043 | 66 | Provides: db-devel = %{version}-%{release} |
25836e73 | 67 | Obsoletes: db-devel |
e42fa043 AM |
68 | Obsoletes: db3-devel |
69 | Obsoletes: db4-devel | |
554ba8b9 | 70 | %endif |
e42fa043 AM |
71 | |
72 | %description devel | |
73 | The Berkeley Database (Berkeley DB) is a programmatic toolkit that | |
74 | provides embedded database support for both traditional and | |
75 | client/server applications. Berkeley DB includes B+tree, Extended | |
76 | Linear Hashing, Fixed and Variable-length record access methods, | |
77 | transactions, locking, logging, shared memory caching and database | |
78 | recovery. DB supports C, C++, Java and Perl APIs. | |
79 | ||
80 | This package contains the header files, libraries, and documentation | |
81 | for building programs which use Berkeley DB. | |
82 | ||
83 | %description devel -l pl.UTF-8 | |
84 | Berkeley Database (Berkeley DB) to zestaw narzędzi programistycznych | |
85 | zapewniających obsługę baz danych w aplikacjach tradycyjnych jak i | |
86 | klient-serwer. Berkeley DB obsługuje dostęp do bazy przez B-drzewa i | |
87 | funkcje mieszające ze stałą lub zmienną wielkością rekordu, | |
88 | transakcje, kroniki, pamięć dzieloną i odtwarzanie baz. Ma wsparcie | |
89 | dla C, C++, Javy i Perla. | |
90 | ||
91 | Ten pakiet zawiera pliki nagłówkowe i dokumentację do budowania | |
92 | programów używających Berkeley DB. | |
93 | ||
94 | %package static | |
95 | Summary: Static libraries for Berkeley database library | |
96 | Summary(pl.UTF-8): Statyczne biblioteki Berkeley Database | |
97 | Group: Development/Libraries | |
0db17e6a | 98 | Requires: %{name}-devel = %{version}-%{release} |
554ba8b9 | 99 | %if %{with default_db} |
e42fa043 | 100 | Provides: db-static = %{version}-%{release} |
25836e73 | 101 | Obsoletes: db-static |
e42fa043 AM |
102 | Obsoletes: db3-static |
103 | Obsoletes: db4-static | |
554ba8b9 | 104 | %endif |
e42fa043 AM |
105 | |
106 | %description static | |
107 | The Berkeley Database (Berkeley DB) is a programmatic toolkit that | |
108 | provides embedded database support for both traditional and | |
109 | client/server applications. Berkeley DB includes B+tree, Extended | |
110 | Linear Hashing, Fixed and Variable-length record access methods, | |
111 | transactions, locking, logging, shared memory caching and database | |
112 | recovery. DB supports C, C++, Java and Perl APIs. | |
113 | ||
114 | This package contains the static libraries for building programs which | |
115 | use Berkeley DB. | |
116 | ||
117 | %description static -l pl.UTF-8 | |
118 | Berkeley Database (Berkeley DB) to zestaw narzędzi programistycznych | |
119 | zapewniających obsługę baz danych w aplikacjach tradycyjnych jak i | |
120 | klient-serwer. Berkeley DB obsługuje dostęp do bazy przez B-drzewa i | |
121 | funkcje mieszające ze stałą lub zmienną wielkością rekordu, | |
122 | transakcje, kroniki, pamięć dzieloną i odtwarzanie baz. Ma wsparcie | |
123 | dla C, C++, Javy i Perla. | |
124 | ||
125 | Ten pakiet zawiera statyczne biblioteki do budowania programów | |
126 | używających Berkeley DB. | |
127 | ||
31397b7d ER |
128 | %package apidocs |
129 | Summary: Berkeley database library API documentation | |
ee5514d7 | 130 | Summary(pl.UTF-8): Dokumentacja API biblioteki baz danych Berkeley |
31397b7d | 131 | Group: Documentation |
ceca53ab ER |
132 | %if "%{_rpmversion}" >= "5" |
133 | BuildArch: noarch | |
134 | %endif | |
31397b7d ER |
135 | |
136 | %description apidocs | |
137 | API and internal documentation for Berkeley database library. | |
138 | ||
ee5514d7 JB |
139 | %description apidocs -l pl.UTF-8 |
140 | Dokumentacja API i wewnętrzna do biblioteki baz danych Berkeley. | |
141 | ||
e42fa043 AM |
142 | %package cxx |
143 | Summary: Berkeley database library for C++ | |
144 | Summary(pl.UTF-8): Biblioteka baz danych Berkeley dla C++ | |
145 | Group: Libraries | |
554ba8b9 | 146 | %if %{with default_db} |
e42fa043 AM |
147 | Provides: db-cxx = %{version}-%{release} |
148 | Obsoletes: db4-cxx | |
554ba8b9 | 149 | %endif |
e42fa043 AM |
150 | |
151 | %description cxx | |
152 | Berkeley database library for C++. | |
153 | ||
154 | %description cxx -l pl.UTF-8 | |
155 | Biblioteka baz danych Berkeley dla C++. | |
156 | ||
157 | %package cxx-devel | |
158 | Summary: Header files for db-cxx library | |
159 | Summary(pl.UTF-8): Pliki nagłówkowe biblioteki db-cxx | |
160 | Group: Development/Libraries | |
0db17e6a ER |
161 | Requires: %{name}-cxx = %{version}-%{release} |
162 | Requires: %{name}-devel = %{version}-%{release} | |
554ba8b9 | 163 | %if %{with default_db} |
e42fa043 | 164 | Provides: db-cxx-devel = %{version}-%{release} |
25836e73 | 165 | Obsoletes: db-cxx-devel |
554ba8b9 | 166 | %endif |
e42fa043 AM |
167 | Conflicts: db-devel < 4.1.25-3 |
168 | ||
169 | %description cxx-devel | |
170 | Header files for db-cxx library. | |
171 | ||
172 | %description cxx-devel -l pl.UTF-8 | |
173 | Pliki nagłówkowe biblioteki db-cxx. | |
174 | ||
175 | %package cxx-static | |
176 | Summary: Static version of db-cxx library | |
177 | Summary(pl.UTF-8): Statyczna wersja biblioteki db-cxx | |
178 | Group: Development/Libraries | |
0db17e6a | 179 | Requires: %{name}-cxx-devel = %{version}-%{release} |
554ba8b9 | 180 | %if %{with default_db} |
e42fa043 | 181 | Provides: db-cxx-static = %{version}-%{release} |
25836e73 | 182 | Obsoletes: db-cxx-static |
554ba8b9 | 183 | %endif |
e42fa043 AM |
184 | Conflicts: db-static < 4.2.50-1 |
185 | ||
186 | %description cxx-static | |
187 | Static version of db-cxx library. | |
188 | ||
189 | %description cxx-static -l pl.UTF-8 | |
190 | Statyczna wersja biblioteki db-cxx. | |
191 | ||
192 | %package java | |
193 | Summary: Berkeley database library for Java | |
194 | Summary(pl.UTF-8): Biblioteka baz danych Berkeley dla Javy | |
195 | Group: Libraries | |
fc4b1ff1 | 196 | Requires: jpackage-utils |
554ba8b9 | 197 | %if %{with default_db} |
e42fa043 | 198 | Provides: db-java = %{version}-%{release} |
25836e73 | 199 | Obsoletes: db-java |
554ba8b9 | 200 | %endif |
e42fa043 AM |
201 | |
202 | %description java | |
203 | Berkeley database library for Java. | |
204 | ||
205 | %description java -l pl.UTF-8 | |
206 | Biblioteka baz danych Berkeley dla Javy. | |
207 | ||
208 | %package java-devel | |
209 | Summary: Development files for db-java library | |
210 | Summary(pl.UTF-8): Pliki programistyczne biblioteki db-java | |
211 | Group: Development/Languages/Java | |
0db17e6a | 212 | Requires: %{name}-java = %{version}-%{release} |
554ba8b9 | 213 | %if %{with default_db} |
e42fa043 | 214 | Provides: db-java-devel = %{version}-%{release} |
25836e73 | 215 | Obsoletes: db-java-devel |
554ba8b9 | 216 | %endif |
e42fa043 AM |
217 | Conflicts: db-devel < 4.1.25-3 |
218 | ||
219 | %description java-devel | |
220 | Development files for db-java library. | |
221 | ||
222 | %description java-devel -l pl.UTF-8 | |
223 | Pliki programistyczne biblioteki db-java. | |
224 | ||
225 | %package tcl | |
226 | Summary: Berkeley database library for Tcl | |
227 | Summary(pl.UTF-8): Biblioteka baz danych Berkeley dla Tcl | |
228 | Group: Development/Languages/Tcl | |
229 | Requires: tcl | |
554ba8b9 | 230 | %if %{with default_db} |
e42fa043 AM |
231 | Provides: db-tcl = %{version}-%{release} |
232 | Obsoletes: db4-tcl | |
554ba8b9 | 233 | %endif |
e42fa043 AM |
234 | |
235 | %description tcl | |
236 | Berkeley database library for Tcl. | |
237 | ||
238 | %description tcl -l pl.UTF-8 | |
239 | Biblioteka baz danych Berkeley dla Tcl. | |
240 | ||
241 | %package tcl-devel | |
242 | Summary: Development files for db-tcl library | |
243 | Summary(pl.UTF-8): Pliki programistyczne biblioteki db-tcl | |
244 | Group: Development/Languages/Tcl | |
0db17e6a | 245 | Requires: %{name}-tcl = %{version}-%{release} |
554ba8b9 | 246 | %if %{with default_db} |
e42fa043 | 247 | Provides: db-tcl-devel = %{version}-%{release} |
25836e73 | 248 | Obsoletes: db-tcl-devel |
554ba8b9 | 249 | %endif |
e42fa043 AM |
250 | Conflicts: db-devel < 4.1.25-3 |
251 | ||
252 | %description tcl-devel | |
253 | Development files for db-tcl library. | |
254 | ||
255 | %description tcl-devel -l pl.UTF-8 | |
256 | Pliki programistyczne biblioteki db-tcl. | |
257 | ||
258 | %package utils | |
259 | Summary: Command line tools for managing Berkeley DB databases | |
260 | Summary(pl.UTF-8): Narzędzia do obsługi baz Berkeley DB z linii poleceń | |
261 | Group: Applications/Databases | |
0db17e6a | 262 | Requires: %{name} = %{version}-%{release} |
554ba8b9 | 263 | %if %{with default_db} |
e42fa043 | 264 | Provides: db-utils = %{version}-%{release} |
25836e73 | 265 | Obsoletes: db-utils |
e42fa043 | 266 | Obsoletes: db3-utils |
d3c3fe80 | 267 | Obsoletes: db4-utils |
554ba8b9 | 268 | %endif |
e42fa043 AM |
269 | |
270 | %description utils | |
271 | The Berkeley Database (Berkeley DB) is a programmatic toolkit that | |
272 | provides embedded database support for both traditional and | |
273 | client/server applications. Berkeley DB includes B+tree, Extended | |
274 | Linear Hashing, Fixed and Variable-length record access methods, | |
275 | transactions, locking, logging, shared memory caching and database | |
276 | recovery. DB supports C, C++, Java and Perl APIs. | |
277 | ||
278 | This package contains command line tools for managing Berkeley DB | |
279 | databases. | |
280 | ||
281 | %description utils -l pl.UTF-8 | |
282 | Berkeley Database (Berkeley DB) to zestaw narzędzi programistycznych | |
283 | zapewniających obsługę baz danych w aplikacjach tradycyjnych jak i | |
284 | klient-serwer. Berkeley DB obsługuje dostęp do bazy przez B-drzewa i | |
285 | funkcje mieszające ze stałą lub zmienną wielkością rekordu, | |
286 | transakcje, kroniki, pamięć dzieloną i odtwarzanie baz. Ma wsparcie | |
287 | dla C, C++, Javy i Perla. | |
288 | ||
289 | Ten pakiet zawiera narzędzia do obsługi baz Berkeley DB z linii | |
290 | poleceń. | |
291 | ||
292 | %prep | |
d3c3fe80 | 293 | %setup -q -n db-%{ver} |
d3c3fe80 ER |
294 | # official patches |
295 | %patchset_patch 1 %{patchlevel} | |
e42fa043 | 296 | |
52f71c64 MB |
297 | %patch0 -p1 |
298 | ||
e42fa043 | 299 | %build |
d685cba6 | 300 | cp -f /usr/share/automake/config.sub dist |
e42fa043 | 301 | |
be6de178 | 302 | JAVACFLAGS="-source 1.5 -target 1.5" |
303 | export JAVACFLAGS | |
304 | ||
e42fa043 AM |
305 | %if %{with static_libs} |
306 | cp -a build_unix build_unix.static | |
307 | ||
308 | cd build_unix.static | |
309 | ||
310 | CC="%{__cc}" | |
311 | CXX="%{__cxx}" | |
312 | CFLAGS="%{rpmcflags}" | |
313 | CXXFLAGS="%{rpmcflags} -fno-implicit-templates" | |
314 | LDFLAGS="%{rpmcflags} %{rpmldflags}" | |
315 | export CC CXX CFLAGS CXXFLAGS LDFLAGS | |
316 | ||
317 | ../dist/%configure \ | |
e42fa043 AM |
318 | --disable-shared \ |
319 | --enable-static \ | |
f89e9bd0 JB |
320 | --enable-compat185 \ |
321 | --enable-cxx \ | |
8cf606eb | 322 | --enable-posixmutexes \ |
f89e9bd0 | 323 | --enable-rpc |
e42fa043 AM |
324 | |
325 | # (temporarily?) disabled because of compilation errors: | |
326 | # --enable-dump185 \ | |
327 | ||
328 | %{__make} library_build | |
329 | cd .. | |
330 | %endif | |
331 | ||
332 | cd build_unix | |
333 | ||
334 | ../dist/%configure \ | |
335 | --prefix=%{_prefix} \ | |
336 | --libdir=%{_libdir} \ | |
f89e9bd0 JB |
337 | --enable-shared \ |
338 | --disable-static \ | |
e42fa043 | 339 | --enable-compat185 \ |
e42fa043 | 340 | --enable-cxx \ |
f89e9bd0 JB |
341 | --enable-posixmutexes \ |
342 | --enable-rpc \ | |
e42fa043 | 343 | %{?with_java:--enable-java} \ |
f89e9bd0 | 344 | %{?with_tcl:--enable-tcl --with-tcl=/usr/lib} |
e42fa043 AM |
345 | |
346 | %{__make} library_build \ | |
347 | TCFLAGS='-I$(builddir) -I%{_includedir}' \ | |
348 | LIBSO_LIBS="\$(LIBS)" \ | |
349 | LIBTSO_LIBS="\$(LIBS) -ltcl" | |
350 | ||
351 | %install | |
352 | rm -rf $RPM_BUILD_ROOT | |
554ba8b9 | 353 | install -d $RPM_BUILD_ROOT{%{_includedir},%{_libdir},%{_bindir}} |
e42fa043 AM |
354 | %if %{with java} |
355 | install -d $RPM_BUILD_ROOT%{_javadir} | |
356 | %endif | |
357 | ||
358 | %if %{with static_libs} | |
359 | %{__make} -C build_unix.static library_install \ | |
ee5514d7 | 360 | DESTDIR=$RPM_BUILD_ROOT \ |
554ba8b9 JB |
361 | docdir=%{_docdir}/db-%{version}-docs \ |
362 | includedir=%{_includedir} | |
e42fa043 AM |
363 | %endif |
364 | ||
365 | %{__make} -C build_unix library_install \ | |
e42fa043 | 366 | DESTDIR=$RPM_BUILD_ROOT \ |
ee5514d7 | 367 | LIB_INSTALL_FILE_LIST="" \ |
554ba8b9 JB |
368 | docdir=%{_docdir}/db-%{version}-docs \ |
369 | includedir=%{_includedir} | |
e42fa043 | 370 | |
554ba8b9 JB |
371 | %if %{with default_db} |
372 | install -d $RPM_BUILD_ROOT/%{_lib} | |
d3c3fe80 | 373 | mv $RPM_BUILD_ROOT%{_libdir}/libdb-%{libver}.so $RPM_BUILD_ROOT/%{_lib} |
554ba8b9 | 374 | %endif |
e42fa043 AM |
375 | |
376 | cd $RPM_BUILD_ROOT%{_libdir} | |
554ba8b9 JB |
377 | %if %{with static_libs} |
378 | mv -f libdb.a libdb-%{libver}.a | |
379 | mv -f libdb_cxx.a libdb_cxx-%{libver}.a | |
380 | %endif | |
381 | %if %{with java} | |
f89e9bd0 | 382 | mv -f $RPM_BUILD_ROOT%{_libdir}/db.jar $RPM_BUILD_ROOT%{_javadir}/db-%{libver}.jar |
554ba8b9 JB |
383 | %endif |
384 | %if %{with default_db} | |
d3c3fe80 ER |
385 | ln -sf /%{_lib}/libdb-%{libver}.so libdb.so |
386 | ln -sf /%{_lib}/libdb-%{libver}.so libdb4.so | |
387 | ln -sf /%{_lib}/libdb-%{libver}.so libdb-%{libver}.so | |
388 | ln -sf /%{_lib}/libdb-%{libver}.so libndbm.so | |
389 | ln -sf libdb-%{libver}.la libdb.la | |
390 | ln -sf libdb-%{libver}.la libdb4.la | |
391 | ln -sf libdb-%{libver}.la libndbm.la | |
554ba8b9 JB |
392 | ln -sf libdb_cxx-%{libver}.so libdb_cxx.so |
393 | ln -sf libdb_cxx-%{libver}.la libdb_cxx.la | |
e42fa043 | 394 | %if %{with java} |
d3c3fe80 | 395 | ln -sf libdb_java-%{libver}.la libdb_java.la |
f89e9bd0 | 396 | ln -sf db-%{libver}.jar $RPM_BUILD_ROOT%{_javadir}/db.jar |
e42fa043 AM |
397 | %endif |
398 | %if %{with tcl} | |
d3c3fe80 ER |
399 | ln -sf libdb_tcl-%{libver}.so libdb_tcl.so |
400 | ln -sf libdb_tcl-%{libver}.la libdb_tcl.la | |
e42fa043 | 401 | %endif |
e42fa043 | 402 | %if %{with static_libs} |
d3c3fe80 ER |
403 | ln -sf libdb-%{libver}.a libdb.a |
404 | ln -sf libdb-%{libver}.a libdb4.a | |
405 | ln -sf libdb-%{libver}.a libndbm.a | |
d3c3fe80 | 406 | ln -sf libdb_cxx-%{libver}.a libdb_cxx.a |
e42fa043 | 407 | %endif |
554ba8b9 | 408 | %endif |
e42fa043 | 409 | |
d3c3fe80 ER |
410 | sed -i "s/old_library=''/old_library='libdb-%{libver}.a'/" libdb-%{libver}.la |
411 | sed -i "s/old_library=''/old_library='libdb_cxx-%{libver}.a'/" libdb_cxx-%{libver}.la | |
e42fa043 | 412 | |
f89e9bd0 JB |
413 | cd - |
414 | ||
415 | cd $RPM_BUILD_ROOT%{_bindir} | |
416 | mv -f berkeley_db_svc berkeley_db_svc-%{libver} | |
417 | %{?with_default_db:ln -sf berkeley_db_svc-%{libver} berkeley_db_svc} | |
418 | for F in db_*; do | |
419 | Fver=$(echo $F|sed 's/db_/db%{libver}_/') | |
420 | mv $F $Fver | |
421 | %{?with_default_db:ln -sf $Fver $F} | |
422 | done | |
e42fa043 AM |
423 | cd - |
424 | rm -f examples_c*/tags | |
425 | install -d $RPM_BUILD_ROOT%{_examplesdir}/db-%{version} | |
426 | cp -rf examples_c/* $RPM_BUILD_ROOT%{_examplesdir}/db-%{version} | |
427 | ||
428 | install -d $RPM_BUILD_ROOT%{_examplesdir}/db-cxx-%{version} | |
429 | cp -rf examples_cxx/* $RPM_BUILD_ROOT%{_examplesdir}/db-cxx-%{version} | |
430 | ||
431 | %if %{with java} | |
432 | install -d $RPM_BUILD_ROOT%{_examplesdir}/db-java-%{version} | |
433 | cp -rf examples_java/* $RPM_BUILD_ROOT%{_examplesdir}/db-java-%{version} | |
434 | %endif | |
435 | ||
14bb5365 | 436 | # in %doc |
ee5514d7 | 437 | %{__rm} $RPM_BUILD_ROOT%{_docdir}/db-%{version}-docs/{index.html,license/license_db.html} |
14bb5365 | 438 | |
e42fa043 AM |
439 | %clean |
440 | rm -rf $RPM_BUILD_ROOT | |
441 | ||
442 | %post -p /sbin/ldconfig | |
443 | %postun -p /sbin/ldconfig | |
444 | ||
445 | %post tcl -p /sbin/ldconfig | |
446 | %postun tcl -p /sbin/ldconfig | |
447 | ||
448 | %post cxx -p /sbin/ldconfig | |
449 | %postun cxx -p /sbin/ldconfig | |
450 | ||
451 | %files | |
452 | %defattr(644,root,root,755) | |
14bb5365 | 453 | %doc LICENSE README docs/index.html docs/license |
554ba8b9 | 454 | %if %{with default_db} |
d3c3fe80 | 455 | %attr(755,root,root) /%{_lib}/libdb-%{libver}.so |
554ba8b9 JB |
456 | %else |
457 | %attr(755,root,root) %{_libdir}/libdb-%{libver}.so | |
458 | %endif | |
e42fa043 AM |
459 | |
460 | %files devel | |
461 | %defattr(644,root,root,755) | |
554ba8b9 JB |
462 | %{_libdir}/libdb-%{libver}.la |
463 | %if %{with default_db} | |
d3c3fe80 | 464 | %attr(755,root,root) %{_libdir}/libdb-%{libver}.so |
e42fa043 AM |
465 | %attr(755,root,root) %{_libdir}/libdb4.so |
466 | %attr(755,root,root) %{_libdir}/libdb.so | |
467 | %attr(755,root,root) %{_libdir}/libndbm.so | |
e42fa043 AM |
468 | %{_libdir}/libdb4.la |
469 | %{_libdir}/libdb.la | |
470 | %{_libdir}/libndbm.la | |
554ba8b9 JB |
471 | %else |
472 | %dir %{_includedir} | |
473 | %endif | |
e42fa043 AM |
474 | %{_includedir}/db.h |
475 | %{_includedir}/db_185.h | |
31397b7d ER |
476 | %{_examplesdir}/db-%{version} |
477 | ||
478 | %if %{with static_libs} | |
479 | %files static | |
480 | %defattr(644,root,root,755) | |
481 | %{_libdir}/libdb-%{libver}.a | |
554ba8b9 | 482 | %if %{with default_db} |
31397b7d ER |
483 | %{_libdir}/libdb4.a |
484 | %{_libdir}/libdb.a | |
485 | %{_libdir}/libndbm.a | |
486 | %endif | |
554ba8b9 | 487 | %endif |
31397b7d ER |
488 | |
489 | %if %{with apidocs} | |
490 | %files apidocs | |
491 | %defattr(644,root,root,755) | |
14bb5365 | 492 | %dir %{_docdir}/db-%{version}-docs |
e42fa043 | 493 | %{_docdir}/db-%{version}-docs/api_c |
c5e6f1b4 | 494 | %{_docdir}/db-%{version}-docs/articles |
e42fa043 AM |
495 | %dir %{_docdir}/db-%{version}-docs/gsg |
496 | %{_docdir}/db-%{version}-docs/gsg/C | |
497 | %dir %{_docdir}/db-%{version}-docs/gsg_txn | |
498 | %{_docdir}/db-%{version}-docs/gsg_txn/C | |
499 | %dir %{_docdir}/db-%{version}-docs/gsg_db_rep | |
500 | %{_docdir}/db-%{version}-docs/gsg_db_rep/C | |
501 | %{_docdir}/db-%{version}-docs/images | |
14bb5365 | 502 | %{_docdir}/db-%{version}-docs/porting |
e42fa043 | 503 | %{_docdir}/db-%{version}-docs/ref |
e42fa043 AM |
504 | %endif |
505 | ||
506 | %files cxx | |
507 | %defattr(644,root,root,755) | |
d3c3fe80 | 508 | %attr(755,root,root) %{_libdir}/libdb_cxx-%{libver}.so |
e42fa043 AM |
509 | |
510 | %files cxx-devel | |
511 | %defattr(644,root,root,755) | |
d3c3fe80 | 512 | %{_libdir}/libdb_cxx-%{libver}.la |
554ba8b9 JB |
513 | %if %{with default_db} |
514 | %attr(755,root,root) %{_libdir}/libdb_cxx.so | |
e42fa043 | 515 | %{_libdir}/libdb_cxx.la |
554ba8b9 | 516 | %endif |
e42fa043 AM |
517 | %{_includedir}/db_cxx.h |
518 | %{_docdir}/db-%{version}-docs/api_cxx | |
519 | %{_docdir}/db-%{version}-docs/gsg/CXX | |
520 | %{_docdir}/db-%{version}-docs/gsg_txn/CXX | |
521 | %{_docdir}/db-%{version}-docs/gsg_db_rep/CXX | |
522 | %{_examplesdir}/db-cxx-%{version} | |
523 | ||
524 | %if %{with static_libs} | |
525 | %files cxx-static | |
526 | %defattr(644,root,root,755) | |
d3c3fe80 | 527 | %{_libdir}/libdb_cxx-%{libver}.a |
554ba8b9 | 528 | %if %{with default_db} |
e42fa043 AM |
529 | %{_libdir}/libdb_cxx.a |
530 | %endif | |
554ba8b9 | 531 | %endif |
e42fa043 AM |
532 | |
533 | %if %{with java} | |
534 | %files java | |
535 | %defattr(644,root,root,755) | |
d3c3fe80 | 536 | %attr(755,root,root) %{_libdir}/libdb_java-%{libver}.so |
f89e9bd0 JB |
537 | %{_javadir}/db-%{libver}.jar |
538 | %if %{with default_db} | |
e42fa043 | 539 | %{_javadir}/db.jar |
f89e9bd0 | 540 | %endif |
e42fa043 AM |
541 | |
542 | %files java-devel | |
543 | %defattr(644,root,root,755) | |
d3c3fe80 | 544 | %{_libdir}/libdb_java-%{libver}.la |
554ba8b9 JB |
545 | %if %{with default_db} |
546 | %attr(755,root,root) %{_libdir}/libdb_java.so | |
e42fa043 | 547 | %{_libdir}/libdb_java.la |
554ba8b9 | 548 | %endif |
e42fa043 AM |
549 | %{_docdir}/db-%{version}-docs/collections |
550 | %{_docdir}/db-%{version}-docs/gsg/JAVA | |
551 | %{_docdir}/db-%{version}-docs/gsg_txn/JAVA | |
552 | %{_docdir}/db-%{version}-docs/gsg_db_rep/JAVA | |
553 | %{_docdir}/db-%{version}-docs/java | |
554 | %{_examplesdir}/db-java-%{version} | |
555 | %endif | |
556 | ||
557 | %if %{with tcl} | |
558 | %files tcl | |
559 | %defattr(644,root,root,755) | |
d3c3fe80 | 560 | %attr(755,root,root) %{_libdir}/libdb_tcl-%{libver}.so |
e42fa043 AM |
561 | |
562 | %files tcl-devel | |
563 | %defattr(644,root,root,755) | |
d3c3fe80 | 564 | %{_libdir}/libdb_tcl-%{libver}.la |
554ba8b9 JB |
565 | %if %{with default_db} |
566 | %attr(755,root,root) %{_libdir}/libdb_tcl.so | |
e42fa043 | 567 | %{_libdir}/libdb_tcl.la |
554ba8b9 | 568 | %endif |
e42fa043 AM |
569 | %{_docdir}/db-%{version}-docs/api_tcl |
570 | %endif | |
571 | ||
572 | %files utils | |
573 | %defattr(644,root,root,755) | |
f89e9bd0 JB |
574 | %attr(755,root,root) %{_bindir}/berkeley_db_svc-%{libver} |
575 | %attr(755,root,root) %{_bindir}/db%{libver}_archive | |
576 | %attr(755,root,root) %{_bindir}/db%{libver}_checkpoint | |
577 | %attr(755,root,root) %{_bindir}/db%{libver}_codegen | |
578 | %attr(755,root,root) %{_bindir}/db%{libver}_deadlock | |
579 | %attr(755,root,root) %{_bindir}/db%{libver}_dump | |
580 | #%attr(755,root,root) %{_bindir}/db%{libver}_dump185 | |
581 | %attr(755,root,root) %{_bindir}/db%{libver}_hotbackup | |
582 | %attr(755,root,root) %{_bindir}/db%{libver}_load | |
583 | %attr(755,root,root) %{_bindir}/db%{libver}_printlog | |
584 | %attr(755,root,root) %{_bindir}/db%{libver}_recover | |
585 | %attr(755,root,root) %{_bindir}/db%{libver}_stat | |
586 | %attr(755,root,root) %{_bindir}/db%{libver}_upgrade | |
587 | %attr(755,root,root) %{_bindir}/db%{libver}_verify | |
588 | %if %{with default_db} | |
e42fa043 | 589 | %attr(755,root,root) %{_bindir}/berkeley_db_svc |
f89e9bd0 JB |
590 | %attr(755,root,root) %{_bindir}/db_archive |
591 | %attr(755,root,root) %{_bindir}/db_checkpoint | |
592 | %attr(755,root,root) %{_bindir}/db_codegen | |
593 | %attr(755,root,root) %{_bindir}/db_deadlock | |
594 | %attr(755,root,root) %{_bindir}/db_dump | |
595 | #%attr(755,root,root) %{_bindir}/db_dump185 | |
596 | %attr(755,root,root) %{_bindir}/db_hotbackup | |
597 | %attr(755,root,root) %{_bindir}/db_load | |
598 | %attr(755,root,root) %{_bindir}/db_printlog | |
599 | %attr(755,root,root) %{_bindir}/db_recover | |
600 | %attr(755,root,root) %{_bindir}/db_stat | |
601 | %attr(755,root,root) %{_bindir}/db_upgrade | |
602 | %attr(755,root,root) %{_bindir}/db_verify | |
603 | %endif | |
01378bdd | 604 | %dir %{_docdir}/db-%{version}-docs |
e42fa043 | 605 | %{_docdir}/db-%{version}-docs/utility |