[arch-commits] Commit in python-coverage/repos (2 files)
Felix Yan
felixonmars at archlinux.org
Fri Oct 25 16:35:32 UTC 2019
Date: Friday, October 25, 2019 @ 16:35:32
Author: felixonmars
Revision: 519479
archrelease: copy trunk to community-staging-x86_64
Added:
python-coverage/repos/community-staging-x86_64/
python-coverage/repos/community-staging-x86_64/PKGBUILD
(from rev 519478, python-coverage/trunk/PKGBUILD)
----------+
PKGBUILD | 71 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 71 insertions(+)
Copied: python-coverage/repos/community-staging-x86_64/PKGBUILD (from rev 519478, python-coverage/trunk/PKGBUILD)
===================================================================
--- community-staging-x86_64/PKGBUILD (rev 0)
+++ community-staging-x86_64/PKGBUILD 2019-10-25 16:35:32 UTC (rev 519479)
@@ -0,0 +1,71 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+# Contributor: Clément Démoulins <clement at archivel.fr>
+# Contributor: Fazlul Shahriar <fshahriar at gmail.com>
+
+pkgbase=python-coverage
+pkgname=(python-coverage python2-coverage)
+pkgver=4.5.4
+pkgrel=2
+pkgdesc="A tool for measuring code coverage of Python programs"
+arch=('x86_64')
+url="https://nedbatchelder.com/code/coverage/"
+license=('Apache')
+makedepends=('python-setuptools' 'python2-setuptools')
+checkdepends=('python-mock' 'python2-mock' 'python-pytest-xdist' 'python2-pytest-xdist'
+ 'python-pycontracts' 'python2-pycontracts' 'python-greenlet' 'python2-greenlet'
+ 'python-virtualenv' 'python2-virtualenv' 'python-pyenchant' 'python2-pyenchant'
+ 'python-pylint' 'python2-pylint' 'python-unittest-mixins' 'python2-unittest-mixins'
+ 'python-flaky' 'python2-flaky')
+source=("$pkgbase-$pkgver.tar.gz::https://github.com/nedbat/coveragepy/archive/coverage-$pkgver.tar.gz")
+sha512sums=('4d7530607fbee436fb9ccb2f916175045ce8a2199d7ff09b5e9457cb2c6fc9c64f0f2d045176c38d528c0a80c0f7ba59f620158b25a4dac6aa18837178daaab3')
+
+prepare() {
+ mv coveragepy-coverage-$pkgver coveragepy-$pkgver
+ cp -a coveragepy-$pkgver{,-py2}
+}
+
+check() {
+ # Hack entry points by installing it
+
+ export LC_CTYPE=en_US.UTF-8
+
+ (
+ cd "$srcdir/coveragepy-$pkgver"
+ virtualenv "$srcdir/pyvenv" --system-site-packages
+ . "$srcdir/pyvenv/bin/activate"
+ export PYTHONPATH="$PYTHONPATH:/usr/lib/python3.8/site-packages"
+ python setup.py --quiet develop
+ python igor.py zip_mods install_egg remove_extension
+ python igor.py test_with_tracer py
+ python setup.py --quiet build_ext --inplace
+ python igor.py test_with_tracer c
+ ) || warning "Python 3 tests failed"
+
+ (
+ cd "$srcdir/coveragepy-$pkgver-py2"
+ virtualenv2 "$srcdir/pyvenv-py2" --system-site-packages
+ . "$srcdir/pyvenv-py2/bin/activate"
+ export PYTHONPATH="$PYTHONPATH:/usr/lib/python2.7/site-packages"
+ python setup.py --quiet develop
+ python igor.py zip_mods install_egg remove_extension
+ python igor.py test_with_tracer py
+ python setup.py --quiet build_ext --inplace
+ python igor.py test_with_tracer c
+ ) || warning "Python 2 tests failed"
+}
+
+package_python-coverage() {
+ depends=('python')
+
+ cd coveragepy-$pkgver
+ python3 setup.py install --root="$pkgdir" --optimize=1
+}
+
+package_python2-coverage() {
+ depends=('python2')
+
+ cd coveragepy-$pkgver
+ python2 setup.py install --root="$pkgdir" --optimize=1
+
+ mv "$pkgdir/usr/bin/coverage" "$pkgdir/usr/bin/coverage2"
+}
More information about the arch-commits
mailing list