2016-09-11 23:24:51 +02:00
|
|
|
{ stdenv, fetchurl, gtk2, gdk_pixbuf, atk, pango, glib, cairo, freetype
|
2014-04-28 20:46:16 +02:00
|
|
|
, fontconfig, libxml2, gnome2 }:
|
|
|
|
|
|
|
|
let
|
2018-04-25 23:54:57 +02:00
|
|
|
|
2014-04-28 20:46:16 +02:00
|
|
|
libPath = stdenv.lib.makeLibraryPath
|
2016-09-11 23:24:51 +02:00
|
|
|
[ stdenv.cc.libc stdenv.cc.cc gtk2 gdk_pixbuf atk pango glib cairo
|
2014-04-28 20:46:16 +02:00
|
|
|
freetype fontconfig libxml2 gnome2.gtksourceview
|
2018-04-25 23:54:57 +02:00
|
|
|
] + ":${stdenv.cc.cc.lib}/lib64:$out/libexec";
|
2014-04-28 20:46:16 +02:00
|
|
|
|
2014-06-10 23:38:45 +02:00
|
|
|
patchExe = x: ''
|
2014-12-17 19:11:30 +01:00
|
|
|
patchelf --interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" \
|
2014-06-10 23:38:45 +02:00
|
|
|
--set-rpath ${libPath} ${x}
|
2014-04-28 20:46:16 +02:00
|
|
|
'';
|
2018-04-25 23:54:57 +02:00
|
|
|
|
|
|
|
patchLib = x: ''
|
|
|
|
patchelf --set-rpath ${libPath} ${x}
|
|
|
|
'';
|
|
|
|
|
2014-04-28 20:46:16 +02:00
|
|
|
in
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "verifast-${version}";
|
2018-04-25 23:54:57 +02:00
|
|
|
version = "18.02";
|
2014-04-28 20:46:16 +02:00
|
|
|
|
|
|
|
src = fetchurl {
|
2018-04-25 23:54:57 +02:00
|
|
|
url = "https://github.com/verifast/verifast/releases/download/${version}/${name}-linux.tar.gz";
|
|
|
|
sha256 = "19050be23b6d5e471690421fee59f84c58b29e38379fb86b8f3713a206a4423e";
|
2014-04-28 20:46:16 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
dontStrip = true;
|
2014-06-10 23:38:45 +02:00
|
|
|
phases = "unpackPhase installPhase";
|
2014-04-28 20:46:16 +02:00
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/bin
|
|
|
|
cp -R bin $out/libexec
|
|
|
|
|
2018-04-25 23:54:57 +02:00
|
|
|
${patchExe "$out/libexec/verifast"}
|
|
|
|
${patchExe "$out/libexec/vfide"}
|
|
|
|
${patchLib "$out/libexec/libz3.so"}
|
|
|
|
ln -s $out/libexec/verifast $out/bin/verifast
|
|
|
|
ln -s $out/libexec/vfide $out/bin/vfide
|
2014-04-28 20:46:16 +02:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "Verification for C and Java programs via separation logic";
|
|
|
|
homepage = "http://people.cs.kuleuven.be/~bart.jacobs/verifast/";
|
2014-05-02 02:09:24 +02:00
|
|
|
license = stdenv.lib.licenses.msrla;
|
2014-06-10 23:38:45 +02:00
|
|
|
platforms = [ "x86_64-linux" ];
|
2014-04-28 20:46:16 +02:00
|
|
|
maintainers = [ stdenv.lib.maintainers.thoughtpolice ];
|
|
|
|
};
|
|
|
|
}
|