1 %define __strip %{_mingw32_strip}
2 %define __objdump %{_mingw32_objdump}
3 %define _use_internal_dependency_generator 0
4 %define __find_requires %{_mingw32_findrequires}
5 %define __find_provides %{_mingw32_findprovides}
10 Summary: MinGW port of GNU database routines
13 Group: Development/Libraries
14 URL: http://www.gnu.org/software/gdbm/
15 Source0: ftp://ftp.gnu.org/gnu/gdbm/gdbm-%{version}.tar.gz
16 BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
18 Patch0: gdbm-1.8.0-jbj.patch
19 Patch1: gdbm-1.8.0-fhs.patch
20 Patch2: gdbm-1.8.0-cflags.patch
21 Patch3: gdbm-1.8.0-64offset.patch
23 Patch100: mingw32-gdbm-1.8.0-windows.patch
27 BuildRequires: mingw32-filesystem >= 26
28 BuildRequires: mingw32-gcc
29 BuildRequires: mingw32-binutils
31 BuildRequires: libtool
35 Gdbm is a GNU database indexing library, including routines which use
36 extensible hashing. Gdbm works in a similar way to standard UNIX dbm
37 routines. Gdbm is useful for developers who write C applications and
38 need access to a simple and efficient database or who are building C
39 applications which will use such a database.
41 This is the MinGW Windows port of the libraries and development tools.
45 %setup -q -n gdbm-%{version}
48 %patch2 -p 1 -b .cflags
49 %patch3 -p1 -b .offset
51 %patch100 -p1 -b .windows
55 libtoolize --force --copy
59 make libdir=%{_mingw32_libdir} all progs
63 rm -rf $RPM_BUILD_ROOT
64 make prefix=$RPM_BUILD_ROOT%{_mingw32_prefix} install
66 # Install the binaries. Arguable whether we really want these.
67 install conv2gdbm.exe tdbm.exe testdbm.exe testgdbm.exe testndbm.exe tndbm.exe \
68 $RPM_BUILD_ROOT%{_mingw32_bindir}
70 # Native Fedora package seems to fluff this, but as far as I
71 # can tell they are trying to create <gdbm/gdbm.h> which
73 pushd $RPM_BUILD_ROOT%{_mingw32_includedir}
79 # Remove the static library.
80 rm $RPM_BUILD_ROOT%{_mingw32_libdir}/libgdbm.a
82 # Remove man page and info file which duplicate what is in native package.
83 rm -r $RPM_BUILD_ROOT%{_mingw32_prefix}/man
84 rm -r $RPM_BUILD_ROOT%{_mingw32_prefix}/info
88 rm -rf $RPM_BUILD_ROOT
93 %{_mingw32_bindir}/conv2gdbm.exe
94 %{_mingw32_bindir}/tdbm.exe
95 %{_mingw32_bindir}/testdbm.exe
96 %{_mingw32_bindir}/testgdbm.exe
97 %{_mingw32_bindir}/testndbm.exe
98 %{_mingw32_bindir}/tndbm.exe
99 %{_mingw32_bindir}/libgdbm-2.dll
100 %{_mingw32_libdir}/libgdbm.dll.a
101 %{_mingw32_libdir}/libgdbm.la
102 %{_mingw32_includedir}/gdbm.h
103 %{_mingw32_includedir}/gdbm
107 * Fri Oct 3 2008 Richard W.M. Jones <rjones@redhat.com> - 1.8.0-1
108 - Initial RPM release.