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
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
|
$Id: update-patches 24 2008-08-31 14:56:13Z wbx $
--- bogofilter-1.2.0.orig/configure.ac 2009-02-21 21:41:43.000000000 +0100
+++ bogofilter-1.2.0/configure.ac 2009-05-28 19:47:00.466710794 +0200
@@ -550,49 +550,6 @@ Cannot link against libdb? Try these ste
AH_TEMPLATE([HAVE_DB_H], [Have suitable db.h header])
AC_SUBST(LIBDB)
- dnl check if run-time link works
- saveLIBS="$LIBS"
- LIBS="$LIBS $LIBDB"
- AC_MSG_CHECKING(if a program can be linked against Berkeley DB and run)
- AC_RUN_IFELSE(
- AC_LANG_PROGRAM([[
-#ifdef HAVE_INTTYPES_H
-#include <inttypes.h>
-#endif
-#include <db.h>
- ]], [[
-return 0;
- ]]),,
- [AC_MSG_RESULT(no)
- AC_MSG_ERROR([Cannot run a program linked against libdb.
-Did you adjust your library search path to include your libdb?])],)
- AC_MSG_RESULT(yes)
-
- dnl check if header and library of DB library match
- dnl ignore if cross compiling
- AC_MSG_CHECKING(if Berkeley DB header and library versions match)
- rm -r -f bfadtestdir
- mkdir bfadtestdir
- AC_RUN_IFELSE(
- AC_LANG_PROGRAM([[
- #include <stdlib.h>
- #include <stdio.h>
-#ifdef HAVE_INTTYPES_H
-#include <inttypes.h>
-#endif
- #include <db.h>
- ]], [[
- int maj, min;
- (void)db_version(&maj, &min, 0);
- (void)fprintf(stderr, "headers: %d.%d, library: %d.%d\n",
- DB_VERSION_MAJOR, DB_VERSION_MINOR, maj, min);
- if (maj != DB_VERSION_MAJOR) exit(1);
- if (min != DB_VERSION_MINOR) exit(1);
- exit(0);
- ]]),,
- [AC_MSG_RESULT(no)
- AC_MSG_ERROR(db.h header file and db library version do not match.)],)
- AC_MSG_RESULT(yes)
AC_CHECK_DECLS(db_create,,
AC_MSG_ERROR([[Can not locate a suitable Berkeley DB db.h header file.
Use --with-libdb-prefix=PATH to specify the path to a v3+ install directory.
|