2021-02-05 17:12:51 +00:00
|
|
|
{ lib
|
2020-04-24 23:36:52 +00:00
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, isPyPy
|
|
|
|
, gmp
|
|
|
|
, mpfr
|
|
|
|
, libmpc
|
|
|
|
}:
|
|
|
|
|
|
|
|
let
|
|
|
|
pname = "gmpy2";
|
2022-01-13 20:06:32 +00:00
|
|
|
version = "2.1.2";
|
2024-01-02 11:29:13 +00:00
|
|
|
format = "setuptools";
|
2020-04-24 23:36:52 +00:00
|
|
|
in
|
|
|
|
|
|
|
|
buildPythonPackage {
|
|
|
|
inherit pname version;
|
|
|
|
|
|
|
|
disabled = isPyPy;
|
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "aleaxit";
|
|
|
|
repo = "gmpy";
|
|
|
|
rev = "gmpy2-${version}";
|
2023-03-15 16:39:30 +00:00
|
|
|
hash = "sha256-ARCttNzRA+Ji2j2NYaSCDXgvoEg01T9BnYadyqON2o0=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [ gmp mpfr libmpc ];
|
|
|
|
|
2022-01-13 20:06:32 +00:00
|
|
|
pythonImportsCheck = [ "gmpy2" ];
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "GMP/MPIR, MPFR, and MPC interface to Python 2.6+ and 3.x";
|
|
|
|
homepage = "https://github.com/aleaxit/gmpy/";
|
|
|
|
license = licenses.gpl3Plus;
|
|
|
|
};
|
|
|
|
}
|