2018-06-30 16:05:56 +01:00
|
|
|
{stdenv, fetchFromGitHub, fetchpatch, mpir, gmp, mpfr, flint}:
|
2016-10-10 19:01:44 +01:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "${pname}-${version}";
|
|
|
|
pname = "arb";
|
2018-04-22 22:13:05 +01:00
|
|
|
version = "2.13.0";
|
2016-10-10 19:01:44 +01:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "fredrik-johansson";
|
|
|
|
repo = "${pname}";
|
|
|
|
rev = "${version}";
|
2018-04-22 22:13:05 +01:00
|
|
|
sha256 = "1fl9gmxf6c1cphk5r8jbys5pywj2rfm705kv0055i0aqc6hrv303";
|
2016-10-10 19:01:44 +01:00
|
|
|
};
|
|
|
|
buildInputs = [mpir gmp mpfr flint];
|
2018-04-22 22:13:05 +01:00
|
|
|
configureFlags = [
|
|
|
|
"--with-gmp=${gmp}"
|
|
|
|
"--with-mpir=${mpir}"
|
|
|
|
"--with-mpfr=${mpfr}"
|
|
|
|
"--with-flint=${flint}"
|
|
|
|
];
|
|
|
|
doCheck = true;
|
2018-06-30 16:05:56 +01:00
|
|
|
patches = [
|
|
|
|
# https://github.com/fredrik-johansson/arb/pull/210, included in next release
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://patch-diff.githubusercontent.com/raw/fredrik-johansson/arb/pull/210.patch";
|
|
|
|
name = "return-exact-zero-where-possible.patch";
|
|
|
|
sha256 = "01j9npnpmwh4dla9i05qdn606hy34gy9bz7c9bbsqm7az3n7pxjg";
|
|
|
|
})
|
|
|
|
];
|
2016-10-10 19:01:44 +01:00
|
|
|
meta = {
|
|
|
|
inherit version;
|
|
|
|
description = ''A library for arbitrary-precision interval arithmetic'';
|
|
|
|
license = stdenv.lib.licenses.lgpl21Plus;
|
|
|
|
maintainers = [stdenv.lib.maintainers.raskin];
|
|
|
|
platforms = stdenv.lib.platforms.linux;
|
|
|
|
};
|
|
|
|
}
|