Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at lanzaboote 71 lines 1.5 kB view raw
1{ lib 2, stdenv 3, buildPythonPackage 4, pythonOlder 5, fetchPypi 6, cython 7, geos 8, oldest-supported-numpy 9, setuptools 10, wheel 11, numpy 12, pytestCheckHook 13}: 14 15buildPythonPackage rec { 16 pname = "shapely"; 17 version = "2.0.1"; 18 format = "pyproject"; 19 20 disabled = pythonOlder "3.7"; 21 22 src = fetchPypi { 23 inherit pname version; 24 hash = "sha256-Zqaxo+cuzpf8hVNqKBR2+bd5TeLmRsqKRRfi48FEaJM="; 25 }; 26 27 nativeBuildInputs = [ 28 cython 29 geos # for geos-config 30 oldest-supported-numpy 31 setuptools 32 wheel 33 ]; 34 35 buildInputs = [ 36 geos 37 ]; 38 39 propagatedBuildInputs = [ 40 numpy 41 ]; 42 43 nativeCheckInputs = [ 44 pytestCheckHook 45 ]; 46 47 preCheck = '' 48 rm -r shapely # prevent import of local shapely 49 ''; 50 51 disabledTests = lib.optionals (stdenv.isDarwin && stdenv.isAarch64) [ 52 # FIXME(lf-): these logging tests are broken, which is definitely our 53 # fault. I've tried figuring out the cause and failed. 54 # 55 # It is apparently some sandbox or no-sandbox related thing on macOS only 56 # though. 57 "test_error_handler_exception" 58 "test_error_handler" 59 "test_info_handler" 60 ]; 61 62 pythonImportsCheck = [ "shapely" ]; 63 64 meta = with lib; { 65 changelog = "https://github.com/shapely/shapely/blob/${version}/CHANGES.txt"; 66 description = "Manipulation and analysis of geometric objects"; 67 homepage = "https://github.com/shapely/shapely"; 68 license = licenses.bsd3; 69 maintainers = teams.geospatial.members; 70 }; 71}