[arch-commits] Commit in (4 files)

Bruno Pagani archange at archlinux.org
Tue Jul 28 10:19:30 UTC 2020


    Date: Tuesday, July 28, 2020 @ 10:19:29
  Author: archange
Revision: 665640

Initial addition of python-lmdb to [community]

Added:
  python-lmdb/
  python-lmdb/repos/
  python-lmdb/trunk/
  python-lmdb/trunk/PKGBUILD

----------+
 PKGBUILD |   36 ++++++++++++++++++++++++++++++++++++
 1 file changed, 36 insertions(+)

Added: python-lmdb/trunk/PKGBUILD
===================================================================
--- python-lmdb/trunk/PKGBUILD	                        (rev 0)
+++ python-lmdb/trunk/PKGBUILD	2020-07-28 10:19:29 UTC (rev 665640)
@@ -0,0 +1,36 @@
+# Maintainer: Daniel Bermond <dbermond at archlinux.org>
+# Maintainer: Bruno Pagani <archange at archlinux.org>
+
+_pkg=py-lmdb
+pkgname=python-lmdb
+pkgver=0.98
+pkgrel=1
+pkgdesc="Universal Python binding for the LMDB Lightning Database"
+arch=(x86_64)
+url="https://github.com/jnwatson/py-lmdb/"
+license=('custom: OpenLDAP')
+depends=(python python-cffi lmdb)
+makedepends=(python-setuptools)
+checkdepends=(python-pytest)
+source=(${url}/archive/${_pkg}_${pkgver}.tar.gz)
+sha256sums=('6e0cd0fb7f53ae95120272bda0117aaef456f80a356808d7ff6c8aa3228fdd17')
+
+build() {
+  cd ${_pkg}-${_pkg}_${pkgver}
+  LMDB_FORCE_SYSTEM=1 python setup.py build
+}
+
+check() {
+  cd ${_pkg}-${_pkg}_${pkgver}
+  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() {
+  cd ${_pkg}-${_pkg}_${pkgver}
+  LMDB_FORCE_SYSTEM=1 python setup.py install --root="$pkgdir" --skip-build --optimize=1
+  install -Dm644 LICENSE -t "${pkgdir}"/usr/share/licenses/${pkgname}
+}



More information about the arch-commits mailing list