# Contributor: Iztok Fister, Jr. # Maintainer: Iztok Fister, Jr. pkgname=py3-fiona _pkgorig=Fiona pkgver=1.9.4 pkgrel=0 pkgdesc="Fiona reads and writes geographical data files" url="https://github.com/Toblerity/Fiona" arch="all" license="BSD" depends=" cython gdal gdal-dev python3 python3-dev py3-attrs py3-click-plugins py3-cligj py3-certifi py3-munch py3-setuptools py3-six py3-tz " checkdepends="py3-pytest py3-pytest-cov py3-boto3" makedepends="py3-setuptools" subpackages="$pkgname-pyc" source="$pkgname-$pkgver.tar.gz::https://files.pythonhosted.org/packages/source/F/Fiona/Fiona-$pkgver.tar.gz patch-vendor.patch " builddir="$srcdir/$_pkgorig-$pkgver" options="!check" # several tests are failing prepare() { default_prepare rm -r fiona/_vendor } build() { python3 setup.py build } check() { mv fiona backup # inspired by Arch package local python_version=$(python3 -c 'import sys; print(".".join(map(str, sys.version_info[:2])))') PYTHONPATH="$PWD"/build/lib.linux-$CARCH-$python_version/ pytest -vv --color=yes -m "not wheel" mv backup fiona } package() { python3 setup.py install --skip-build --root="$pkgdir" # conflicts with fio package mv "$pkgdir"/usr/bin/fio "$pkgdir"/usr/bin/fiona-fio # remove tests rm -r "$pkgdir"/usr/lib/python3.*/site-packages/tests # remove docs rm -r "$pkgdir"/usr/lib/python3.*/site-packages/docs # remove examples rm -r "$pkgdir"/usr/lib/python3.*/site-packages/examples # remove scripts rm -r "$pkgdir"/usr/lib/python3.*/site-packages/scripts } sha512sums=" 87e6865a839649976f3c2a9217b5cba0eaef2507412457dbbfe753f39948405bf03dd0a2cc89d6941148c5bfbf37216e338ac120f67f79dfab8cb55d88415982 py3-fiona-1.9.4.tar.gz 0f9daebc982ead978e8e192e988593e2a10745ecba2d44a1f94d994e9fdcd1647de5b71f891c536f681f1a1a8be4fb416e50e27cb762811da333ec915bde4638 patch-vendor.patch "