# Contributor: Fabian Affolter <fabian@affolter-engineering.ch>
# Maintainer: Fabian Affolter <fabian@affolter-engineering.ch>
pkgname=py3-zope-deprecation
pkgver=5.0
pkgrel=2
pkgdesc="Zope Deprecation Infrastructure"
url="https://github.com/zopefoundation/zope.deprecation"
arch="noarch"
license="ZPL-2.1"
depends="py3-setuptools"
makedepends="
	py3-gpep517
	py3-wheel
	"
checkdepends="py3-zope-testrunner"
subpackages="$pkgname-pyc"
source="$pkgname-$pkgver.tar.gz::https://github.com/zopefoundation/zope.deprecation/archive/refs/tags/$pkgver.tar.gz"
builddir="$srcdir"/zope.deprecation-$pkgver
options="!check" # todo import failure

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

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

check() {
	zope-testrunner --test-path=src
}

package() {
	python3 -m installer -d "$pkgdir" \
		.dist/*.whl
}

sha512sums="
c194d5c5bf7a47311f7c85b21ecd9f2f238cb332859ca8fa4d20b98ae4041867497e5384f4de10f03b7a4005810700ed61cd3c86c46dd638a3780500eea7dd6c  py3-zope-deprecation-5.0.tar.gz
"
