1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
--- configure.in.orig 2011-01-13 21:12:40.420005851 +0100
+++ configure.in 2011-01-13 21:15:23.680008513 +0100
@@ -4456,16 +4456,17 @@
else return 1;
}
], [AC_MSG_RESULT([yes])], [AC_MSG_ERROR([no. you need at least db 4.1])])
- DB_LIB=
- for dbver in '' -5.1 5.1 -5.0 5.0 -5 5 -4.8 4.8 -4.7 4.7 -4 4; do
- AC_CHECK_LIB(db$dbver, dbopen, [ DB_LIB="db$dbver"; DB_CPPLIB="db_cxx$dbver"; break; ] ,
- AC_CHECK_LIB(db$dbver, __db185_open, [ DB_LIB="db$dbver"; DB_CPPLIB="db_cxx$dbver"; break; ]
+ save_LIBS="$LIBS"
+ for dbver in -5.1 5.1 -5.0 5.0 -5 5 -4.8 4.8 -4.7 4.7 -4 4 ''; do
+ AC_CHECK_LIB(db$dbver, db_create, [ DB_LIB="db$dbver"; DB_CPPLIB="db_cxx$dbver"; LIBS="-ldb$dbver $LIBS"; break; ] ,
+ AC_CHECK_LIB(db$dbver, __db185_open, [ DB_LIB="db$dbver"; DB_CPPLIB="db_cxx$dbver"; LIBS="-ldb$dbver $LIBS"; break; ]
)
)
done
if test -z "$DB_LIB" ; then
- AC_MSG_ERROR([db not installed or functional])
+ AC_CHECK_FUNC(dbopen, [], [ AC_MSG_ERROR([db not installed or functional]) ])
fi
+ LIBS="$save_LIBS"
SCPDEFS="$SCPDEFS -DSYSTEM_DB"
else
AC_MSG_RESULT([internal])
|