Merge pull request #46126 from flokli/gmpy-phe
pythonPackages: cleanup gmpy[2], add phe
This commit is contained in:
commit
a59f244b2c
24
pkgs/development/python-modules/gmpy/default.nix
Normal file
24
pkgs/development/python-modules/gmpy/default.nix
Normal file
@ -0,0 +1,24 @@
|
||||
{ buildPythonPackage, fetchurl, isPyPy, gmp } :
|
||||
|
||||
let
|
||||
pname = "gmpy";
|
||||
version = "1.17";
|
||||
in
|
||||
|
||||
buildPythonPackage {
|
||||
inherit pname version;
|
||||
|
||||
disabled = isPyPy;
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://pypi/g/gmpy/${pname}-${version}.zip";
|
||||
sha256 = "1a79118a5332b40aba6aa24b051ead3a31b9b3b9642288934da754515da8fa14";
|
||||
};
|
||||
|
||||
buildInputs = [ gmp ];
|
||||
|
||||
meta = {
|
||||
description = "GMP or MPIR interface to Python 2.4+ and 3.x";
|
||||
homepage = http://code.google.com/p/gmpy/;
|
||||
};
|
||||
}
|
25
pkgs/development/python-modules/gmpy2/default.nix
Normal file
25
pkgs/development/python-modules/gmpy2/default.nix
Normal file
@ -0,0 +1,25 @@
|
||||
{ stdenv, buildPythonPackage, fetchurl, isPyPy, gmp, mpfr, libmpc } :
|
||||
|
||||
let
|
||||
pname = "gmpy2";
|
||||
version = "2.0.8";
|
||||
in
|
||||
|
||||
buildPythonPackage {
|
||||
inherit pname version;
|
||||
|
||||
disabled = isPyPy;
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://pypi/g/gmpy2/${pname}-${version}.zip";
|
||||
sha256 = "0grx6zmi99iaslm07w6c2aqpnmbkgrxcqjrqpfq223xri0r3w8yx";
|
||||
};
|
||||
|
||||
buildInputs = [ gmp mpfr libmpc ];
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
description = "GMP/MPIR, MPFR, and MPC interface to Python 2.6+ and 3.x";
|
||||
homepage = http://code.google.com/p/gmpy/;
|
||||
license = licenses.gpl3Plus;
|
||||
};
|
||||
}
|
29
pkgs/development/python-modules/phe/default.nix
Normal file
29
pkgs/development/python-modules/phe/default.nix
Normal file
@ -0,0 +1,29 @@
|
||||
{ stdenv, buildPythonPackage, fetchPypi, isPyPy, isPy3k, click, gmpy2, numpy } :
|
||||
|
||||
let
|
||||
pname = "phe";
|
||||
version = "1.4.0";
|
||||
in
|
||||
|
||||
buildPythonPackage {
|
||||
inherit pname version;
|
||||
|
||||
# https://github.com/n1analytics/python-paillier/issues/51
|
||||
disabled = isPyPy || ! isPy3k;
|
||||
|
||||
src = fetchPypi {
|
||||
inherit pname version;
|
||||
sha256 = "0wzlk7d24kp0f5kpm0kvvc88mm42144f5cg9pcpb1dsfha75qy5m";
|
||||
};
|
||||
|
||||
buildInputs = [ click gmpy2 numpy ];
|
||||
|
||||
# 29/233 tests fail
|
||||
doCheck = false;
|
||||
|
||||
meta = with stdenv.lib; {
|
||||
description = "A library for Partially Homomorphic Encryption in Python";
|
||||
homepage = https://github.com/n1analytics/python-paillier;
|
||||
license = licenses.gpl3;
|
||||
};
|
||||
}
|
@ -2624,48 +2624,9 @@ in {
|
||||
|
||||
GeoIP = callPackage ../development/python-modules/GeoIP { };
|
||||
|
||||
gmpy = buildPythonPackage rec {
|
||||
name = "gmpy-1.17";
|
||||
disabled = isPyPy;
|
||||
gmpy = callPackage ../development/python-modules/gmpy { };
|
||||
|
||||
src = pkgs.fetchurl {
|
||||
url = "mirror://pypi/g/gmpy/${name}.zip";
|
||||
sha256 = "1a79118a5332b40aba6aa24b051ead3a31b9b3b9642288934da754515da8fa14";
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
pkgs.gcc
|
||||
pkgs.gmp
|
||||
];
|
||||
|
||||
meta = {
|
||||
description = "GMP or MPIR interface to Python 2.4+ and 3.x";
|
||||
homepage = http://code.google.com/p/gmpy/;
|
||||
};
|
||||
};
|
||||
|
||||
gmpy2 = buildPythonPackage rec {
|
||||
name = "gmpy2-2.0.6";
|
||||
disabled = isPyPy;
|
||||
|
||||
src = pkgs.fetchurl {
|
||||
url = "mirror://pypi/g/gmpy2/${name}.zip";
|
||||
sha256 = "5041d0ae24407c24487106099f5bcc4abb1a5f58d90e6712cc95321975eddbd4";
|
||||
};
|
||||
|
||||
buildInputs = [
|
||||
pkgs.gcc
|
||||
pkgs.gmp
|
||||
pkgs.mpfr
|
||||
pkgs.libmpc
|
||||
];
|
||||
|
||||
meta = {
|
||||
description = "GMP/MPIR, MPFR, and MPC interface to Python 2.6+ and 3.x";
|
||||
homepage = http://code.google.com/p/gmpy/;
|
||||
license = licenses.gpl3Plus;
|
||||
};
|
||||
};
|
||||
gmpy2 = callPackage ../development/python-modules/gmpy2 { };
|
||||
|
||||
gmusicapi = with pkgs; buildPythonPackage rec {
|
||||
name = "gmusicapi-10.1.0";
|
||||
@ -3732,6 +3693,8 @@ in {
|
||||
};
|
||||
};
|
||||
|
||||
phe = callPackage ../development/python-modules/phe { };
|
||||
|
||||
phpserialize = callPackage ../development/python-modules/phpserialize { };
|
||||
|
||||
plaid-python = callPackage ../development/python-modules/plaid-python { };
|
||||
|
Loading…
Reference in New Issue
Block a user