[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: kdesdk/kbabel/kbabeldict/modules/dbsearchengine
From: Adriaan de Groot <groot () kde ! org>
Date: 2004-07-31 0:51:10
Message-ID: 20040731005110.442DD99F5 () office ! kde ! org
[Download RAW message or body]
CVS commit by adridg:
Make it possible to specify the db4 header file explicitly -- this is
needed on FreeBSD at least, where the header can be found in an awful
lot of different places and naming schemes. For FBSD, typical use would
be: --with-db-include=/usr/local/include/db41/db.h --with-db-name=db41
For other systems, the autodetection remains unchanged.
CCMAIL:kde@freebsd.org
M +17 -7 configure.in.in 1.16
M +4 -0 database.h 1.18
--- kdesdk/kbabel/kbabeldict/modules/dbsearchengine/configure.in.in #1.15:1.16
@@ -8,4 +8,5 @@
ac_db_includes="."
ac_db_libraries="."
+ac_db_include_file="db.h"
AC_ARG_WITH(db-dir,
@@ -18,4 +19,8 @@
[ ac_db_includes="$withval"
])
+AC_ARG_WITH(db-include,
+ AC_HELP_STRING([--with-db-include=FILE],[path to the Berkeley DB IV header \
file]), + [ ac_db_include_file="$withval"
+ ])
AC_ARG_WITH(db-lib-dir,
AC_HELP_STRING([--with-db-lib-dir=DIR],[where the libs of Berkeley DB IV are \
installed]), @@ -29,4 +34,5 @@
AC_DEFUN([KDE_CHECK_DB_VERSION],
[
+ifelse($3,,,[LIBS="$kde_db_safe_LIBS -l$3"])
AC_TRY_LINK([
#include <$2>
@@ -56,14 +62,14 @@
kde_cv_berk_database=NO
if test "xNO" = "x$kde_cv_berk_database" ; then
- KDE_CHECK_DB_VERSION($ac_db_name, db.h)
+ KDE_CHECK_DB_VERSION($ac_db_name, $ac_db_include_file, $ac_db_name)
fi
if test "xNO" = "x$kde_cv_berk_database" ; then
- KDE_CHECK_DB_VERSION(db42, db4/db.h)
+ KDE_CHECK_DB_VERSION(db4, db4/db.h, db4)
fi
if test "xNO" = "x$kde_cv_berk_database" ; then
- KDE_CHECK_DB_VERSION(db4, db4/db.h)
+ KDE_CHECK_DB_VERSION(db4-db, db.h, db4)
fi
if test "xNO" = "x$kde_cv_berk_database" ; then
- KDE_CHECK_DB_VERSION(db4, db.h)
+ KDE_CHECK_DB_VERSION(db, db.h, db)
fi
@@ -78,5 +84,4 @@
case "$kde_cv_berk_database" in
NO)
- AC_MSG_RESULT(not found)
AC_MSG_WARN(Dictionary plugin \"Translation Database\" for KBabel will not be \
built! Please install Berkeley Database IV. See http://www.sleepycat.com for more \
information.) LIB_DBIV=""
@@ -103,7 +108,12 @@
$ac_db_name)
LIB_DBIV="-l$ac_db_name"
- kde_db_header=db.h
+ kde_db_header="$ac_db_include_file"
AC_MSG_RESULT(user specified $ac_db_name)
- AC_DEFINE_UNQUOTED(HAVE_DB_DB_H, 1, [DB 4 header location] )
+ if test "x$ac_db_include_file" = "xdb.h" ; then
+ AC_DEFINE_UNQUOTED(HAVE_DB_DB_H, 1, [DB 4 header location] )
+ else
+ AC_DEFINE_UNQUOTED(USE_DB_H_PATH, <$ac_db_include_file>, [DB 4 header path])
+ fi
+
;;
esac
--- kdesdk/kbabel/kbabeldict/modules/dbsearchengine/database.h #1.17:1.18
@@ -30,4 +30,7 @@
#include <config.h>
+#ifdef USE_DB_H_PATH
+#include USE_DB_H_PATH
+#else
#ifdef HAVE_DB4_DB_H
#include <db4/db.h>
@@ -35,4 +38,5 @@
#include <db.h>
#endif
+#endif
#define uint32 u_int32_t
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic