-AC_CHECK_HEADER(gdbm.h,, [
- echo
- echo 'FATAL ERROR: could not find a valid GNU database manager header.'
- echo 'Install either the gdbm-devel (rpm) or the libgdbmg1-dev (deb) package.'
- exit 1
-])
-AC_CHECK_LIB(gdbm, gdbm_open,, [
- echo
- echo 'FATAL ERROR: could not find a valid GNU database manager library.'
- echo 'Install either the gdbm-devel (rpm) or the libgdbmg1-dev (deb) package.'
- exit 1
-])
-libgdbm="/usr/lib/libgdbm.a"
+libgdbm=""
+have_db=true
+AC_CHECK_HEADER(gdbm/ndbm.h,, [ have_db=false ])
+if test $have_db = "true" -a -f /usr/lib/libgdbm.a; then
+ libgdbm="/usr/lib/libgdbm.a"
+fi