summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: c1169f5feaa97f90a572f2882de82fca9df62549 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
# Maintainer: Torleif Skår <torleif.skaar AT gmail DOT com>
_name="spin"
pkgname="python-${_name}"
pkgver=0.8
pkgrel=1
pkgdesc="A developer tool for scientific Python libraries"
arch=('any')
url="https://github.com/scientific-python/spin"
license=('BSD')
depends=(
  "python>=3.8"
  "python-click"
  "python-tomli"
)
makedepends=(
  "python-setuptools"
  "python-build"
  "python-installer"
  "python-wheel"
)
checkdepends=(
  "python-pytest"
)
source=(
  "https://files.pythonhosted.org/packages/source/${_name::1}/${_name}/${_name}-${pkgver}.tar.gz"
)
sha256sums=(
  "27c39a3f3eefcf448566b01f5ae434bbf125f027ab8567841c5129f79445c439"
)
_archive="${_name}-${pkgver}"

build() {
  cd "${_archive}"
  python -m build --wheel --no-isolation
}

check() {
  cd "${_archive}"
  PYTHONPATH="." pytest
}

package() {
  cd "${_archive}"
  python -m installer --destdir="${pkgdir}" dist/*.whl

  install -Dm0644 -t "${pkgdir}/usr/share/licenses/${pkgname}/" LICENSE
}

# vim: sw=2 ts=2 et: