diff options
author | chrisjbillington | 2023-08-23 14:21:29 +1000 |
---|---|---|
committer | chrisjbillington | 2023-08-23 14:21:29 +1000 |
commit | a2d548f180e83824b8e76b79628b42c0cd8a456f (patch) | |
tree | 19856cd7581ac69783fb5797bb6ed93e7083cef9 /PKGBUILD | |
parent | 03c00ccd54508d8d00e2e0ea7ce3a711dea5dcc1 (diff) | |
download | aur-a2d548f180e83824b8e76b79628b42c0cd8a456f.tar.gz |
Changes as per comments from MarsSeed
* build with H5PY_SYSTEM_LZF=1 envvar and add depends=liblzf
* build with makedepends=cython0 as per current requirement,
* add the needed makedepends=python-setuptools,
* remove the unneeded depends=python-six,
* implement a Git tag based pkgver().
Diffstat (limited to 'PKGBUILD')
-rw-r--r-- | PKGBUILD | 25 |
1 files changed, 12 insertions, 13 deletions
@@ -5,16 +5,16 @@ # Contributor: Rich Li <rich@dranek.com> # Contributor: Sebastien Binet <binet@lblbox> -_pkg=h5py -pkgname=python-${_pkg}-git -pkgver=r1197.ff214cdd +_name=h5py +pkgname=python-${_name}-git +pkgver=3.9.0.r5.g6b5af4c pkgrel=1 pkgdesc="General-purpose Python bindings for the HDF5 library" arch=(x86_64) url="https://www.h5py.org/" license=(BSD) -depends=(hdf5 python-numpy python-six) -makedepends=(cython python-pkgconfig) +depends=(hdf5 python-numpy liblzf) +makedepends=(cython0 python-pkgconfig python-setuptools) checkdepends=(python-pytest) conflicts=(python-h5py hdf5-openmpi) provides=(python-h5py) @@ -22,28 +22,27 @@ source=("git+https://github.com/h5py/h5py") md5sums=('SKIP') pkgver() { - cd "${_pkg}" - printf "r%s.%s" "$(git rev-list HEAD --count --first-parent)" "$(git rev-parse --short HEAD)" + cd "$_name" + git describe --long --tags --abbrev=7 | sed 's/\([^-]*-g\)/r\1/;s/-/./g' } prepare() { # Remove RPATH - sed -i "s/settings\\['runtime_library_dirs'\\] = settings\\['library_dirs'\\]/pass/" ${_pkg}/setup_build.py + sed -i "s/settings\\['runtime_library_dirs'\\] = settings\\['library_dirs'\\]/pass/" ${_name}/setup_build.py } build() { - cd ${_pkg} - python setup.py build + cd ${_name} + H5PY_SYSTEM_LZF=1 python setup.py build } check() { - cd ${_pkg} + cd ${_name} python setup.py test || warning "Tests failed" } package() { - cd ${_pkg} + cd ${_name} python setup.py install --root="${pkgdir}" --skip-build --optimize=1 - install -Dm644 licenses/license.txt -t "${pkgdir}"/usr/share/licenses/${pkgname}/ } |