1{
2 lib,
3 bitlist,
4 buildPythonPackage,
5 fetchPypi,
6 fountains,
7 parts,
8 pytestCheckHook,
9 pythonOlder,
10 setuptools,
11 wheel,
12}:
13
14buildPythonPackage rec {
15 pname = "fe25519";
16 version = "1.5.0";
17 format = "pyproject";
18
19 disabled = pythonOlder "3.7";
20
21 src = fetchPypi {
22 inherit pname version;
23 hash = "sha256-la+17tPHjceMTe7Wk8DGVaSptk8XJa+l7GTeqLIFDvs=";
24 };
25
26 nativeBuildInputs = [
27 setuptools
28 wheel
29 ];
30
31 propagatedBuildInputs = [
32 bitlist
33 fountains
34 parts
35 ];
36
37 nativeCheckInputs = [ pytestCheckHook ];
38
39 postPatch = ''
40 substituteInPlace pyproject.toml \
41 --replace "--doctest-modules --ignore=docs --cov=fe25519 --cov-report term-missing" ""
42 '';
43
44 pythonImportsCheck = [ "fe25519" ];
45
46 meta = with lib; {
47 description = "Python field operations for Curve25519's prime";
48 homepage = "https://github.com/BjoernMHaase/fe25519";
49 license = with licenses; [ cc0 ];
50 maintainers = with maintainers; [ fab ];
51 };
52}