desktop/python-pluggy/PKGBUILD

51 lines
1.2 KiB
Bash
Raw Permalink Normal View History

pkgbase=python-pluggy
pkgname=(python3-pluggy python2-pluggy)
pkgver=0.5.2
pkgrel=1
pkgdesc="Plugin and hook calling mechanisms for python"
arch=('any')
url="https://www.pluggypayments.com/docs/python"
license=('MIT')
makedepends=('python3-setuptools' 'python2-setuptools')
checkdepends=('python3-pytest-runner' 'python2-pytest-runner')
source=("https://pypi.io/packages/source/p/pluggy/pluggy-$pkgver.tar.gz")
sha512sums=('850b1a7b9e55d46d5deb16b8bc71e3f9d6c26b78fe34379b295a9780f3da8abb3c44f524f175d0392b61fc2d36d66d156db3f499a3c1666e2ff3e3c6344153cb')
prepare() {
cp -a pluggy-$pkgver{,-py2}
}
build() {
cd "$srcdir"/pluggy-$pkgver
python3 setup.py build
cd "$srcdir"/pluggy-$pkgver-py2
python2 setup.py build
}
2018-03-12 06:06:51 +08:00
check() {
cd "$srcdir"/pluggy-$pkgver
python3 setup.py pytest
cd "$srcdir"/pluggy-$pkgver-py2
python2 setup.py pytest
}
package_python3-pluggy() {
depends=('python3')
cd pluggy-$pkgver
python3 setup.py install -O1 --root "$pkgdir"
install -Dm644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
}
package_python2-pluggy() {
depends=('python2')
cd pluggy-$pkgver-py2
python2 setup.py install -O1 --root "$pkgdir"
install -Dm644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
}