2 # spec file for package gdbm
4 # Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany.
6 # All modifications and additions to the file contributed by third parties
7 # remain the property of their copyright owners, unless otherwise agreed
8 # upon. The license for this file, and modifications and additions to the
9 # file, is the same license as for the pristine package itself (unless the
10 # license for the pristine package is not an Open Source License, in which
11 # case the license is the MIT License). An "Open Source License" is a
12 # license that conforms to the Open Source Definition (Version 1.9)
13 # published by the Open Source Initiative.
15 # Please submit bugfixes or comments via http://bugs.opensuse.org/
23 Summary: GNU dbm key/data database
25 Url: http://directory.fsf.org/GNU/gdbm.html
26 Group: System/Libraries
27 Source: %{name}-%{version}.tar.bz2
28 Source2: baselibs.conf
29 Patch0: gdbm-%{version}.dif
30 Patch1: gdbm-protoize_dbm_headers.patch
31 Patch2: gdbm-prototype_static_functions.patch
32 Patch3: gdbm-fix_testprogs.patch
33 Patch4: gdbm-1.8.3-no-build-date.patch
34 BuildRequires: libtool
35 BuildRoot: %{_tmppath}/%{name}-%{version}-build
38 GNU dbm is a library of database functions that use extensible
39 hashing and work similar to the standard UNIX dbm. These routines are
40 provided to a programmer needing to create and manipulate a hashed
43 The basic use of GDBM is to store key/data pairs in a data file. Each
44 key must be unique and each key is paired with only one data item.
46 The library provides primitives for storing key/data pairs, searching
47 and retrieving the data by its key and deleting a key along with its
48 data. It also supports sequential iteration over all key/data pairs in
51 For compatibility with programs using old UNIX dbm functions, the
52 package also provides traditional dbm and ndbm interfaces.
56 Summary: GNU dbm key/data database
57 Group: System/Libraries
59 Obsoletes: gdbm < %{version}-%{release}
60 Provides: gdbm = %{version}-%{release}
62 %description -n %lname
63 GNU dbm is a library of database functions that use extensible
64 hashing and work similar to the standard UNIX dbm. These routines are
65 provided to a programmer needing to create and manipulate a hashed
68 The basic use of GDBM is to store key/data pairs in a data file. Each
69 key must be unique and each key is paired with only one data item.
71 The library provides primitives for storing key/data pairs, searching
72 and retrieving the data by its key and deleting a key along with its
73 data. It also supports sequential iteration over all key/data pairs in
76 For compatibility with programs using old UNIX dbm functions, the
77 package also provides traditional dbm and ndbm interfaces.
80 License: GPL-2.0+ ; LGPL-2.1+
81 Summary: Include Files and Libraries mandatory for Development
82 Group: Development/Libraries/C and C++
83 Requires: gdbm = %{version}
84 Provides: gdbm:/usr/lib/libgdbm.so
87 This package contains all necessary include files and libraries needed
88 to develop applications that require these.
100 autoreconf --force --install
104 export CFLAGS="%{optflags} -Wa,--noexecstack"
106 make %{?_smp_mflags};
109 make install INSTALL_ROOT=%{buildroot}
110 make install-compat INSTALL_ROOT=%{buildroot}
111 echo "/* GNU ld script
112 Use the shared library, but some functions are only in
113 the static library, so try that secondarily. */
114 GROUP ( %{_libdir}/libgdbm.so %{_libdir}/libgdbm_compat.so )" > %{buildroot}/%{_libdir}/libndbm.so
115 echo "/* GNU ld script
116 Use the shared library, but some functions are only in
117 the static library, so try that secondarily. */
118 GROUP ( %{_libdir}/libgdbm.a %{_libdir}/libgdbm_compat.a )" > %{buildroot}/%{_libdir}/libndbm.a
120 %post -n %lname -p /sbin/ldconfig
122 %postun -n %lname -p /sbin/ldconfig
125 %defattr(-,root,root)
126 %doc COPYING README NEWS
127 %{_libdir}/libgdbm.so.3
128 %{_libdir}/libgdbm.so.3.0.0
129 %{_libdir}/libgdbm_compat.so.3
130 %{_libdir}/libgdbm_compat.so.3.0.0
133 %defattr(-,root,root)
135 %{_includedir}/gdbm.h
136 %{_includedir}/ndbm.h
137 %{_infodir}/gdbm.info.gz
139 %{_libdir}/libgdbm.so
140 %{_libdir}/libgdbm_compat.a
141 %{_libdir}/libgdbm_compat.so
143 %{_libdir}/libndbm.so
144 %{_mandir}/man3/gdbm.3.gz
145 %exclude %{_libdir}/*.la