Commit Graph

41 Commits

Author SHA1 Message Date
Xin LI
88fe01c61f databases/lmdb: update to 0.9.29. 2021-07-25 23:21:34 -07:00
Mathieu Arnold
305f148f48 Remove # $FreeBSD$ from Makefiles. 2021-04-06 16:31:07 +02:00
Xin LI
26a63eaad4 Update to 0.9.28. 2021-02-10 23:32:49 +00:00
Xin LI
51d887b2f7 databases/lmdb: Add a pkg-config file for use by other software that
expects them.

Submitted by:	Daniel O'Connor <darius dons net au>
2020-09-23 00:32:42 +00:00
Xin LI
6c3f69c928 databases/lmdb: in db_env_close0(), destroy robust mutexes if we are
the only remaining user.

When closing an lmdb database, all memory and file descriptor resources
are released, including the shared memory pages that contained the
robust mutex.

However, before this commit, prior to unmapping the pages that contained
the robust mutexex, lmdb did not destroy the mutexes first.  This would
create a problem when an application opens and closes a database, then
open it again.

According to libthr(3), by default, a shared lock backed by a mapped
file in memory is automatically destroyed on the last unmap of the
corresponding file' page, which is allowed by POSIX.

After unmapping the shared pages, the kernel writes off all active
robust mutexes associated with these pages.  However, the userland
threading library still keeps the record (pshared_lookup in
thr_pshared.c of libthr) for these objects as they are not really
destroyed before, so that it don't have to ask the kernel every
time when looking them up.

Now, a later re-open of the database might have mapped the lock file
to the same memory location.  Because the threading library have
remembered the robust mutex object, it would just reuse it even though
it was already invalid from kernel's point of view.  Unfortunately,
regular lock operations would still work for this process.

Should another lmdb process opens the same database, it would attempt
to obtain the robust mutex (no longer recognized by kernel) because it
would see another process holding a file lock, but that would fail
because the robust mutex is invalid for the kernel.

Explicitly destroy the mutex if we are the last remaining user to ensure
the mutex is always in a known defined state.

OpenLDAP ITS #9278

With debugging help from:	kib
PR:				244493
MFH:				2020Q2
2020-06-16 21:51:55 +00:00
Xin LI
666ee14851 - Drop support of FreeBSD < 11.0
- Make use of robust mutexes.
2019-12-07 22:47:43 +00:00
Xin LI
d5f408361d Update to 0.9.24. 2019-08-06 08:26:25 +00:00
Sunpoet Po-Chuan Hsieh
27ca5a03ae Update WWW
Approved by:	portmgr (blanket)
2019-01-13 20:09:54 +00:00
Xin LI
d7561c1cc8 Update to 0.9.23. 2018-12-30 06:29:34 +00:00
Jan Beich
f9e1b3e8eb databases/lmdb: back out r478269 due to cyrus-imapd30 instability
Robust mutexes were already enabled but r478269 disabled POSIX
semaphores. It appears both are only mutually exclusive on Android and
old GNU libc.

PR:		230564
Reported by:	Volodymyr Kostyrko
Pointy hat to:	jbeich
2018-09-03 12:08:40 +00:00
Jan Beich
855a5b4b58 databases/lmdb: switch to robust mutexes on FreeBSD >= 11
PR:		230564
Approved by:	delphij (maintainer)
2018-08-28 00:01:28 +00:00
Pietro Cerutti
ad9dd8f2f2 databases/lmdb: update to 0.9.22
LMDB 0.9.22 Release (2018-03-22)
  Fix MDB_DUPSORT alignment bug (ITS#8819)
  Fix regression with new db from 0.9.19 (ITS#8760)
  Fix liblmdb to build on Solaris (ITS#8612)
  Fix delete behavior with DUPSORT DB (ITS#8622)
  Fix mdb_cursor_get/mdb_cursor_del behavior (ITS#8722)

PR:		227103
Submitted by:	gahr
Approved by:	delphij (maintainer)
2018-03-30 10:56:11 +00:00
Pietro Cerutti
8341a0ab26 databases/lmdb: use fdatasync where supported
Submitted upstream in http://www.openldap.org/its/index.cgi?findid=8739

PR:		222514
Submitted by:	gahr
Approved by:	delphij (maintainer, via private email)
2017-09-25 09:37:33 +00:00
Xin LI
016125facf Update to 0.9.21. 2017-06-04 08:13:52 +00:00
Pietro Cerutti
d29f043a5b databases/lmdb: remove useless TEST_TARGET
Reported by:	mat
2017-04-25 12:40:50 +00:00
Pietro Cerutti
87bab43e28 databases/lmdb: update to 0.9.19
PR:		218334
Submitted by:	gahr
Approved by:	maintainer timeout
2017-04-25 12:26:34 +00:00
Xin LI
ddaf098cbc Downgrade to 0.9.18 due to regressions. 2017-01-18 17:46:54 +00:00
Xin LI
bed756a22a Update to 0.9.20. 2017-01-12 07:47:40 +00:00
Mathieu Arnold
7427bdad4f Add soname and cleanup
Using soname allows pkg(8) to register the library, and it helps on
upgrades.
Use WRKSRC_SUBDIR
Use MAKE_ARGS instead of MAKE_ENV so the patch can be simplified.

PR:		211700
Submitted by:	mat
Approved by:	delphij (maintainer)
Sponsored by:	Absolight
2016-08-09 21:28:45 +00:00
Xin LI
6e2153a349 Update to 0.9.18.
PR:		ports/208766
Submitted by:	gahr
2016-04-18 08:42:05 +00:00
Xin LI
55cad84404 Update to 0.9.16. 2015-08-21 19:20:19 +00:00
Mathieu Arnold
63d17e75d7 Cleanup some abusive use of GH_TAGNAME.
With hat:	portmgr
Sponsored by:	Absolight
2015-08-04 11:29:18 +00:00
Xin LI
6d3cd0eac4 Update to 0.9.15, move to Github and add LICENSE. 2015-07-02 18:13:48 +00:00
Dmitry Marakasov
178592ab36 - Don't install static libraries with INSTALL_LIB (part 1/2)
Approved by:	portmgr blanket
MFH:		2015Q2
2015-05-08 14:04:50 +00:00
Xin LI
0adc19f9b0 Update to 0.9.14. 2015-04-14 18:00:59 +00:00
John Marino
8f3cf904a9 databases category: Remove $PTHREAD_LIBS
Note: virtuoso did not pass check-plist from before, so it was fixed.

approved by:	PTHREAD blanket
2015-03-25 09:33:52 +00:00
Xin LI
05c273e00b Use local mirror ONLY as gitorious.org keeps rerolling with only timestamp
change and there is no way to workaround that with the current framework.
2014-08-21 08:42:02 +00:00
Xin LI
ca4ce4a1cc Refresh after distfile reroll. No content change detected in source in my
manual inspection, so no PORTREVISION bump.
2014-08-18 05:32:37 +00:00
Antoine Brodin
c1c6f4281a Mark BROKEN: Checksum mismatch
Reported by:	pkg-fallout
2014-08-17 23:00:26 +00:00
Xin LI
3d08c567d6 Update to 0.9.13. 2014-08-09 09:38:54 +00:00
Baptiste Daroussin
4a4ec28d37 Convert all :U to :tu and :L to :tl
Since FreeBSD 8.4 and FreeBSD 9.1 make(1) do support :tu and :tl as a
replacement for :U and :L (which has been marked as deprecated)

bmake which is the default on FreeBSD 10+ only support by default
:tu/:tl a hack has been added at the time to support :U and :L to ease
migration. This hack is now not necessary anymore

Note that this makes the ports tree incompatible with make(1) from
FreeBSD 8.3 or earlier

With hat:	portmgr
2014-05-05 09:45:36 +00:00
Emanuel Haupt
edfd67d861 Support staging 2014-02-20 08:06:18 +00:00
Xin LI
0103c4fd1b Update to 0.9.11 2014-01-15 19:50:34 +00:00
Xin LI
d155ff39a4 Update to 0.9.10. 2013-11-20 20:18:24 +00:00
Xin LI
0d0604a341 Update to 0.9.9. 2013-10-28 03:22:17 +00:00
Baptiste Daroussin
36117d7097 Add NO_STAGE all over the place in preparation for the staging support (cat: databases) 2013-09-20 16:13:47 +00:00
Xin LI
886e61b82c - Update to 0.9.8.
- Override 'do-install' target so we install shared
   library with a version number.
2013-09-09 19:29:00 +00:00
Xin LI
78fb15bbc2 Use local mirror for lmdb distfiles. 2013-09-03 22:27:17 +00:00
Bryan Drewery
b179278458 - Mark BROKEN, fails to fetch 2013-08-31 00:04:51 +00:00
Xin LI
4ee49f4279 Update to 0.9.7. 2013-08-16 18:40:22 +00:00
Xin LI
7214e51437 LMDB is an ultra-fast, ultra-compact key-value data
store developed by Symas for the OpenLDAP Project.

PR:		ports/174007
2013-03-11 23:58:01 +00:00