at 25.11-pre 1.3 kB view raw
1{ 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 6 # build-system 7 cmake, 8 nanobind, 9 ninja, 10 pcpp, 11 scikit-build, 12 setuptools, 13 14 # buildInputs 15 isl, 16 17 # tests 18 pytestCheckHook, 19}: 20 21buildPythonPackage rec { 22 pname = "islpy"; 23 version = "2025.1.5"; 24 pyproject = true; 25 26 src = fetchFromGitHub { 27 owner = "inducer"; 28 repo = "islpy"; 29 tag = "v${version}"; 30 hash = "sha256-hzqxVLNKm63XliX5rDB54f6n1nJPVJJSAMmNTInbOEE="; 31 }; 32 33 build-system = [ 34 cmake 35 nanobind 36 ninja 37 pcpp 38 scikit-build 39 setuptools 40 ]; 41 42 buildInputs = [ isl ]; 43 44 dontUseCmakeConfigure = true; 45 46 preConfigure = '' 47 python ./configure.py \ 48 --no-use-shipped-isl \ 49 --isl-inc-dir=${lib.getDev isl}/include \ 50 ''; 51 52 # Force resolving the package from $out to make generated ext files usable by tests 53 preCheck = '' 54 rm -rf islpy 55 ''; 56 57 nativeCheckInputs = [ pytestCheckHook ]; 58 59 pythonImportsCheck = [ "islpy" ]; 60 61 meta = { 62 description = "Python wrapper around isl, an integer set library"; 63 homepage = "https://github.com/inducer/islpy"; 64 changelog = "https://github.com/inducer/islpy/releases/tag/v${version}"; 65 license = lib.licenses.mit; 66 maintainers = with lib.maintainers; [ tomasajt ]; 67 }; 68}