summarylogtreecommitdiffstats
path: root/PKGBUILD
blob: e362c5790e681d87f2b69e077e64c970f533a2fd (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
# Maintainer: a821 at (nospam) mail dot de
# Contributor: Luis Martinez <luis dot martinez at disroot dot org>
# Contributor: acxz <akashpatel2008 at yahoo dot com>
# Contributor: jyantis <yantis@yantis.net>

pkgname=python-chess-git
_pkg="${pkgname%-git}"
pkgver=1.11.0.r34.gd4b31904
pkgrel=1
pkgdesc="Chess library with move generation/validation and common format support"
arch=('any')
url=https://github.com/niklasf/python-chess
license=('GPL-3.0-or-later')
depends=('python')
makedepends=('git' 'python-build' 'python-installer' 'python-setuptools' 'python-wheel')
provides=("$_pkg")
conflicts=("$_pkg")
source=("$_pkg::git+$url")
sha256sums=('SKIP')

pkgver() {
	git -C "$_pkg" describe --long --tags | sed 's/^v//;s/-/.r/;s/-/./'
}

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

check() {
	cd "$_pkg"
	python test.py
}

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