]> git.pld-linux.org Git - packages/ocaml.git/blame - ocaml-db3.patch
- updated to 3.09.2
[packages/ocaml.git] / ocaml-db3.patch
CommitLineData
0be8cd9b
JB
1--- ocaml-3.09.2/configure.orig 2006-04-19 22:15:48.276544500 +0200
2+++ ocaml-3.09.2/configure 2006-04-22 23:49:10.045620750 +0200
3@@ -1238,51 +1238,12 @@
b9a9b48b
MM
4
5 # See if we can compile the dbm library
6
7-dbm_include="not found"
8-dbm_link="not found"
e15a2426
MM
9 use_gdbm_ndbm=no
10-
b9a9b48b
MM
11-for dir in /usr/include /usr/include/db1 /usr/include/gdbm; do
12- if test -f $dir/ndbm.h; then
13- dbm_include=$dir
14- if sh ./hasgot dbm_open; then
15- dbm_link=""
16- elif sh ./hasgot -lndbm dbm_open; then
17- dbm_link="-lndbm"
18- elif sh ./hasgot -ldb1 dbm_open; then
19- dbm_link="-ldb1"
20- elif sh ./hasgot -lgdbm dbm_open; then
21- dbm_link="-lgdbm"
6c6c92a8 22- elif sh ./hasgot -lgdbm_compat -lgdbm dbm_open; then
0be8cd9b 23- dbm_link="-lgdbm_compat -lgdbm"
b9a9b48b
MM
24- fi
25- break
26- fi
e15a2426
MM
27- if test -f $dir/gdbm-ndbm.h; then
28- dbm_include=$dir
29- use_gdbm_ndbm=yes
30- if sh ./hasgot -lgdbm_compat -lgdbm dbm_open; then
31- dbm_link="-lgdbm_compat -lgdbm"
32- fi
0be8cd9b 33- break
e15a2426 34- fi
b9a9b48b 35-done
e15a2426 36-if test "$dbm_include" = "not found" || test "$dbm_link" = "not found"; then
b9a9b48b
MM
37- echo "NDBM not found, the \"dbm\" library will not be supported."
38-else
39- echo "NDBM found (in $dbm_include)"
40- if test "$dbm_include" = "/usr/include"; then
41- dbm_include=""
42- else
43- dbm_include="-I$dbm_include"
44- fi
45- echo "DBM_INCLUDES=$dbm_include" >> Makefile
46- echo "DBM_LINK=$dbm_link" >> Makefile
e15a2426
MM
47- if test "$use_gdbm_ndbm" = "yes"; then
48- echo "#define DBM_USES_GDBM_NDBM" >> s.h
49- fi
b9a9b48b
MM
50- otherlibraries="$otherlibraries dbm"
51-fi
52+dbm_include=""
53+dbm_link="-ldb"
54+echo "DBM_INCLUDES=$dbm_include" >> Makefile
55+echo "DBM_LINK=$dbm_link" >> Makefile
56+otherlibraries="$otherlibraries dbm"
57
58 # Look for tcl/tk
59
e15a2426
MM
60diff -ur ocaml-3.07beta2/otherlibs/dbm/cldbm.c ocaml-3.07beta2-/otherlibs/dbm/cldbm.c
61--- ocaml-3.07beta2/otherlibs/dbm/cldbm.c 2003-07-08 15:50:31.000000000 +0200
62+++ ocaml-3.07beta2-/otherlibs/dbm/cldbm.c 2003-08-26 11:11:19.000000000 +0200
63@@ -24,7 +24,8 @@
64 #ifdef DBM_USES_GDBM_NDBM
65 #include <gdbm-ndbm.h>
66 #else
67-#include <ndbm.h>
68+#define DB_DBM_HSEARCH 1
69+#include <db.h>
70 #endif
71
72 /* Quite close to sys_open_flags, but we need RDWR */
This page took 0.041494 seconds and 4 git commands to generate.