3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/development/coq-modules/flocq/default.nix

52 lines
1.3 KiB
Nix
Raw Normal View History

{ stdenv, bash, which, autoconf, automake, fetchurl, coq }:
let params =
if stdenv.lib.versionAtLeast coq.coq-version "8.7" then {
version = "3.0.0";
uid = "37477";
sha256 = "1h05ji5cmyqyv2i1l83xgkm7vfvcnl8r1dzvbp5yncm1jr9kf6nn";
} else {
version = "2.6.1";
uid = "37454";
sha256 = "06msp1fwpqv6p98a3i1nnkj7ch9rcq3rm916yxq8dxf51lkghrin";
}
; in
2014-10-21 06:23:36 +01:00
stdenv.mkDerivation rec {
2017-01-14 14:52:03 +00:00
name = "coq${coq.coq-version}-flocq-${version}";
inherit (params) version;
2014-10-21 06:23:36 +01:00
src = fetchurl {
url = "https://gforge.inria.fr/frs/download.php/file/${params.uid}/flocq-${version}.tar.gz";
inherit (params) sha256;
2014-10-21 06:23:36 +01:00
};
nativeBuildInputs = [ bash which autoconf automake ];
buildInputs = [ coq ] ++ (with coq.ocamlPackages; [
ocaml camlp5
]);
2014-10-21 06:23:36 +01:00
buildPhase = ''
${bash}/bin/bash autogen.sh
${bash}/bin/bash configure --libdir=$out/lib/coq/${coq.coq-version}/user-contrib/Flocq
./remake
'';
installPhase = ''
./remake install
'';
meta = with stdenv.lib; {
homepage = http://flocq.gforge.inria.fr/;
description = "A floating-point formalization for the Coq system";
2014-12-07 12:14:08 +00:00
license = licenses.lgpl3;
2014-10-21 06:23:36 +01:00
maintainers = with maintainers; [ jwiegley ];
platforms = coq.meta.platforms;
};
passthru = {
compatibleCoqVersions = v: builtins.elem v [ "8.5" "8.6" "8.7" "8.8" ];
};
2014-10-21 06:23:36 +01:00
}