aboutsummaryrefslogtreecommitdiffstats
path: root/community/py3-tornado/APKBUILD
blob: 129baf60226124fbc4c6c6af30914002d1421b21 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# Maintainer: Michael M <mic@hael.xyz>
pkgname=py3-tornado
_pkgname=tornado
pkgver=6.4
pkgrel=1
pkgdesc="Python3 web framework and asynchronous networking library"
options="!check" # 3 Tests fail by failure to resolve 'localhost'
url="https://www.tornadoweb.org/"
arch="all"
license="Apache-2.0"
depends="python3"
makedepends="python3-dev py3-gpep517 py3-setuptools py3-wheel"
checkdepends="py3-curl py3-mock py3-twisted"
subpackages="$pkgname-pyc"
source="https://files.pythonhosted.org/packages/source/${_pkgname:0:1}/$_pkgname/$_pkgname-$pkgver.tar.gz"
builddir="$srcdir/$_pkgname-$pkgver"

replaces="py-tornado" # Backwards compatibility
provides="py-tornado=$pkgver-r$pkgrel" # Backwards compatibility

export TORNADO_EXTENSION=1

build() {
	gpep517 build-wheel \
		--wheel-dir .dist \
		--output-fd 3 3>&1 >&2
}

check() {
	export PYTHONPATH="$(echo $PWD/build/lib.*)"
	cd build
	python3 -m tornado.test.runtests
}

package() {
	python3 -m installer -d "$pkgdir" .dist/*.whl
	rm -rf "$pkgdir"/usr/lib/python3*/site-packages/$_pkgname/test
}

sha512sums="
c063509d4c385e410c63cccdc1e9c66aa2bb739473667ede56cb801b7379b910c8059dec831d609109f3076222b588b257afd960dffa422d7a872867dcdda7c7  tornado-6.4.tar.gz
"