python312Packages.pyprecice: cleanup and fix

+26 -14
+26 -14
pkgs/development/python-modules/pyprecice/default.nix
··· 1 { 2 lib, 3 buildPythonPackage, 4 - setuptools, 5 - pip, 6 - cython, 7 fetchFromGitHub, 8 mpi4py, 9 numpy, 10 precice, 11 - pkgconfig, 12 - pythonOlder, 13 }: 14 15 buildPythonPackage rec { 16 pname = "pyprecice"; 17 version = "3.1.2"; 18 pyproject = true; 19 - 20 - disabled = pythonOlder "3.7"; 21 22 src = fetchFromGitHub { 23 owner = "precice"; ··· 26 hash = "sha256-/atuMJVgvY4kgvrB+LuQZmJuSK4O8TJdguC7NCiRS2Y="; 27 }; 28 29 - nativeBuildInputs = [ 30 - setuptools 31 - pip 32 cython 33 pkgconfig 34 ]; 35 36 - propagatedBuildInputs = [ 37 numpy 38 mpi4py 39 precice ··· 44 45 # Do not use pythonImportsCheck because this will also initialize mpi which requires a network interface 46 47 - meta = with lib; { 48 description = "Python language bindings for preCICE"; 49 homepage = "https://github.com/precice/python-bindings"; 50 - license = licenses.lgpl3Only; 51 - maintainers = with maintainers; [ Scriptkiddi ]; 52 }; 53 }
··· 1 { 2 lib, 3 buildPythonPackage, 4 fetchFromGitHub, 5 + 6 + # build-system 7 + cython, 8 + pip, 9 + pkgconfig, 10 + setuptools, 11 + 12 + # dependencies 13 mpi4py, 14 numpy, 15 precice, 16 }: 17 18 buildPythonPackage rec { 19 pname = "pyprecice"; 20 version = "3.1.2"; 21 pyproject = true; 22 23 src = fetchFromGitHub { 24 owner = "precice"; ··· 27 hash = "sha256-/atuMJVgvY4kgvrB+LuQZmJuSK4O8TJdguC7NCiRS2Y="; 28 }; 29 30 + postPatch = '' 31 + substituteInPlace pyproject.toml \ 32 + --replace-fail "setuptools>=61,<72" "setuptools" \ 33 + --replace-fail "numpy<2" "numpy" 34 + ''; 35 + 36 + build-system = [ 37 cython 38 + pip 39 pkgconfig 40 + setuptools 41 ]; 42 43 + pythonRelaxDeps = [ 44 + "numpy" 45 + ]; 46 + 47 + dependencies = [ 48 numpy 49 mpi4py 50 precice ··· 55 56 # Do not use pythonImportsCheck because this will also initialize mpi which requires a network interface 57 58 + meta = { 59 description = "Python language bindings for preCICE"; 60 homepage = "https://github.com/precice/python-bindings"; 61 + changelog = "https://github.com/precice/python-bindings/blob/v${version}/CHANGELOG.md"; 62 + license = lib.licenses.lgpl3Only; 63 + maintainers = with lib.maintainers; [ Scriptkiddi ]; 64 }; 65 }