diff options
author | Luis Martinez | 2022-07-03 17:59:09 -0500 |
---|---|---|
committer | Luis Martinez | 2022-07-03 17:59:09 -0500 |
commit | 130477b7380f8c7d920b9055cb764818e9a19cfc (patch) | |
tree | 1781dcbc3390020a6d074067fd5d301ebf4cce54 | |
parent | 18ec454a4d73adbab44be526e7c24c80df9a62ae (diff) | |
download | aur-130477b7380f8c7d920b9055cb764818e9a19cfc.tar.gz |
patch for python310 compatibility
-rw-r--r-- | .SRCINFO | 10 | ||||
-rw-r--r-- | PKGBUILD | 29 |
2 files changed, 25 insertions, 14 deletions
@@ -1,7 +1,7 @@ pkgbase = python-aioimaplib pkgdesc = Python asyncio IMAP4rev1 client library pkgver = 0.9.0 - pkgrel = 2 + pkgrel = 3 url = https://github.com/bamthomas/aioimaplib arch = any license = GPL3 @@ -14,10 +14,14 @@ pkgbase = python-aioimaplib checkdepends = python-pytz checkdepends = python-twine checkdepends = python-tzlocal + makedepends = python-build + makedepends = python-installer makedepends = python-setuptools - depends = python>=3.5 - depends = python3 + makedepends = python-wheel + depends = python source = python-aioimaplib-0.9.0.tar.gz::https://github.com/bamthomas/aioimaplib/archive/0.9.0.tar.gz + source = python310.patch::https://github.com/bamthomas/aioimaplib/compare/0.9.0...21da21f.diff sha256sums = 3d4700f019e7a6459a6b88ef5f1ee3441f600554938490405f172313835e2749 + sha256sums = 43030b610417278c3046eac82a71f8d8e207c13ce81015dedb04ac1df878b46b pkgname = python-aioimaplib @@ -3,14 +3,15 @@ # Contributor: Rhinoceros <https://aur.archlinux.org/account/rhinoceros> pkgname=python-aioimaplib +_pkg="${pkgname#python-}" pkgver=0.9.0 -pkgrel=2 +pkgrel=3 pkgdesc='Python asyncio IMAP4rev1 client library' arch=('any') url='https://github.com/bamthomas/aioimaplib' license=('GPL3') -depends=('python>=3.5' 'python3') -makedepends=('python-setuptools') +depends=('python') +makedepends=('python-build' 'python-installer' 'python-setuptools' 'python-wheel') checkdepends=( 'python-asynctest' 'python-docutils' @@ -21,20 +22,26 @@ checkdepends=( 'python-pytz' 'python-twine' 'python-tzlocal') -source=("$pkgname-$pkgver.tar.gz::$url/archive/$pkgver.tar.gz") -sha256sums=('3d4700f019e7a6459a6b88ef5f1ee3441f600554938490405f172313835e2749') +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 "aioimaplib-$pkgver" - python setup.py build + cd "$_pkg-$pkgver" + python -m build --wheel --no-isolation } check() { - cd "aioimaplib-$pkgver" - python setup.py nosetests + cd "$_pkg-$pkgver" + nosetests } package() { - cd "aioimaplib-$pkgver" - python setup.py install --prefix=/usr --root="${pkgdir}" --optimize=1 --skip-build + cd "$_pkg-$pkgver" + PYTHONHASHSEED=0 python -m installer --destdir="$pkgdir" dist/*.whl } |