summarylogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--.SRCINFO26
-rw-r--r--PKGBUILD53
2 files changed, 28 insertions, 51 deletions
diff --git a/.SRCINFO b/.SRCINFO
index 9aa2abba047..8964794af91 100644
--- a/.SRCINFO
+++ b/.SRCINFO
@@ -1,27 +1,17 @@
pkgbase = python-lmdb
pkgdesc = Universal Python binding for the LMDB Lightning Database
- pkgver = 0.94
- pkgrel = 3
- url = https://github.com/dw/py-lmdb/
+ pkgver = 0.98
+ pkgrel = 1
+ url = https://github.com/jnwatson/py-lmdb/
arch = x86_64
- license = custom
- makedepends = python
- makedepends = python2
+ license = custom: OpenLDAP
+ checkdepends = python-pytest
makedepends = python-setuptools
- makedepends = python2-setuptools
- depends = python2
- depends = lmdb
- source = https://github.com/dw/py-lmdb/archive/py-lmdb_0.94.tar.gz
- sha256sums = 68685bbbd3ffe93c71f55b57c00d3704a370c70e04b943e47cbe107ad14a049c
-
-pkgname = python-lmdb
depends = python
depends = python-cffi
depends = lmdb
+ source = https://github.com/jnwatson/py-lmdb/archive/py-lmdb_0.98.tar.gz
+ sha256sums = 6e0cd0fb7f53ae95120272bda0117aaef456f80a356808d7ff6c8aa3228fdd17
-pkgname = python2-lmdb
- pkgdesc = Universal Python2 binding for the LMDB Lightning Database
- depends = python2
- depends = python2-cffi
- depends = lmdb
+pkgname = python-lmdb
diff --git a/PKGBUILD b/PKGBUILD
index 3546ee38050..699d890cd8d 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -1,47 +1,34 @@
-# Maintainer : Daniel Bermond < gmail-com: danielbermond >
+# Maintainer: Daniel Bermond <dbermond@archlinux.org>
-pkgbase=python-lmdb
-pkgname=('python-lmdb' 'python2-lmdb')
-pkgver=0.94
-pkgrel=3
+pkgname=python-lmdb
+pkgver=0.98
+pkgrel=1
pkgdesc='Universal Python binding for the LMDB Lightning Database'
arch=('x86_64')
-url='https://github.com/dw/py-lmdb/'
-license=('custom')
-depends=('python2' 'lmdb')
-makedepends=('python' 'python2' 'python-setuptools' 'python2-setuptools')
-source=("https://github.com/dw/py-lmdb/archive/py-lmdb_${pkgver}.tar.gz")
-sha256sums=('68685bbbd3ffe93c71f55b57c00d3704a370c70e04b943e47cbe107ad14a049c')
-
-prepare() {
- cp -a "py-lmdb-py-lmdb_${pkgver}" "py-lmdb-py-lmdb_${pkgver}-py2"
-}
+url='https://github.com/jnwatson/py-lmdb/'
+license=('custom: OpenLDAP')
+depends=('python' 'python-cffi' 'lmdb')
+makedepends=('python-setuptools')
+checkdepends=('python-pytest')
+source=("https://github.com/jnwatson/py-lmdb/archive/py-lmdb_${pkgver}.tar.gz")
+sha256sums=('6e0cd0fb7f53ae95120272bda0117aaef456f80a356808d7ff6c8aa3228fdd17')
build() {
- printf '%s\n' ' -> Building for Python...'
cd "py-lmdb-py-lmdb_${pkgver}"
LMDB_FORCE_SYSTEM='1' python setup.py build
-
- printf '%s\n' ' -> Building for Python2...'
- cd "${srcdir}/py-lmdb-py-lmdb_${pkgver}-py2"
- LMDB_FORCE_SYSTEM='1' python2 setup.py build
}
-package_python-lmdb() {
- depends=('python' 'python-cffi' 'lmdb')
-
+check() {
cd "py-lmdb-py-lmdb_${pkgver}"
- LMDB_FORCE_SYSTEM='1' python setup.py install --root="$pkgdir" --skip-build --optimize='1'
-
- install -D -m644 LICENSE -t "${pkgdir}/usr/share/licenses/${pkgname}"
+ local _pyver
+ _pyver="$(python -c 'import sys; print("%s.%s" %sys.version_info[0:2])')"
+ export LMDB_FORCE_SYSTEM='1'
+ export PYTHONPATH="$(pwd)/build/lib.linux-${CARCH}-${_pyver}"
+ pytest
}
-package_python2-lmdb() {
- pkgdesc='Universal Python2 binding for the LMDB Lightning Database'
- depends=('python2' 'python2-cffi' 'lmdb')
-
- cd "py-lmdb-py-lmdb_${pkgver}-py2"
- LMDB_FORCE_SYSTEM='1' python2 setup.py install --root="$pkgdir" --skip-build --optimize='1'
-
+package() {
+ cd "py-lmdb-py-lmdb_${pkgver}"
+ LMDB_FORCE_SYSTEM='1' python setup.py install --root="$pkgdir" --skip-build --optimize='1'
install -D -m644 LICENSE -t "${pkgdir}/usr/share/licenses/${pkgname}"
}