Commit a554e07
committed
Use POSIX mutexes for LMDB on macOS
Darwin's default System V semaphore backend fails with EINVAL once a
process holds locks on more than kern.sysv.semume (=10) semaphore sets
concurrently, breaking workloads that open multiple DB environments in
one process (e.g. the storage-lmdb test suite).
Compile lmdb with MDB_USE_POSIX_MUTEX=1 on Apple targets via target-
scoped CFLAGS in .cargo/config.toml; MDB_USE_ROBUST must be disabled
because Darwin does not implement robust mutexes. Linux builds keep
upstream defaults.1 parent be919bf commit a554e07
1 file changed
Lines changed: 15 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
0 commit comments