Skip to content

Commit 8456235

Browse files
committed
Get bsddb module to compile with version 3.2 of BSD DB.
1 parent 95c1e50 commit 8456235

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

Modules/_bsddb.c

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1969,6 +1969,7 @@ DB_set_bt_minkey(DBObject* self, PyObject* args)
19691969
RETURN_NONE();
19701970
}
19711971

1972+
#if (DBVER >= 33)
19721973
static int
19731974
_default_cmp (const DBT *leftKey,
19741975
const DBT *rightKey)
@@ -2120,6 +2121,7 @@ DB_set_bt_compare (DBObject* self, PyObject* args)
21202121
RETURN_IF_ERR ();
21212122
RETURN_NONE ();
21222123
}
2124+
#endif /* DBVER >= 33 */
21232125

21242126

21252127
static PyObject*
@@ -3956,6 +3958,7 @@ DBEnv_set_lg_max(DBEnvObject* self, PyObject* args)
39563958
}
39573959

39583960

3961+
#if (DBVER >= 33)
39593962
static PyObject*
39603963
DBEnv_set_lg_regionmax(DBEnvObject* self, PyObject* args)
39613964
{
@@ -3971,6 +3974,7 @@ DBEnv_set_lg_regionmax(DBEnvObject* self, PyObject* args)
39713974
RETURN_IF_ERR();
39723975
RETURN_NONE();
39733976
}
3977+
#endif
39743978

39753979

39763980
static PyObject*
@@ -4593,7 +4597,9 @@ static PyMethodDef DB_methods[] = {
45934597
{"remove", (PyCFunction)DB_remove, METH_VARARGS|METH_KEYWORDS},
45944598
{"rename", (PyCFunction)DB_rename, METH_VARARGS},
45954599
{"set_bt_minkey", (PyCFunction)DB_set_bt_minkey, METH_VARARGS},
4600+
#if (DBVER >= 33)
45964601
{"set_bt_compare", (PyCFunction)DB_set_bt_compare, METH_VARARGS},
4602+
#endif
45974603
{"set_cachesize", (PyCFunction)DB_set_cachesize, METH_VARARGS},
45984604
#if (DBVER >= 41)
45994605
{"set_encrypt", (PyCFunction)DB_set_encrypt, METH_VARARGS|METH_KEYWORDS},
@@ -4683,7 +4689,9 @@ static PyMethodDef DBEnv_methods[] = {
46834689
{"set_lg_bsize", (PyCFunction)DBEnv_set_lg_bsize, METH_VARARGS},
46844690
{"set_lg_dir", (PyCFunction)DBEnv_set_lg_dir, METH_VARARGS},
46854691
{"set_lg_max", (PyCFunction)DBEnv_set_lg_max, METH_VARARGS},
4692+
#if (DBVER >= 33)
46864693
{"set_lg_regionmax",(PyCFunction)DBEnv_set_lg_regionmax, METH_VARARGS},
4694+
#endif
46874695
{"set_lk_detect", (PyCFunction)DBEnv_set_lk_detect, METH_VARARGS},
46884696
{"set_lk_max", (PyCFunction)DBEnv_set_lk_max, METH_VARARGS},
46894697
#if (DBVER >= 32)

0 commit comments

Comments
 (0)