2018-08-14 06:43:38 +02:00
|
|
|
{ stdenv, fetchurl, fetchpatch, gmp }:
|
2016-10-10 17:07:21 +02:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "ratpoints-${version}";
|
2018-08-14 06:43:38 +02:00
|
|
|
version = "2.1.3.p4";
|
|
|
|
|
2016-10-10 17:07:21 +02:00
|
|
|
src = fetchurl {
|
|
|
|
url = "http://www.mathe2.uni-bayreuth.de/stoll/programs/ratpoints-${version}.tar.gz";
|
|
|
|
sha256 = "0zhad84sfds7izyksbqjmwpfw4rvyqk63yzdjd3ysd32zss5bgf4";
|
|
|
|
};
|
2018-08-14 06:43:38 +02:00
|
|
|
|
|
|
|
enableParallelBuilding = true;
|
|
|
|
|
|
|
|
patches = [
|
|
|
|
(fetchpatch {
|
|
|
|
url = "https://git.sagemath.org/sage.git/plain/build/pkgs/ratpoints/patches/sturm_and_rp_private.patch?id=1615f58890e8f9881c4228c78a6b39b9aab1303a";
|
|
|
|
sha256 = "0q3wajncyfr3gahd8gwk9x7g56zw54lpywrl63lqk7drkf60mrcl";
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [ gmp ];
|
|
|
|
|
|
|
|
makeFlags = [ "CC=cc" ];
|
|
|
|
buildFlags = stdenv.lib.optional stdenv.isDarwin ["CCFLAGS2=-lgmp -lc -lm" "CCFLAGS=-UUSE_SSE"];
|
|
|
|
installFlags = [ "INSTALL_DIR=$(out)" ];
|
|
|
|
|
2016-10-10 17:07:21 +02:00
|
|
|
preInstall = ''mkdir -p "$out"/{bin,share,lib,include}'';
|
2018-08-14 06:43:38 +02:00
|
|
|
|
2016-10-10 17:07:21 +02:00
|
|
|
meta = {
|
|
|
|
inherit version;
|
|
|
|
description = ''A program to find rational points on hyperelliptic curves'';
|
|
|
|
license = stdenv.lib.licenses.gpl2Plus;
|
|
|
|
maintainers = [stdenv.lib.maintainers.raskin];
|
2018-08-14 06:43:38 +02:00
|
|
|
platforms = stdenv.lib.platforms.unix;
|
2017-08-01 22:03:30 +02:00
|
|
|
homepage = http://www.mathe2.uni-bayreuth.de/stoll/programs/;
|
2016-10-10 17:07:21 +02:00
|
|
|
updateWalker = true;
|
|
|
|
};
|
|
|
|
}
|