forked from gentoo/gentoo
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
dev-db/lmdb: version bump, adds support for Solaris
Package-Manager: portage-2.3.0
- Loading branch information
Showing
2 changed files
with
53 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
DIST LMDB_0.9.18.tar.gz 139156 SHA256 dd35b471d6eea84f48f2feece13d121abf59ef255308b8624a36223ffbdf9989 SHA512 394e88d99d446eb30771d7cf7a661584683a0d6d8e976cc561b5eecbb2a5d0817bbd59994002afa4eae6c86a39f05f50ebc2eff77cd70dd8c67225df4611f5e6 WHIRLPOOL 067fdb080edfc338885358c5cfef39a6ca9cdab8f49fd0f62bc68005e1f7dac9cd69fc87d130cf19f818906d090b906ea8b9716440358f33982e96e91ae4c049 | ||
DIST LMDB_0.9.19.tar.gz 143141 SHA256 108532fb94c6f227558d45be3f3347b52539f0f58290a7bb31ec06c462d05326 SHA512 1d9825f09592ad92a540a1dec232cf6649f41cc67b0d59dc8958a71f4090f347c84995f32a166e2c2efecb862981f455814dd07af99bc3489e42fe3fd8bc6191 WHIRLPOOL 968546a1ba458c9686353a4f497c070fd2f01087de68e91d92ae98aae9e371871d90a03645cd35d40208d670bfe5113144038739db8b53f5a9b7ec1b5ec13b75 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
# Copyright 1999-2017 Gentoo Foundation | ||
# Distributed under the terms of the GNU General Public License v2 | ||
# $Id$ | ||
|
||
EAPI=6 | ||
inherit toolchain-funcs flag-o-matic | ||
|
||
DESCRIPTION="An ultra-fast, ultra-compact key-value embedded data store" | ||
HOMEPAGE="http://symas.com/mdb/" | ||
SRC_URI="https://github.com/LMDB/lmdb/archive/LMDB_${PV}.tar.gz" | ||
|
||
LICENSE="OPENLDAP" | ||
SLOT="0/${PV}" | ||
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~sh ~sparc ~x86 ~ppc-aix ~amd64-fbsd ~sparc-fbsd ~x86-fbsd ~x86-freebsd ~amd64-linux ~x86-linux ~x64-solaris ~x86-solaris" | ||
IUSE="static-libs" | ||
|
||
DEPEND="" | ||
# =net-nds/openldap-2.4.40 installs lmdb files. | ||
RDEPEND="!=net-nds/openldap-2.4.40" | ||
|
||
S="${WORKDIR}/${PN}-LMDB_${PV}/libraries/liblmdb" | ||
|
||
src_prepare() { | ||
sed -i -e "s!^CC.*!CC = $(tc-getCC)!" \ | ||
-e "s!^CFLAGS.*!CFLAGS = ${CFLAGS}!" \ | ||
-e "s!^AR.*!AR = $(tc-getAR)!" \ | ||
-e "/^prefix/s!/usr/local!${EPREFIX}/usr!" \ | ||
-e "/^libdir/s!lib\$!$(get_libdir)!" \ | ||
-e "s!shared!shared -Wl,-soname,liblmdb.so.0!" \ | ||
"${S}/Makefile" || die | ||
eapply_user | ||
} | ||
|
||
src_configure() { | ||
if [[ ${CHOST} == *-solaris* ]] ; then | ||
# ensure sigwait has a second sig argument | ||
append-cppflags -D_POSIX_PTHREAD_SEMANTICS | ||
fi | ||
} | ||
|
||
src_compile() { | ||
emake LDLIBS+=" -pthread" | ||
} | ||
|
||
src_install() { | ||
emake DESTDIR="${D}" install | ||
|
||
mv "${ED}"usr/$(get_libdir)/liblmdb.so{,.0} || die | ||
dosym liblmdb.so.0 /usr/$(get_libdir)/liblmdb.so | ||
|
||
use static-libs || rm "${ED}"usr/$(get_libdir)/liblmdb.a || die | ||
} |