summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: b345bfd49efdf7bca2e5da13e7ff8e40a8cf425f (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
43
44
45
46
47
# Maintainer: Luis Martinez <luis dot martinez at disroot dot org>
# Contributor: Lex Black <autumn-wind at web dot de>
# Contributor: Rhinoceros <https://aur.archlinux.org/account/rhinoceros>

pkgname=python-aioimaplib
_pkg="${pkgname#python-}"
pkgver=0.9.0
pkgrel=3
pkgdesc='Python asyncio IMAP4rev1 client library'
arch=('any')
url='https://github.com/bamthomas/aioimaplib'
license=('GPL3')
depends=('python')
makedepends=('python-build' 'python-installer' 'python-setuptools' 'python-wheel')
checkdepends=(
	'python-asynctest'
	'python-docutils'
	'python-imaplib2' ## AUR
	'python-mock'
	'python-nose'
	'python-pyopenssl'
	'python-pytz'
	'python-twine'
	'python-tzlocal')
source=("$pkgname-$pkgver.tar.gz::$url/archive/$pkgver.tar.gz"
        "python310.patch::$url/compare/0.9.0...21da21f.diff")
sha256sums=('3d4700f019e7a6459a6b88ef5f1ee3441f600554938490405f172313835e2749'
            '43030b610417278c3046eac82a71f8d8e207c13ce81015dedb04ac1df878b46b')

prepare() {
	patch -p1 -d "$_pkg-$pkgver" < python310.patch
}

build() {
	cd "$_pkg-$pkgver"
	python -m build --wheel --no-isolation
}

check() {
	cd "$_pkg-$pkgver"
	nosetests
}

package() {
	cd "$_pkg-$pkgver"
	PYTHONHASHSEED=0 python -m installer --destdir="$pkgdir" dist/*.whl
}