Date: Friday, January 31, 2020 @ 14:00:08 Author: dvzrv Revision: 560753
archrelease: copy trunk to community-testing-any Added: python-django-haystack/repos/community-testing-any/ python-django-haystack/repos/community-testing-any/PKGBUILD (from rev 560752, python-django-haystack/trunk/PKGBUILD) ----------+ PKGBUILD | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) Copied: python-django-haystack/repos/community-testing-any/PKGBUILD (from rev 560752, python-django-haystack/trunk/PKGBUILD) =================================================================== --- community-testing-any/PKGBUILD (rev 0) +++ community-testing-any/PKGBUILD 2020-01-31 14:00:08 UTC (rev 560753) @@ -0,0 +1,59 @@ +# Maintainer: David Runge <dv...@archlinux.org> + +_name=django-haystack +pkgname=python-django-haystack +pkgver=2.8.1.r109.g7773b7f9 +pkgrel=1 +pkgdesc="Modular search for Django" +arch=('any') +url="https://github.com/django-haystack/django-haystack" +license=('BSD') +depends=('python-django' 'python-six') +makedepends=('git' 'python-setuptools_scm') +checkdepends=('gdal' 'python-coverage' 'python-dateutil' 'python-elasticsearch' +'python-geopy' 'python-mock' 'python-nose' 'python-pysolr' 'python-requests' +'python-pytest' 'python-whoosh') +optdepends=('python-elasticsearch: interface with an elasticsearch instance as search backend' + 'python-pysolr: interface with a solr instance as search backend' + 'python-whoosh: use whoosh as search backend' + 'python-xapian-haystack: use python-xapian as search backend') +# everything's broken: +# https://github.com/django-haystack/django-haystack/issues/1673 +# source=("https://files.pythonhosted.org/packages/source/${_name::1}/${_name}/${_name}-${pkgver}.tar.gz") +source=("${_name}-${pkgver}::git+https://github.com/django-haystack/django-haystack#commit=7773b7f95599701d391983df6bacbe394033c0a6") +sha512sums=('SKIP') + +pkgver() { + cd "$pkgname-$pkgver" + git describe --long --tags | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g' +} + +prepare() { + mv -v "${_name}-${pkgver}" "$pkgname-$pkgver" + cd "$pkgname-$pkgver" + sed -e 's/==/>=/g' -i setup.py + # remove test, which is not working + rm -rv test_haystack/test_management_commands.py +} + +build() { + cd "$pkgname-$pkgver" + python setup.py build +} + +check() { + cd "$pkgname-$pkgver" + export PYTHONPATH="build:${PYTHONPATH}" + python setup.py test +} + +package() { + cd "$pkgname-$pkgver" + python setup.py install --skip-build \ + --optimize=1 \ + --prefix=/usr \ + --root="${pkgdir}" + install -vDm 644 {AUTHORS,CONTRIBUTING.md,README.rst} \ + -t "${pkgdir}/usr/share/doc/${pkgname}" + install -vDm 644 LICENSE -t "${pkgdir}/usr/share/licenses/${pkgname}" +}