depot/pkgs/development/ocaml-modules/mopsa/default.nix
Luke Granger-Brown 57725ef3ec Squashed 'third_party/nixpkgs/' content from commit 76612b17c0ce
git-subtree-dir: third_party/nixpkgs
git-subtree-split: 76612b17c0ce71689921ca12d9ffdc9c23ce40b2
2024-11-10 23:59:47 +00:00

80 lines
1.2 KiB
Nix

{
lib,
buildDunePackage,
fetchFromGitLab,
clang,
libclang,
libllvm,
flint,
mpfr,
pplite,
ocaml,
menhir,
apron,
camlidl,
yojson,
zarith,
}:
buildDunePackage rec {
pname = "mopsa";
version = "1.0";
minimalOCamlVersion = "4.12";
src = fetchFromGitLab {
owner = "mopsa";
repo = "mopsa-analyzer";
rev = "v${version}";
hash = "sha256-nGnWwV7g3SYgShbXGUMooyOdFwXFrQHnQvlc8x9TAS4=";
};
nativeBuildInputs = [
clang
libllvm
menhir
];
buildInputs = [
camlidl
flint
libclang
mpfr
pplite
];
propagatedBuildInputs = [
apron
yojson
zarith
];
postPatch = ''
patchShebangs bin
'';
buildPhase = ''
runHook preBuild
dune build --profile release -p mopsa
runHook postBuild
'';
installPhase = ''
runHook preInstall
dune install --profile release --prefix=$bin --libdir=$out/lib/ocaml/${ocaml.version}/site-lib
runHook postInstall
'';
outputs = [
"bin"
"out"
];
meta = {
license = lib.licenses.lgpl3Plus;
homepage = "https://mopsa.lip6.fr/";
description = "A Modular and Open Platform for Static Analysis using Abstract Interpretation";
maintainers = [ lib.maintainers.vbgl ];
};
}