From b634622be0a78fd62f2631ee63e1a73d965f3527 Mon Sep 17 00:00:00 2001 From: Vincent Laporte Date: Mon, 20 Feb 2017 20:09:53 +0000 Subject: [PATCH] compcert: 2.7.1 -> 3.0.1 --- pkgs/development/compilers/compcert/default.nix | 14 +++++++------- pkgs/top-level/all-packages.nix | 9 ++++++++- pkgs/top-level/ocaml-packages.nix | 8 -------- 3 files changed, 15 insertions(+), 16 deletions(-) diff --git a/pkgs/development/compilers/compcert/default.nix b/pkgs/development/compilers/compcert/default.nix index 20d4a430ac4b..8086a9f97495 100644 --- a/pkgs/development/compilers/compcert/default.nix +++ b/pkgs/development/compilers/compcert/default.nix @@ -1,25 +1,25 @@ { stdenv, lib, fetchurl -, coq, ocaml, findlib, menhir +, coq, ocamlPackages , tools ? stdenv.cc }: -assert lib.versionAtLeast ocaml.version "4.02"; +assert lib.versionAtLeast ocamlPackages.ocaml.version "4.02"; stdenv.mkDerivation rec { name = "compcert-${version}"; - version = "2.7.1"; + version = "3.0.1"; src = fetchurl { url = "http://compcert.inria.fr/release/${name}.tgz"; - sha256 = "1vhbs1fmr9x2imqyd6yfvkbz763jhjfm9wk4nizf9rn1cvxrjqa4"; + sha256 = "0dgrj26dzdy4n3s9b5hwc6lm54vans1v4qx9hdp1q8w1qqcdriq9"; }; - buildInputs = [ coq ocaml findlib menhir ]; + buildInputs = [ coq ] + ++ (with ocamlPackages; [ ocaml findlib menhir ]); enableParallelBuilding = true; configurePhase = '' - substituteInPlace ./configure --replace pl2 pl3 substituteInPlace ./configure --replace '{toolprefix}gcc' '{toolprefix}cc' ./configure -clightgen -prefix $out -toolprefix ${tools}/bin/ '' + (if stdenv.isDarwin then "ia32-macosx" else "ia32-linux"); @@ -30,7 +30,7 @@ stdenv.mkDerivation rec { mkdir -p $lib/share/doc/compcert mv doc/html $lib/share/doc/compcert/ mkdir -p $lib/lib/coq/${coq.coq-version}/user-contrib/compcert/ - mv backend cfrontend common cparser driver flocq ia32 lib \ + mv backend cfrontend common cparser driver flocq x86 x86_32 lib \ $lib/lib/coq/${coq.coq-version}/user-contrib/compcert/ ''; diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 0c8b4868fe79..722b9b9d9d8f 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -4766,7 +4766,14 @@ with pkgs; cmucl_binary = callPackage_i686 ../development/compilers/cmucl/binary.nix { }; - inherit (ocaml-ng.ocamlPackages_4_02) compcert; + compcert = callPackage ../development/compilers/compcert (( + if system == "x86_64-linux" + then { tools = pkgsi686Linux.stdenv.cc; } + else {} + ) // { + coq = coq_8_6; + }); + # Users installing via `nix-env` will likely be using the REPL, # which has a hard dependency on Z3, so make sure it is available. diff --git a/pkgs/top-level/ocaml-packages.nix b/pkgs/top-level/ocaml-packages.nix index bd902396ba1e..b980e0530201 100644 --- a/pkgs/top-level/ocaml-packages.nix +++ b/pkgs/top-level/ocaml-packages.nix @@ -671,14 +671,6 @@ let wyrd = callPackage ../tools/misc/wyrd { }; - compcert = callPackage ../development/compilers/compcert (( - if system == "x86_64-linux" - then { tools = pkgs.pkgsi686Linux.stdenv.cc; } - else {} - ) // { - coq = pkgs.coq_8_5; - }); - haxe = callPackage ../development/compilers/haxe { }; ocaml-top = callPackage ../development/tools/ocaml/ocaml-top { };