# Contributor: Kaarle Ritvanen <kunkku@alpinelinux.org>
# Maintainer: Kaarle Ritvanen <kunkku@alpinelinux.org>
pkgname=py3-django-haystack
pkgver=3.3.0
pkgrel=0
pkgdesc="Modular search for Django"
options="!check" # requires unpackaged pysolr and whoosh
url="https://github.com/django-haystack/django-haystack"
arch="noarch"
license="BSD-3-Clause"
depends="py3-django py3-setuptools"
makedepends="py3-gpep517 py3-setuptools_scm py3-wheel"
subpackages="$pkgname-pyc"
source="https://files.pythonhosted.org/packages/source/d/django_haystack/django_haystack-$pkgver.tar.gz"

builddir="$srcdir/django_haystack-$pkgver"

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

build() {
	gpep517 build-wheel --wheel-dir .dist --output-fd 1
}

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

sha512sums="
3f367b4f22a34145c02487ba3a678542c6bc3f8d8c9be2b4c41fea90f9f8d2bc5a6d4566b31455167f5f198865c81029393e4284673cab057dee6a682c9965af  django_haystack-3.3.0.tar.gz
"
