nixpkgs/pkgs/development/coq-modules/VST/default.nix

39 lines
1.1 KiB
Nix
Raw Normal View History

2020-08-28 22:05:46 +01:00
{ lib, mkCoqDerivation, coq, compcert, version ? null }:
2020-09-28 22:04:32 +01:00
2020-08-28 22:05:46 +01:00
with lib; mkCoqDerivation {
2020-09-28 22:04:32 +01:00
pname = "coq${coq.coq-version}-VST";
2020-08-28 22:05:46 +01:00
namePrefix = [];
displayVersion = { coq = false; };
owner = "PrincetonUniversity";
repo = "VST";
inherit version;
2021-04-30 07:49:33 +01:00
defaultVersion = with versions; switch coq.coq-version [
2021-06-16 06:50:50 +01:00
{ case = range "8.12" "8.13"; out = "2.8"; }
2021-04-30 07:49:33 +01:00
] null;
2021-06-16 06:50:50 +01:00
release."2.8".sha256 = "sha256-cyK88uzorRfjapNQ6XgQEmlbWnDsiyLve5po1VG52q0=";
2020-08-28 22:05:46 +01:00
releaseRev = v: "v${v}";
2020-09-28 22:04:32 +01:00
propagatedBuildInputs = [ compcert ];
preConfigure = "patchShebangs util";
makeFlags = [
"BITSIZE=64"
"COMPCERT=inst_dir"
"COMPCERT_INST_DIR=${compcert.lib}/lib/coq/${coq.coq-version}/user-contrib/compcert"
"INSTALLDIR=$(out)/lib/coq/${coq.coq-version}/user-contrib/VST"
];
postInstall = ''
for d in msl veric floyd sepcomp progs64
do
cp -r $d $out/lib/coq/${coq.coq-version}/user-contrib/VST/
done
'';
meta = {
description = "Verified Software Toolchain";
homepage = "https://vst.cs.princeton.edu/";
inherit (compcert.meta) platforms;
};
}