Upstream stopped supporting LTS 1.6.* releases. Let's move to the 2.x branch which only supports LMDB (patched to use MDB_WRITEMAP) and uses __thread (thus, needs clang or lang/gcc). The config format changed a bit, /usr/local/libexec/knot1to2 might help. Most work done by Alexis Vachette, ok fcambus@
18 lines
551 B
Plaintext
18 lines
551 B
Plaintext
$OpenBSD: patch-src_contrib_lmdb_mdb_c,v 1.1 2017/06/01 13:42:01 jca Exp $
|
|
Index: src/contrib/lmdb/mdb.c
|
|
--- src/contrib/lmdb/mdb.c.orig
|
|
+++ src/contrib/lmdb/mdb.c
|
|
@@ -4921,6 +4921,12 @@ mdb_env_open(MDB_env *env, const char *path, unsigned
|
|
if (env->me_fd!=INVALID_HANDLE_VALUE || (flags & ~(CHANGEABLE|CHANGELESS)))
|
|
return EINVAL;
|
|
|
|
+ /*
|
|
+ * Always force MDB_WRITEMAP, the code does the right thing if
|
|
+ * asking for a read-only handle.
|
|
+ */
|
|
+ flags |= MDB_WRITEMAP;
|
|
+
|
|
flags |= env->me_flags;
|
|
|
|
rc = mdb_fname_init(path, flags, &fname);
|