nixpkgs/pkgs/applications/science/logic/leo2/default.nix
Profpatsch 4a7f99d55d treewide: with stdenv.lib; in meta -> with lib;
Part of: https://github.com/NixOS/nixpkgs/issues/108938

meta = with stdenv.lib;

is a widely used pattern. We want to slowly remove
the `stdenv.lib` indirection and encourage people
to use `lib` directly. Thus let’s start with the meta
field.

This used a rewriting script to mostly automatically
replace all occurances of this pattern, and add the
`lib` argument to the package header if it doesn’t
exist yet.

The script in its current form is available at
https://cs.tvl.fyi/depot@2f807d7f141068d2d60676a89213eaa5353ca6e0/-/blob/users/Profpatsch/nixpkgs-rewriter/default.nix
2021-01-11 10:38:22 +01:00

38 lines
980 B
Nix

{ lib, stdenv, fetchurl, makeWrapper, eprover, ocaml, perl, zlib }:
stdenv.mkDerivation rec {
pname = "leo2";
version = "1.6.2";
src = fetchurl {
url = "https://page.mi.fu-berlin.de/cbenzmueller/leo/leo2_v${version}.tgz";
sha256 = "1wjpmizb181iygnd18lx7p77fwaci2clgzs5ix5j51cc8f3pazmv";
};
buildInputs = [ makeWrapper eprover ocaml perl zlib ];
sourceRoot = "leo2/src";
preConfigure = "patchShebangs configure";
buildFlags = [ "opt" ];
preInstall = "mkdir -p $out/bin";
postInstall = ''
mkdir -p "$out/etc"
echo -e "e = ${eprover}/bin/eprover\\nepclextract = ${eprover}/bin/epclextract" > "$out/etc/leoatprc"
wrapProgram $out/bin/leo \
--add-flags "--atprc $out/etc/leoatprc"
'';
meta = with lib; {
description = "A high-performance typed higher order prover";
maintainers = [ maintainers.raskin ];
platforms = platforms.linux;
license = licenses.bsd3;
homepage = "http://www.leoprover.org/";
};
}