aboutsummaryrefslogtreecommitdiffstats
path: root/testing/py3-publicsuffix2/APKBUILD
blob: b6770f2a818f0a6359383450436affe88997985d (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
# Contributor: Michał Polański <michal@polanski.me>
# Maintainer: Michał Polański <michal@polanski.me>
pkgname=py3-publicsuffix2
_pkgname=python-publicsuffix2
_pkgver=2.2019-12-21
pkgver=${_pkgver//-}
pkgrel=1
pkgdesc="Python library to deal with publicsuffix data"
url="https://github.com/nexB/python-publicsuffix2"
license="MIT AND MPL-2.0"
arch="noarch"
depends="python3 py3-requests"
makedepends="py3-setuptools"
checkdepends="py3-pytest"
source="$_pkgname-release-$_pkgver.tar.gz::https://github.com/nexB/python-publicsuffix2/archive/release-$_pkgver.tar.gz"
builddir="$srcdir/$_pkgname-release-$_pkgver"

build() {
	python3 setup.py build
}

check() {
	PYTHONPATH="$PWD"/build/lib pytest
}

package() {
	python3 setup.py install --prefix=/usr --root="$pkgdir" --skip-build

	# remove stray license file; SPDX identifier is sufficient in Alpine
	rm "$pkgdir"/usr/lib/python3.*/site-packages/publicsuffix2/mpl-2.0.LICENSE
}

sha512sums="983bdb17b76d10eb73cf69f0ba7590806bf6786ae0c30526593ce1ab97f3b22c967f9acae83b880dd56be41a29eae9cca5726926667eb74013d0d1078433bf05  python-publicsuffix2-release-2.2019-12-21.tar.gz"