2019-03-05 20:59:18 +00:00
|
|
|
{ lib
|
|
|
|
, fetchPypi
|
|
|
|
, buildPythonPackage
|
|
|
|
, gmp
|
|
|
|
, mpfr
|
|
|
|
, libmpc
|
|
|
|
, ppl
|
|
|
|
, cython
|
|
|
|
, cysignals
|
|
|
|
, gmpy2
|
|
|
|
, sphinx
|
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pplpy";
|
2021-02-20 09:09:13 +00:00
|
|
|
version = "0.8.7";
|
2019-03-05 20:59:18 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2021-02-20 09:09:13 +00:00
|
|
|
sha256 = "500bd0f4ae1a76956fae7fcba77854f5ec3e64fce76803664983763c3f2bd8bd";
|
2019-03-05 20:59:18 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
gmp
|
|
|
|
mpfr
|
|
|
|
libmpc
|
|
|
|
ppl
|
|
|
|
];
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
sphinx # docbuild, called by make
|
|
|
|
];
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
cython
|
|
|
|
cysignals
|
|
|
|
gmpy2
|
|
|
|
];
|
|
|
|
|
|
|
|
outputs = [ "out" "doc" ];
|
|
|
|
|
|
|
|
postBuild = ''
|
|
|
|
# Find the build result in order to put it into PYTHONPATH. The doc
|
|
|
|
# build needs to import pplpy.
|
|
|
|
build_result="$PWD/$( find build/ -type d -name 'lib.*' | head -n1 )"
|
|
|
|
|
|
|
|
echo "Building documentation"
|
|
|
|
PYTHONPATH="$build_result:$PYTHONPATH" make -C docs html
|
|
|
|
'';
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
mkdir -p "$doc/share/doc"
|
|
|
|
mv docs/build/html "$doc/share/doc/pplpy"
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "A Python wrapper for ppl";
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://gitlab.com/videlec/pplpy";
|
2020-11-17 19:41:33 +00:00
|
|
|
maintainers = teams.sage.members;
|
2019-03-05 20:59:18 +00:00
|
|
|
license = licenses.gpl3;
|
|
|
|
};
|
|
|
|
}
|