2023-02-02 18:25:31 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, cmake
|
|
|
|
, python
|
|
|
|
, libosmium
|
|
|
|
, protozero
|
|
|
|
, boost
|
|
|
|
, expat
|
|
|
|
, bzip2
|
|
|
|
, zlib
|
|
|
|
, pybind11
|
|
|
|
, shapely
|
|
|
|
, pythonOlder
|
|
|
|
, isPyPy
|
|
|
|
, lz4
|
|
|
|
, requests
|
|
|
|
, pytestCheckHook
|
2022-08-12 12:06:08 +00:00
|
|
|
}:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pyosmium";
|
2023-02-02 18:25:31 +00:00
|
|
|
version = "3.6.0";
|
|
|
|
format = "setuptools";
|
2020-11-09 15:59:12 +00:00
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
disabled = pythonOlder "3.6" || isPyPy;
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "osmcode";
|
|
|
|
repo = pname;
|
2022-08-12 12:06:08 +00:00
|
|
|
rev = "refs/tags/v${version}";
|
2023-02-02 18:25:31 +00:00
|
|
|
hash = "sha256-+YJQGPQm2FGOPhNzlXX2GM+ad4QdipJhwViOKGHtqBk=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
cmake
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
libosmium
|
|
|
|
protozero
|
|
|
|
boost
|
|
|
|
expat
|
|
|
|
bzip2
|
|
|
|
zlib
|
|
|
|
pybind11
|
|
|
|
lz4
|
|
|
|
];
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
requests
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
preBuild = "cd ..";
|
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2022-08-12 12:06:08 +00:00
|
|
|
pytestCheckHook
|
|
|
|
shapely
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Python bindings for libosmium";
|
|
|
|
homepage = "https://osmcode.org/pyosmium";
|
2021-04-05 15:23:46 +00:00
|
|
|
changelog = "https://github.com/osmcode/pyosmium/blob/v${version}/CHANGELOG.md";
|
2020-04-24 23:36:52 +00:00
|
|
|
license = licenses.bsd2;
|
|
|
|
maintainers = with maintainers; [ sikmir ];
|
|
|
|
};
|
|
|
|
}
|