at 23.11-beta 1.1 kB view raw
1{ lib 2, buildPythonPackage 3, fetchPypi 4, python 5, geos 6, pytestCheckHook 7, cython 8, numpy 9}: 10 11buildPythonPackage rec { 12 pname = "pygeos"; 13 version = "0.14"; 14 15 src = fetchPypi { 16 inherit pname version; 17 hash = "sha256-MPvBf2SEQgC4UTO4hfz7ZVQbh3lTH270+P5GfT+6diM="; 18 }; 19 20 nativeBuildInputs = [ 21 geos # for geos-config 22 cython 23 ]; 24 25 propagatedBuildInputs = [ 26 numpy 27 ]; 28 29 # The cythonized extensions are required to exist in the pygeos/ directory 30 # for the package to function. Therefore override of buildPhase was 31 # necessary. 32 buildPhase = '' 33 ${python.pythonOnBuildForHost.interpreter} setup.py build_ext --inplace 34 ${python.pythonOnBuildForHost.interpreter} setup.py bdist_wheel 35 ''; 36 37 nativeCheckInputs = [ 38 pytestCheckHook 39 ]; 40 41 pythonImportsCheck = [ 42 "pygeos" 43 ]; 44 45 meta = with lib; { 46 description = "Wraps GEOS geometry functions in numpy ufuncs"; 47 homepage = "https://github.com/pygeos/pygeos"; 48 changelog = "https://github.com/pygeos/pygeos/blob/${version}/CHANGELOG.rst"; 49 license = licenses.bsd3; 50 maintainers = with maintainers; [ nialov ]; 51 }; 52}