summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'dev-python/bsddb3')
-rw-r--r--dev-python/bsddb3/Manifest2
-rw-r--r--dev-python/bsddb3/bsddb3-6.0.1.ebuild65
-rw-r--r--dev-python/bsddb3/bsddb3-6.1.0.ebuild74
-rw-r--r--dev-python/bsddb3/metadata.xml8
4 files changed, 149 insertions, 0 deletions
diff --git a/dev-python/bsddb3/Manifest b/dev-python/bsddb3/Manifest
new file mode 100644
index 000000000000..4eb863132f3b
--- /dev/null
+++ b/dev-python/bsddb3/Manifest
@@ -0,0 +1,2 @@
+DIST bsddb3-6.0.1.tar.gz 347002 SHA256 abc34d83d6cbb40f1626ecc2b62e8163ba204f4bb6a65c23b125a171d224bf6d SHA512 14a35a4933f83f11267072956e0061053918974d556899ea7670e2e52f7fbf9cb9f64e1810323b60a63ece0576a6d2b1a2743adf2c06f7f1debba8dcc0f0b8da WHIRLPOOL a4441dd6ba6c2de6bacfe5584395059614087c6b8c01c61290bdba7e2a75d5ee7abed349f7519439828a5dafd48da46c91b98caed1b0fffe16c9201c79af0d71
+DIST bsddb3-6.1.0.tar.gz 340966 SHA256 b13163e3891c32390aea66edcf7880eb245abc89199a766b7b1907fc5c1efd15 SHA512 2c84f8fd8c5bcced843ea7f1f54511cc4845a75ac182b4f832b92800c4f230906bf5919cb7d10938e79272f0fe89a5ed9b3f90c02bf11ac651126e6982dcc0ff WHIRLPOOL b27e1c024705f64eb0cffd0bf87932af4dd9f3eb5bdbce40d2d6a250cd101be55ebf1f76c17ac6c40de9e28e0c84b9bfafd0c62d7c1950782eef8fa1137ebb3b
diff --git a/dev-python/bsddb3/bsddb3-6.0.1.ebuild b/dev-python/bsddb3/bsddb3-6.0.1.ebuild
new file mode 100644
index 000000000000..fdf24ffc0733
--- /dev/null
+++ b/dev-python/bsddb3/bsddb3-6.0.1.ebuild
@@ -0,0 +1,65 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+PYTHON_COMPAT=( python{2_7,3_3,3_4} )
+
+inherit db-use distutils-r1 multilib
+
+DESCRIPTION="Python bindings for Berkeley DB"
+HOMEPAGE="http://www.jcea.es/programacion/pybsddb.htm http://pypi.python.org/pypi/bsddb3"
+SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="alpha amd64 arm hppa ia64 ppc ppc64 sparc x86 ~amd64-linux ~x86-linux"
+IUSE="doc"
+
+RDEPEND=">=sys-libs/db-4.8.30
+ <sys-libs/db-6.1"
+DEPEND="${RDEPEND}
+ dev-python/setuptools[${PYTHON_USEDEP}]"
+
+DISTUTILS_IN_SOURCE_BUILD=1
+
+src_prepare() {
+ # This list should be kept in sync with setup.py.
+ for DB_VER in 6.0 5.3 5.2 5.1 5.0 4.8; do
+ has_version "sys-libs/db:${DB_VER}" && break
+ done
+
+ # Force version.
+ sed -e "s/db_ver = None/db_ver = (${DB_VER%.*}, ${DB_VER#*.})/" \
+ -e "s/dblib = 'db'/dblib = '$(db_libname ${DB_VER})'/" \
+ -i setup2.py setup3.py || die
+
+ # Adjust test.py to look in build/lib.
+ sed -e "s/'lib.%s' % PLAT_SPEC/'lib'/" \
+ -i test2.py test3.py || die
+
+ distutils-r1_src_prepare
+}
+
+src_configure() {
+ # These are needed for both build and install.
+ export BERKELEYDB_DIR="${EPREFIX}/usr"
+ export BERKELEYDB_INCDIR="$(db_includedir)"
+ export BERKELEYDB_LIBDIR="${EPREFIX}/usr/$(get_libdir)"
+}
+
+python_compile() {
+ if ! python_is_python3; then
+ local -x CFLAGS="${CFLAGS} -fno-strict-aliasing"
+ fi
+ distutils-r1_python_compile
+}
+
+python_test() {
+ "${PYTHON}" test.py -v || die "Testing failed with ${EPYTHON}"
+}
+
+python_install_all() {
+ use doc && local HTML_DOCS=( docs/html/. )
+ distutils-r1_python_install_all
+}
diff --git a/dev-python/bsddb3/bsddb3-6.1.0.ebuild b/dev-python/bsddb3/bsddb3-6.1.0.ebuild
new file mode 100644
index 000000000000..54195b180217
--- /dev/null
+++ b/dev-python/bsddb3/bsddb3-6.1.0.ebuild
@@ -0,0 +1,74 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+PYTHON_COMPAT=( python{2_7,3_3,3_4} )
+
+inherit db-use distutils-r1 multilib
+
+DESCRIPTION="Python bindings for Berkeley DB"
+HOMEPAGE="http://www.jcea.es/programacion/pybsddb.htm http://pypi.python.org/pypi/bsddb3"
+SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~amd64-linux ~x86-linux"
+IUSE="doc"
+
+RDEPEND="
+ >=sys-libs/db-4.7
+ <sys-libs/db-6.2:=
+"
+DEPEND="${RDEPEND}
+ dev-python/setuptools[${PYTHON_USEDEP}]"
+
+DISTUTILS_IN_SOURCE_BUILD=1
+
+src_prepare() {
+ # This list should be kept in sync with setup.py.
+ if [[ -z ${DB_VER} ]]; then
+ for DB_VER in 6.1 6.0 5.3 5.2 5.1 5.0 4.8 4.7; do
+ has_version "sys-libs/db:${DB_VER}" && break
+ done
+ fi
+
+ # Force version.
+ sed -e "s/db_ver = None/db_ver = (${DB_VER%.*}, ${DB_VER#*.})/" \
+ -e "s/dblib = 'db'/dblib = '$(db_libname ${DB_VER})'/" \
+ -i setup2.py setup3.py || die
+
+ # Adjust test.py to look in build/lib.
+ sed -e "s/'lib.%s' % PLAT_SPEC/'lib'/" \
+ -i test2.py test3.py || die
+
+ distutils-r1_src_prepare
+}
+
+src_configure() {
+ # These are needed for both build and install.
+ export BERKELEYDB_DIR="${EPREFIX}/usr"
+ export BERKELEYDB_INCDIR="$(db_includedir ${DB_VER})"
+ export BERKELEYDB_LIBDIR="${EPREFIX}/usr/$(get_libdir)"
+ export YES_I_HAVE_THE_RIGHT_TO_USE_THIS_BERKELEY_DB_VERSION=1
+}
+
+python_compile() {
+ if ! python_is_python3; then
+ local -x CFLAGS="${CFLAGS} -fno-strict-aliasing"
+ fi
+ distutils-r1_python_compile
+}
+
+python_test() {
+ if python_is_python3; then
+ PYTHONPATH=Lib3 "${PYTHON}" test3.py -v || die "Testing failed with ${EPYTHON}"
+ else
+ PYTHONPATH=Lib "${PYTHON}" test.py -v || die "Testing failed with ${EPYTHON}"
+ fi
+}
+
+python_install_all() {
+ use doc && local HTML_DOCS=( docs/html/. )
+ distutils-r1_python_install_all
+}
diff --git a/dev-python/bsddb3/metadata.xml b/dev-python/bsddb3/metadata.xml
new file mode 100644
index 000000000000..07d7984e12bb
--- /dev/null
+++ b/dev-python/bsddb3/metadata.xml
@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <herd>python</herd>
+ <upstream>
+ <remote-id type="pypi">bsddb3</remote-id>
+ </upstream>
+</pkgmetadata>