[arch-commits] Commit in python-txaio/repos (2 files)
Felix Yan
felixonmars at archlinux.org
Fri Oct 25 15:24:47 UTC 2019
Date: Friday, October 25, 2019 @ 15:24:46
Author: felixonmars
Revision: 519016
archrelease: copy trunk to community-staging-any
Added:
python-txaio/repos/community-staging-any/
python-txaio/repos/community-staging-any/PKGBUILD
(from rev 519013, python-txaio/trunk/PKGBUILD)
----------+
PKGBUILD | 58 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 58 insertions(+)
Copied: python-txaio/repos/community-staging-any/PKGBUILD (from rev 519013, python-txaio/trunk/PKGBUILD)
===================================================================
--- community-staging-any/PKGBUILD (rev 0)
+++ community-staging-any/PKGBUILD 2019-10-25 15:24:46 UTC (rev 519016)
@@ -0,0 +1,58 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+# Contributor: Anatol Pomozov
+
+pkgbase=python-txaio
+pkgname=(python-txaio python2-txaio)
+pkgver=18.8.1
+pkgrel=2
+pkgdesc='Compatibility API between asyncio/Twisted/Trollius'
+arch=('any')
+url="https://github.com/crossbario/txaio"
+license=('MIT')
+makedepends=('python-setuptools' 'python2-setuptools')
+checkdepends=('python-pytest' 'python-mock' 'python-twisted' 'python2-pytest' 'python2-mock' 'python2-twisted')
+source=("https://pypi.io/packages/source/t/txaio/txaio-$pkgver.tar.gz")
+sha512sums=('5aa0024b32211534b0c673da13b092ba08e15195b3b016bc21104618605d5c0b49096fa2795e13d9d5c4247defa1d72f903cbcc8d00a21359825224faab64b64')
+
+prepare() {
+ # This tests whether pip can install the sdist, and is completely broken
+ # except in their boutique setup. They won't fix it.
+ # https://github.com/crossbario/txaio/issues/77#issuecomment-246276723
+ rm txaio-$pkgver/test/test_packaging.py
+ cp -a txaio-$pkgver{,-py2}
+
+ # Fix tests on Python 3.7 (https://github.com/crossbario/txaio/issues/134)
+ sed -i 's/asyncio\.test_utils/test.test_asyncio.utils/' txaio-$pkgver/test/*.py
+}
+
+build() {
+ cd "$srcdir"/txaio-$pkgver
+ python setup.py build
+
+ cd "$srcdir"/txaio-$pkgver-py2
+ python2 setup.py build
+}
+
+check() {
+ cd "$srcdir"/txaio-$pkgver
+ python -m pytest
+
+ cd "$srcdir"/txaio-$pkgver-py2
+ python2 -m pytest
+}
+
+package_python-txaio() {
+ depends=('python-six')
+
+ cd txaio-$pkgver
+ python setup.py install --root="$pkgdir" --optimize=1
+ install -Dm644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
+}
+
+package_python2-txaio() {
+ depends=('python2-six')
+
+ cd txaio-$pkgver-py2
+ python2 setup.py install --root="$pkgdir" --optimize=1
+ install -Dm644 LICENSE "$pkgdir"/usr/share/licenses/$pkgname/LICENSE
+}
More information about the arch-commits
mailing list