blob: 7d93732eaabf77c4984520a1bd0b4a9c3e020b38 (
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
50
51
52
|
# Contributor: Carlo Landmeter <clandmeter@alpinelinux.org>
# Maintainer: Carlo Landmeter <clandmeter@alpinelinux.org>
pkgname=py-pathlib2
pkgver=2.3.4
pkgrel=0
pkgdesc="Fork of pathlib aiming to support the full stdlib Python API"
url="https://github.com/mcmtroffaes/pathlib2"
arch="noarch"
license="MIT"
source="pathlib2-$pkgver.tar.gz::https://github.com/mcmtroffaes/pathlib2/archive/$pkgver.tar.gz"
builddir="$srcdir/pathlib2-$pkgver"
depends="py-six py-scandir"
makedepends="python2-dev python3-dev py-setuptools"
subpackages="py2-${pkgname#py-}:_py2 py3-${pkgname#py-}:_py3"
build() {
cd "$builddir"
python2 setup.py build
python3 setup.py build
}
check() {
cd "$builddir"
python2 setup.py test
python3 setup.py test
}
package() {
mkdir -p "$pkgdir"
}
_py2() {
depends="${depends//py-/py2-}"
_py python2
}
_py3() {
depends="${depends//py-/py3-}"
_py python3
}
_py() {
local python="$1"
pkgdesc="$pkgdesc (for $python)"
depends="$depends $python"
install_if="$pkgname=$pkgver-r$pkgrel $python"
cd "$builddir"
$python setup.py install --prefix=/usr --root="$subpkgdir"
}
sha512sums="79b37a97037ba9ca2b315c7c4ff06e8b9b492d4f5d5cfe33e8b4cae533bf2314d27edb1a21f83791d82a1761df6a97bc07376cbff61e29e4bf43552daab499a0 pathlib2-2.3.4.tar.gz"
|