1 # Maintainer: Felix Yan <felixonmars@archlinux.org>
2 # Contributor: Ionut Biru <ibiru@archlinux.org>
3 # Contributor: Juergen Hoetzel <juergen@archlinux.org>
4 # Contributor: Douglas Soares de Andrade <douglas@archlinux.org>
9 pkgdesc="Asynchronous networking framework written in Python"
11 url="https://twistedmatrix.com/"
13 depends=('python-zope-interface' 'python-constantly' 'python-incremental' 'python-automat'
14 'python-hyperlink' 'python-attrs' 'python-typing_extensions')
15 makedepends=('python-setuptools')
16 optdepends=('python-pyopenssl: for TLS client hostname verification'
17 'python-service-identity: for TLS client hostname verification'
18 'python-idna: for TLS client hostname verification'
19 'python-cryptography: for using conch'
20 'python-pyasn1: for using conch'
21 'python-appdirs: for using conch'
22 'python-bcrypt: for using conch'
23 'python-h2: for http2 support'
24 'python-priority: for http2 support'
25 'python-pyserial: for serial support'
26 'tk: for using tkconch')
27 checkdepends=('python-pyhamcrest' 'subversion' 'xorg-server-xvfb' 'tk' 'openssh' 'git' 'gtk3'
28 'python-gobject' 'python-subunit' 'python-h2' 'python-priority' 'python-cryptography'
29 'python-idna' 'python-pyasn1' 'python-pyserial' 'python-bcrypt'
30 'python-cython-test-exception-raiser' 'python-pyopenssl' 'python-service-identity')
31 # Conflicts with the command line tools used to be provided by the python2 package.
32 conflicts=("python2-twisted<=20.3.0-3")
33 source=("https://github.com/twisted/twisted/archive/twisted-$pkgver.tar.gz")
34 sha512sums=('890a11ca55fd88636f404678c6fad3fcea9d0604b1b37681a4b92ea74952bc4d1b96a571dde39a4aa82d966121156801f6b42dbd0bb5a309503591a7a77c6d71')
37 cd twisted-twisted-$pkgver
42 export LC_CTYPE=en_US.UTF-8
44 # tests use the underlying function from the 'python -m twisted.trial' module, to prevent loading system entry points
45 PYTHONPATH="$srcdir/twisted-twisted-$pkgver/build/lib" xvfb-run python -c 'from twisted.scripts.trial import run; run()' twisted || echo "Tests failed"
49 cd twisted-twisted-$pkgver
50 python setup.py install --prefix=/usr --root="$pkgdir" --optimize=1
51 install -Dm644 LICENSE -t "$pkgdir"/usr/share/licenses/$pkgname/