Date: Friday, February 23, 2018 @ 16:36:10
  Author: anthraxx
Revision: 297234

upgpkg: python-scrypt 0.8.6-4

Modified:
  python-scrypt/trunk/PKGBUILD

----------+
 PKGBUILD |   61 ++++++++++++++++++++++++++++++++++++++++++++++---------------
 1 file changed, 46 insertions(+), 15 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD    2018-02-23 16:13:48 UTC (rev 297233)
+++ PKGBUILD    2018-02-23 16:36:10 UTC (rev 297234)
@@ -1,24 +1,55 @@
-# Maintainer: Daniel Micay <danielmi...@gmail.com>
-pkgname=(python-scrypt python2-scrypt)
-pkgver=0.8.0
-pkgrel=3
+# Maintainer: Levente Polyak <anthraxx[at]archlinux[dot]org>
+# Contributor: Daniel Micay <danielmi...@gmail.com>
+
+pkgname=('python-scrypt' 'python2-scrypt')
+pkgver=0.8.6
+pkgrel=4
 pkgdesc='Bindings for the scrypt key derivation function library'
-arch=(x86_64)
+arch=('x86_64')
 url='https://pypi.python.org/pypi/scrypt/'
 license=('BSD')
-makedepends=(python-setuptools python2-setuptools)
-options=(!emptydirs)
-source=("https://pypi.org/packages/source/s/scrypt/scrypt-$pkgver.tar.gz";)
-md5sums=('0704e59cc3afb3845c27bb3827baeea9')
+makedepends=('python-setuptools' 'python2-setuptools')
+options=('!emptydirs')
+source=(https://pypi.python.org/packages/source/s/scrypt/scrypt-${pkgver}.tar.gz)
+sha512sums=('f0f3bd61a5fcb55a1d6af5b7062202446c2c0595e88617f1e53c4ded6a9b1ab857fda9e8d153c0b3bbceee49a818dd428776522c6b0919b15096fd230b13ef60')
 
+prepare() {
+  cp -a scrypt-${pkgver}{,-py2}
+  sed 's|env python$|env python2|' -i scrypt-${pkgver}-py2/scrypt/scrypt.py
+}
+
+build() {
+  (cd scrypt-${pkgver}
+    python setup.py build
+  )
+  (cd scrypt-${pkgver}-py2
+    python2 setup.py build
+  )
+}
+
+check() {
+  (cd scrypt-${pkgver}
+    python setup.py test
+  )
+  (cd scrypt-${pkgver}-py2
+    python2 setup.py test
+  )
+}
+
 package_python-scrypt() {
-  depends=(python)
-  cd "scrypt-$pkgver"
-  python3 setup.py install --root="$pkgdir/" --optimize=1
+  depends=('python' 'glibc')
+  cd scrypt-${pkgver}
+  python setup.py install --root="${pkgdir}" -O1 --skip-build
+  install -Dm 644 README.rst -t "${pkgdir}/usr/share/doc/${pkgname}"
+  install -Dm 644 LICENSE -t "${pkgdir}/usr/share/licenses/${pkgname}"
 }
 
 package_python2-scrypt() {
-  depends=(python2)
-  cd "scrypt-$pkgver"
-  python2 setup.py install --root="$pkgdir/" --optimize=1
+  depends=('python2' 'glibc')
+  cd scrypt-${pkgver}-py2
+  python2 setup.py install --root="${pkgdir}" -O1 --skip-build
+  install -Dm 644 README.rst -t "${pkgdir}/usr/share/doc/${pkgname}"
+  install -Dm 644 LICENSE -t "${pkgdir}/usr/share/licenses/${pkgname}"
 }
+
+# vim: ts=2 sw=2 et:

Reply via email to