Unverified Commit 52004333 authored by Yifei Sun's avatar Yifei Sun Committed by GitHub
Browse files

ocamlPackages.frama-c-lannotate: init at 0.2.4 (#467858)

parents 53f112a1 11d16855
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -74,6 +74,7 @@ stdenv.mkDerivation rec {
  ]);

  buildInputs = with ocamlPackages; [
    camlzip
    dune-site
    dune-configurator
    ocamlgraph
+29 −0
Original line number Diff line number Diff line
{
  lib,
  buildDunePackage,
  dune-site,
  fetchzip,
  frama-c,
}:

buildDunePackage (finalAttrs: {
  pname = "frama-c-lannotate";
  version = "0.2.4";

  src = fetchzip {
    url = "https://git.frama-c.com/pub/ltest/lannotate/-/archive/${finalAttrs.version}/lannotate-${finalAttrs.version}.tar.bz2";
    hash = "sha256-JoD2M3R3/DcUMt33QOvwqHg4eToCgjB8riKc09TWdyc=";
  };

  propagatedBuildInputs = [
    dune-site
    frama-c
  ];

  meta = {
    description = "Lannotate plugin of Frama-C, part of the LTest suite";
    homepage = "https://frama-c.com/fc-plugins/ltest.html";
    license = lib.licenses.lgpl2;
    maintainers = with lib.maintainers; [ redianthus ];
  };
})
+43 −0
Original line number Diff line number Diff line
{
  stdenv,
  pkgs,
  ocaml,
  findlib,
  framac,
  camlzip,
  ocamlgraph,
  menhirLib,
  ppx_deriving,
  yaml,
  yojson,
  zarith,
}:

stdenv.mkDerivation {
  pname = "ocaml${ocaml.version}-frama-c";
  inherit (framac) version meta;

  dontUnpack = true;

  buildInputs = [ findlib ];

  propagatedBuildInputs = [
    camlzip
    menhirLib
    ocamlgraph
    ppx_deriving
    yaml
    yojson
    zarith
  ];

  installPhase = ''
    runHook preInstall
    mkdir -p $OCAMLFIND_DESTDIR
    for p in ${framac}/lib/*
    do
      ln -s $p $OCAMLFIND_DESTDIR/
    done
    runHook postInstall
  '';
}
+6 −0
Original line number Diff line number Diff line
@@ -647,6 +647,12 @@ let

        fpath = callPackage ../development/ocaml-modules/fpath { };

        frama-c = callPackage ../development/ocaml-modules/frama-c {
          framac = pkgs.framac.override { ocamlPackages = self; };
        };

        frama-c-lannotate = callPackage ../development/ocaml-modules/frama-c-lannotate { };

        frei0r = callPackage ../development/ocaml-modules/frei0r {
          inherit (pkgs) frei0r;
        };