[arch-commits] Commit in python-pytest-benchmark/repos (2 files)
Felix Yan
felixonmars at archlinux.org
Sat Oct 26 20:29:47 UTC 2019
Date: Saturday, October 26, 2019 @ 20:29:46
Author: felixonmars
Revision: 520567
archrelease: copy trunk to community-staging-any
Added:
python-pytest-benchmark/repos/community-staging-any/
python-pytest-benchmark/repos/community-staging-any/PKGBUILD
(from rev 520566, python-pytest-benchmark/trunk/PKGBUILD)
----------+
PKGBUILD | 64 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 64 insertions(+)
Copied: python-pytest-benchmark/repos/community-staging-any/PKGBUILD (from rev 520566, python-pytest-benchmark/trunk/PKGBUILD)
===================================================================
--- community-staging-any/PKGBUILD (rev 0)
+++ community-staging-any/PKGBUILD 2019-10-26 20:29:46 UTC (rev 520567)
@@ -0,0 +1,64 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+pkgbase=python-pytest-benchmark
+pkgname=('python-pytest-benchmark' 'python2-pytest-benchmark')
+pkgver=3.2.2
+pkgrel=2
+pkgdesc='A py.test fixture for benchmarking code'
+arch=('any')
+license=('BSD')
+url='https://github.com/ionelmc/pytest-benchmark'
+makedepends=('python-pytest' 'python2-pytest' 'python2-statistics' 'python2-pathlib'
+ 'python-py-cpuinfo' 'python2-py-cpuinfo')
+checkdepends=('python-pytest-cov' 'python2-pytest-cov' 'python-pygal' 'python2-pygal'
+ 'python-freezegun' 'python2-freezegun' 'mercurial' 'python-aspectlib'
+ 'python2-aspectlib' 'python-pytest-xdist' 'python2-pytest-xdist'
+ 'python-pytest-runner' 'python2-pytest-runner' 'python-elasticsearch'
+ 'python2-elasticsearch' 'python2-mock' 'git')
+source=("$pkgbase-$pkgver.tar.gz::https://github.com/ionelmc/pytest-benchmark/archive/v$pkgver.tar.gz")
+sha512sums=('ab9f6f6a6c40a8c5e563c58ac92d9f111e99e6e676d4c34809a702b08eb6bde20b7857895804a767a3f0e86ca89d192cb710e335efcb5d99e6bbad0868e3493a')
+
+prepare() {
+ cp -a pytest-benchmark-$pkgver{,-py2}
+}
+
+build() {
+ cd "$srcdir"/pytest-benchmark-$pkgver
+ python setup.py build
+
+ cd "$srcdir"/pytest-benchmark-$pkgver-py2
+ python2 setup.py build
+}
+
+check() {
+ # Hack entry points by installing it
+
+ cd "$srcdir"/pytest-benchmark-$pkgver
+ python setup.py install --root="$PWD/tmp_install" --optimize=1
+ PYTHONPATH="$PWD/tmp_install/usr/lib/python3.8/site-packages:$PYTHONPATH" PATH="$PWD/tmp_install/usr/bin:$PATH" python setup.py pytest --addopts="tests"
+
+ cd "$srcdir"/pytest-benchmark-$pkgver-py2
+ python2 setup.py install --root="$PWD/tmp_install" --optimize=1
+ PYTHONPATH="$PWD/tmp_install/usr/lib/python2.7/site-packages:$PYTHONPATH" PATH="$PWD/tmp_install/usr/bin:$PATH" python2 setup.py pytest --addopts="tests"
+}
+
+package_python-pytest-benchmark() {
+ depends=('python-pytest' 'python-py-cpuinfo')
+
+ cd "$srcdir"/pytest-benchmark-$pkgver
+ python setup.py install --root="$pkgdir"/ --optimize=1
+ install -D -m644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
+}
+
+package_python2-pytest-benchmark() {
+ depends=('python2-pytest' 'python2-py-cpuinfo' 'python2-statistics' 'python2-pathlib')
+
+ cd "$srcdir"/pytest-benchmark-$pkgver-py2
+ python2 setup.py install --root="$pkgdir"/ --optimize=1
+ install -D -m644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
+
+ mv "$pkgdir"/usr/bin/pytest-benchmark{,2}
+ mv "$pkgdir"/usr/bin/py.test-benchmark{,2}
+}
+
+# vim:set ts=2 sw=2 et:
More information about the arch-commits
mailing list