[arch-commits] Commit in python-pycontracts/repos (2 files)
Felix Yan
felixonmars at archlinux.org
Sat Oct 26 20:49:44 UTC 2019
Date: Saturday, October 26, 2019 @ 20:49:44
Author: felixonmars
Revision: 520628
archrelease: copy trunk to community-staging-any
Added:
python-pycontracts/repos/community-staging-any/
python-pycontracts/repos/community-staging-any/PKGBUILD
(from rev 520623, python-pycontracts/trunk/PKGBUILD)
----------+
PKGBUILD | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 51 insertions(+)
Copied: python-pycontracts/repos/community-staging-any/PKGBUILD (from rev 520623, python-pycontracts/trunk/PKGBUILD)
===================================================================
--- community-staging-any/PKGBUILD (rev 0)
+++ community-staging-any/PKGBUILD 2019-10-26 20:49:44 UTC (rev 520628)
@@ -0,0 +1,51 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+pkgbase=python-pycontracts
+pkgname=(python-pycontracts python2-pycontracts)
+pkgver=1.8.12
+pkgrel=2
+pkgdesc='Declare constraints on function parameters and return values'
+arch=('any')
+url="https://andreacensi.github.io/contracts"
+license=('GPL')
+makedepends=('python-setuptools' 'python2-setuptools' 'python-pyparsing' 'python2-pyparsing'
+ 'python-decorator' 'python2-decorator' 'python-six' 'python2-six' 'python-future'
+ 'python2-future')
+checkdepends=('python-nose' 'python2-nose')
+source=("https://pypi.io/packages/source/P/PyContracts/PyContracts-$pkgver.tar.gz")
+sha512sums=('9abd5ab5203687ddd8a738998e63e8f3e397b9ba9b9ee22bda945dab4f0d460115ed8e825c9c551d4c067b0f39dbb5b8ca51d365623b10ee8e210efc4edcbf15')
+
+prepare() {
+ cp -a PyContracts-$pkgver{,-py2}
+}
+
+build() {
+ cd "$srcdir"/PyContracts-$pkgver
+ python setup.py build
+
+ cd "$srcdir"/PyContracts-$pkgver-py2
+ python2 setup.py build
+}
+
+check() {
+ cd "$srcdir"/PyContracts-$pkgver
+ python setup.py nosetests
+
+ cd "$srcdir"/PyContracts-$pkgver-py2
+ rm -r src/contracts-py3k-test
+ python2 setup.py nosetests
+}
+
+package_python-pycontracts() {
+ depends=('python-pyparsing' 'python-decorator' 'python-six' 'python-future')
+
+ cd PyContracts-$pkgver
+ python setup.py install --root="$pkgdir" --optimize=1
+}
+
+package_python2-pycontracts() {
+ depends=('python2-pyparsing' 'python2-decorator' 'python2-six' 'python2-future')
+
+ cd PyContracts-$pkgver-py2
+ python2 setup.py install --root="$pkgdir" --optimize=1
+}
More information about the arch-commits
mailing list