default.nix (1015B)
1 { 2 lib, 3 stdenv, 4 python3Packages, 5 fetchFromGitHub, 6 cykhash, 7 pyrobuf, 8 }: 9 10 python3Packages.buildPythonPackage rec { 11 pname = "pyrosm"; 12 version = "0.6.2"; 13 pyproject = true; 14 15 src = fetchFromGitHub { 16 owner = "HTenkanen"; 17 repo = "pyrosm"; 18 tag = "v${version}"; 19 hash = "sha256-eX6lOkprU/RkSz2+dGlRtdQQsI+m9GZyN/VfcIix79k="; 20 }; 21 22 postPatch = '' 23 substituteInPlace pyproject.toml --replace-fail "cykhash==2.0.0" "cykhash" 24 ''; 25 26 build-system = with python3Packages; [ 27 setuptools 28 cython 29 ]; 30 31 dependencies = with python3Packages; [ 32 python-rapidjson 33 geopandas 34 shapely 35 cykhash 36 pyrobuf 37 ]; 38 39 doCheck = false; 40 41 nativeCheckInputs = with python3Packages; [ pytestCheckHook ]; 42 43 pythonImportsCheck = [ "pyrosm" ]; 44 45 meta = { 46 description = "A Python tool to parse OSM data from Protobuf format into GeoDataFrame"; 47 homepage = "https://github.com/HTenkanen/pyrosm"; 48 license = lib.licenses.mit; 49 maintainers = [ lib.maintainers.sikmir ]; 50 }; 51 }