diff options
author | Blair Bonnett | 2019-09-28 22:06:59 +0200 |
---|---|---|
committer | Blair Bonnett | 2019-09-28 22:06:59 +0200 |
commit | 9dc5e55c5fe50c24c8766b8ab6d53c6c36294aa4 (patch) | |
tree | 6ed453d2068e019875026874fb0886c1a44f1308 | |
parent | 7a95dc0cfdce6ede726768b0416870eed7bfc167 (diff) | |
download | aur-9dc5e55c5fe50c24c8766b8ab6d53c6c36294aa4.tar.gz |
Fix dependencies, enable tests, quote variables.
-rw-r--r-- | .SRCINFO | 8 | ||||
-rw-r--r-- | .gitignore | 1 | ||||
-rw-r--r-- | PKGBUILD | 19 |
3 files changed, 22 insertions, 6 deletions
@@ -1,11 +1,15 @@ pkgbase = python-numpy-quaternion pkgdesc = Add built-in support for quaternions to NumPy pkgver = 2019.7.23.15.26.49 - pkgrel = 2 + pkgrel = 3 url = https://github.com/moble/quaternion arch = x86_64 license = MIT - depends = python-numpy>=1.3 + checkdepends = python-pytest + makedepends = python-setuptools + depends = python-numpy>=1.13 + depends = python-scipy + optdepends = python-numba: speedup of numerical functions source = https://files.pythonhosted.org/packages/source/n/numpy-quaternion/numpy-quaternion-2019.7.23.15.26.49.tar.gz sha256sums = 42289bafc3292959173d93736f9c875b5c69d472934f04a76883b7b185adc42e diff --git a/.gitignore b/.gitignore index dbf3fdd9285b..bcb56b4bd3e8 100644 --- a/.gitignore +++ b/.gitignore @@ -2,3 +2,4 @@ src pkg *.pkg.tar.xz *.tar.gz +*.log @@ -2,12 +2,17 @@ pkgname=python-numpy-quaternion pkgver=2019.7.23.15.26.49 -pkgrel=2 +pkgrel=3 pkgdesc="Add built-in support for quaternions to NumPy" url="https://github.com/moble/quaternion" arch=('x86_64') license=('MIT') -depends=('python-numpy>=1.3') +depends=('python-numpy>=1.13' 'python-scipy') +optdepends=( + "python-numba: speedup of numerical functions" +) +makedepends=('python-setuptools') +checkdepends=('python-pytest') source=( "https://files.pythonhosted.org/packages/source/n/numpy-quaternion/numpy-quaternion-$pkgver.tar.gz" ) @@ -17,11 +22,17 @@ sha256sums=( build() { cd "numpy-quaternion-$pkgver" - package_version=${pkgver} python setup.py build + package_version="$pkgver" python setup.py build +} + +check() { + cd "numpy-quaternion-$pkgver" + PYVER=$(python -c 'import sys; print("{}.{}".format(*sys.version_info[:2]))') + PYTHONPATH="$PWD/build/lib.linux-$CARCH-$PYVER" pytest } package() { cd "numpy-quaternion-$pkgver" - package_version=${pkgver} python setup.py install --root="$pkgdir/" --optimize=1 --skip-build + package_version="$pkgver" python setup.py install --root="$pkgdir/" --optimize=1 --skip-build install -Dm644 "LICENSE" "$pkgdir/usr/share/licenses/$pkgname/LICENSE" } |