2021-01-17 00:15:33 +00:00
|
|
|
{lib, stdenv, fetchurl, gmp, mpir, cddlib}:
|
2020-04-24 23:36:52 +00:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "gfan";
|
|
|
|
version = "0.6.2";
|
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "http://home.math.au.dk/jensen/software/gfan/gfan${version}.tar.gz";
|
|
|
|
sha256 = "02pihqb1lb76a0xbfwjzs1cd6ay3ldfxsm8dvsbl6qs3vkjxax56";
|
|
|
|
};
|
|
|
|
|
2020-10-19 23:25:03 +00:00
|
|
|
patches = [
|
|
|
|
./gfan-0.6.2-cddlib-prefix.patch
|
|
|
|
];
|
|
|
|
|
2021-01-17 00:15:33 +00:00
|
|
|
postPatch = lib.optionalString stdenv.cc.isClang ''
|
2020-04-24 23:36:52 +00:00
|
|
|
substituteInPlace Makefile --replace "-fno-guess-branch-probability" ""
|
|
|
|
'';
|
|
|
|
|
2021-02-19 19:06:45 +00:00
|
|
|
buildFlags = [ "CC=${stdenv.cc.targetPrefix}cc" "CXX=${stdenv.cc.targetPrefix}c++" ];
|
2021-02-05 17:12:51 +00:00
|
|
|
installFlags = [ "PREFIX=$(out)" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
buildInputs = [ gmp mpir cddlib ];
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
inherit version;
|
2021-02-05 17:12:51 +00:00
|
|
|
description = "A software package for computing Gröbner fans and tropical varieties";
|
2021-01-17 00:15:33 +00:00
|
|
|
license = lib.licenses.gpl2 ;
|
|
|
|
maintainers = [lib.maintainers.raskin];
|
|
|
|
platforms = lib.platforms.unix;
|
2020-04-24 23:36:52 +00:00
|
|
|
homepage = "http://home.math.au.dk/jensen/software/gfan/gfan.html";
|
|
|
|
};
|
|
|
|
}
|