blob: 8d3c28f206c5674cc9ae1fd93728c52ff8aa8989 (
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
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
|
# Maintainer: peippo <christoph+aur@christophfink.com>
pkgname="python-pyrosm"
_name=${pkgname#python-}
pkgdesc="A Python tool to parse OSM data from Protobuf format into GeoDataFrame."
url="https://pyrosm.readthedocs.io/"
pkgver=0.6.1
pkgrel=3
arch=("any")
license=("MIT")
makedepends=(
"python-setuptools"
)
depends=(
"cython"
"python"
"python-cykhash"
"python-geopandas"
"python-numpy"
"python-pygeos"
"python-pyrobuf"
"python-rapidjson"
"python-shapely"
)
optdepends=(
"python-igraph: convert graph to igraph.Graph"
"python-networkx: convert graph to networkx.Graph"
"python-pandana: convert graph to pandana.Network"
)
checkdepends=(
"python-anyio"
"python-coverage"
"python-igraph"
"python-networkx"
"python-pandana"
"python-pytest"
)
source=(
"https://files.pythonhosted.org/packages/source/${_name::1}/$_name/$_name-$pkgver.tar.gz"
"${pkgname}-${pkgver}_LICENSE::https://raw.githubusercontent.com/HTenkanen/pyrosm/v${pkgver}/LICENSE"
)
sha256sums=(
"53072bff13a4e96bb3f384e5a5b22bc63813115d633b8882e596856d8441cd2b"
"ae4f776adf4385747f78ad16b5a162814fefe8557f18433cc772a9734716b3a7"
)
build() {
cd "${srcdir}"/${_name}-${pkgver}
python setup.py build
}
check() {
cd "${srcdir}"/${_name}-${pkgver}
local python_version=$(python -c 'import sys; print(".".join(map(str, sys.version_info[:2])))')
PYTHONPATH="build/lib.linux-$CARCH-${python_version}" pytest
}
package() {
cd "${srcdir}/${_name}-${pkgver}"
python setup.py install --root="${pkgdir}" --optimize=1
cd "${srcdir}"
install -Dm644 "${pkgname}-${pkgver}_LICENSE" "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
}
|