summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2024-07-21 02:10:54 +0100
committerSam James <sam@gentoo.org>2024-07-21 02:10:54 +0100
commit0eb4e39e25ff997a71d5447f2f3a70ce774202a7 (patch)
tree73d657936eecfb5c057b61dd40a7e49c9b62dcdb /dev-db/lmdb
parentsys-apps/openrc-navi: update DESCRIPTION, HOMEPAGE (diff)
downloadgentoo-0eb4e39e25ff997a71d5447f2f3a70ce774202a7.tar.gz
gentoo-0eb4e39e25ff997a71d5447f2f3a70ce774202a7.tar.bz2
gentoo-0eb4e39e25ff997a71d5447f2f3a70ce774202a7.zip
dev-db/lmdb: add 0.9.33
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'dev-db/lmdb')
-rw-r--r--dev-db/lmdb/Manifest1
-rw-r--r--dev-db/lmdb/lmdb-0.9.33.ebuild66
2 files changed, 67 insertions, 0 deletions
diff --git a/dev-db/lmdb/Manifest b/dev-db/lmdb/Manifest
index 3de8f185e0a8..f1d02b78dde9 100644
--- a/dev-db/lmdb/Manifest
+++ b/dev-db/lmdb/Manifest
@@ -1,2 +1,3 @@
DIST openldap-LMDB_0.9.31.tar.gz 145086 BLAKE2B 8df437c27cb9d40b71a8e9f516c503676dade2342c9d618dcfff6081bf0034f67d1216a6a25a364e7dacd588acb2e254b98486efade12307fa3ad7977be5ed54 SHA512 318aa89b7e39f98f636dba01620f866ddc255d81a2d4def8a9d9fdd80878608db1ac7b60bde58e954aba802d94df42786a9cd00d0c7e11646f09fd5d64821ac4
DIST openldap-LMDB_0.9.32.tar.gz 149188 BLAKE2B 8c15585a10644b791e54d3344c91ad1d86da0af06b02361685ec365309c8188dfd253d7a10f8708cd7f22363f99cc71aaaa170cc3349183f06d0765216cc19ef SHA512 3b8d45085f7a679e27f4b1d8b0a62531d4897d27c2a17f424462da07bd88f6c8fe8d64f866203c9e301b353dff1036fc48d9801917e97cfe7d3fd28f2d918d7a
+DIST openldap-LMDB_0.9.33.tar.gz 149281 BLAKE2B 0750f392fdcb2fd6459943d3d8e8268a6210b25559c882c7705349ad6f68b9dfd71636d01c06b2101fe6aea8deeb21534c3aa06aeeac1a0e925fd4d0d9ef41ca SHA512 57404b35adb5136fcdf60552c2dd2626b9753868f2707d3279725e08145cee3be0d311189b2c6ef6879f25cf09962e6b423c70c8a2e09ef1b368948e873d92b5
diff --git a/dev-db/lmdb/lmdb-0.9.33.ebuild b/dev-db/lmdb/lmdb-0.9.33.ebuild
new file mode 100644
index 000000000000..192658950b08
--- /dev/null
+++ b/dev-db/lmdb/lmdb-0.9.33.ebuild
@@ -0,0 +1,66 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+inherit flag-o-matic multilib multilib-minimal toolchain-funcs
+
+MY_P="${PN^^}_${PV}"
+
+DESCRIPTION="An ultra-fast, ultra-compact key-value embedded data store"
+HOMEPAGE="https://symas.com/lmdb/technical/"
+SRC_URI="https://git.openldap.org/openldap/openldap/-/archive/${MY_P}/openldap-${MY_P}.tar.gz"
+S="${WORKDIR}/openldap-${MY_P}/libraries/liblmdb"
+
+LICENSE="OPENLDAP"
+SLOT="0/${PV}"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~m68k ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~arm64-macos ~ppc-macos ~x64-macos ~x64-solaris"
+IUSE="static-libs"
+
+src_prepare() {
+ default
+ if [[ ${CHOST} == *-darwin* && ${CHOST#*-darwin} -lt 10 ]] ; then
+ # posix_memalign isn't available before 10.6, but on OSX
+ # malloc is always aligned for any addressable type
+ sed -i -e '/(__APPLE__)/a#define HAVE_MEMALIGN 1\n#define memalign(X,Y) malloc(X)' mdb.c || die
+ fi
+ multilib_copy_sources
+}
+
+multilib_src_configure() {
+ local soname="-Wl,-soname,liblmdb$(get_libname 0)"
+ if [[ ${CHOST} == *-darwin* ]] ; then
+ soname="-dynamiclib -install_name ${EPREFIX}/usr/$(get_libdir)/liblmdb$(get_libname 0)"
+ replace-flags -O[123456789] -O1
+ fi
+ sed -i -e "s!^CC.*!CC = $(tc-getCC)!" \
+ -e "s!^CFLAGS.*!CFLAGS = ${CFLAGS}!" \
+ -e "s!^AR.*!AR = $(tc-getAR)!" \
+ -e "s!^SOEXT.*!SOEXT = $(get_libname)!" \
+ -e "/^prefix/s!/usr/local!${EPREFIX}/usr!" \
+ -e "/^libdir/s!lib\$!$(get_libdir)!" \
+ -e "s!shared!shared ${soname}!" \
+ "Makefile" || die
+}
+
+multilib_src_compile() {
+ emake LDLIBS+=" -pthread"
+}
+
+multilib_src_install() {
+ emake DESTDIR="${D}" install
+
+ mv "${ED}"/usr/$(get_libdir)/liblmdb$(get_libname) \
+ "${ED}"/usr/$(get_libdir)/liblmdb$(get_libname 0) || die
+ dosym liblmdb$(get_libname 0) /usr/$(get_libdir)/liblmdb$(get_libname)
+
+ insinto /usr/$(get_libdir)/pkgconfig
+ doins "${FILESDIR}/lmdb.pc"
+ sed -i -e "s!@PACKAGE_VERSION@!${PV}!" \
+ -e "s!@prefix@!${EPREFIX}/usr!g" \
+ -e "s!@libdir@!$(get_libdir)!" \
+ "${ED}"/usr/$(get_libdir)/pkgconfig/lmdb.pc || die
+
+ if ! use static-libs; then
+ rm "${ED}"/usr/$(get_libdir)/liblmdb.a || die
+ fi
+}