aboutsummaryrefslogtreecommitdiffstats
path: root/testing/py2-contextlib2/APKBUILD
blob: 6ef54883f13ef758e76fced8e77fcda6ac6456b7 (plain) (blame)
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
# Contributor: Stuart Cardall <developer@it-offshore.co.uk>
# Maintainer: Stuart Cardall <developer@it-offshore.co.uk>
pkgname=py2-contextlib2
_pkgname=${pkgname#py2-*}
pkgver=0.4.0
pkgrel=1
pkgdesc="Backport of the Python3 stdlib contextlib module"
url="https://contextlib2.readthedocs.org/"
arch="noarch"
license="PSF"
depends="python2"
makedepends="python2-dev"
source="$pkgname-$pkgver.tar.gz::http://http.debian.net/debian/pool/main/c/$_pkgname/${_pkgname}_${pkgver}.orig.tar.gz"
builddir="$srcdir/$_pkgname-$pkgver"

build() {
	cd "$builddir"
	python2 setup.py build
}

check() {
	cd "$builddir"
	python2 test_contextlib2.py
}

package() {
	cd "$builddir"
	python2 setup.py install --prefix=/usr --root="$pkgdir"
}

sha512sums="622762c5490f0ff3e4b421a63bccce8fe0753977112ee0db9640dad31093c40c8a331f3d7cade9925f17903eaeaa376925ef607d7a440170c7c5ec1c8e04f56a  py2-contextlib2-0.4.0.tar.gz"