diff options
Diffstat (limited to 'pkgs/development/python-modules/i-pi/default.nix')
-rw-r--r-- | pkgs/development/python-modules/i-pi/default.nix | 44 |
1 files changed, 33 insertions, 11 deletions
diff --git a/pkgs/development/python-modules/i-pi/default.nix b/pkgs/development/python-modules/i-pi/default.nix index 046823d23c43..2ad38a1ea4ac 100644 --- a/pkgs/development/python-modules/i-pi/default.nix +++ b/pkgs/development/python-modules/i-pi/default.nix @@ -1,31 +1,50 @@ -{ buildPythonPackage, lib, fetchFromGitHub, gfortran -, makeWrapper, numpy, pytest, mock, pytest-mock -} : +{ + buildPythonPackage, + lib, + fetchFromGitHub, + gfortran, + makeWrapper, + setuptools, + numpy, + scipy, + distutils, + pytestCheckHook, + mock, + pytest-mock, + pythonAtLeast, +}: buildPythonPackage rec { pname = "i-pi"; - version = "2.6.1"; - format = "setuptools"; + version = "3.0"; + pyproject = true; src = fetchFromGitHub { owner = "i-pi"; repo = "i-pi"; rev = "refs/tags/v${version}"; - sha256 = "sha256-c1bs8ZI/dfDwKx5Df8ndtsDxESQrdbMkvrjfI6b9JTg="; + hash = "sha256-SJ0qTwwdIOR1nXs9MV6O1oxJPR6/6H86wscDy/sLc/g="; }; + build-system = [ setuptools ]; + nativeBuildInputs = [ gfortran makeWrapper ]; - propagatedBuildInputs = [ numpy ]; + dependencies = [ + numpy + scipy + ]; nativeCheckInputs = [ - pytest + pytestCheckHook mock pytest-mock - ]; + ] ++ lib.optional (pythonAtLeast "3.12") distutils; + + pytestFlagsArray = [ "ipi_tests/unit_tests" ]; postFixup = '' wrapProgram $out/bin/i-pi \ @@ -33,8 +52,11 @@ buildPythonPackage rec { ''; meta = with lib; { - description = "A universal force engine for ab initio and force field driven (path integral) molecular dynamics"; - license = with licenses; [ gpl3Only mit ]; + description = "Universal force engine for ab initio and force field driven (path integral) molecular dynamics"; + license = with licenses; [ + gpl3Only + mit + ]; homepage = "http://ipi-code.org/"; platforms = platforms.linux; maintainers = [ maintainers.sheepforce ]; |