# Maintainer: Blair Bonnett # Contributor: richli pkgname=python-h5netcdf pkgver=1.0.2 pkgrel=1 pkgdesc="Pythonic interface to netCDF4 via h5py" arch=('any') url="https://github.com/shoyer/h5netcdf" license=('BSD') depends=('python-h5py' 'python-packaging') optdepends=( 'python-h5pyd: open remote datasets using the HDF REST interface' ) makedepends=( 'python-build' 'python-installer' 'python-setuptools' 'python-setuptools-scm' 'python-setuptools-scm-git-archive' 'python-wheel' ) checkdepends=('python-netcdf4' 'python-pytest') _pypi=h5netcdf source=( "https://files.pythonhosted.org/packages/source/${_pypi::1}/$_pypi/$_pypi-$pkgver.tar.gz" ) sha256sums=( '8808a1e095f0122b4fb408cc98c60adf399bd57fef48d1ca7cdf4cda1d0a6b4a' ) build() { cd "$_pypi-${pkgver}" python -m build --wheel --no-isolation } check() { cd "$_pypi-${pkgver}" PYTHONPATH="./build/lib" pytest -v --disable-warnings } package() { cd "$_pypi-${pkgver}" python -m installer --destdir="$pkgdir" "dist/$_pypi-$pkgver-"*.whl install -Dm644 LICENSE "$pkgdir/usr/share/licenses/$pkgname/LICENSE" } # vim: set et sw=4 ts=4 sts=4: