3
0
Fork 0
forked from mirrors/nixpkgs
nixpkgs/pkgs/applications/science/logic/cadical/default.nix

48 lines
1.2 KiB
Nix
Raw Normal View History

{ lib, stdenv, fetchFromGitHub }:
2020-04-04 16:22:36 +01:00
stdenv.mkDerivation rec {
pname = "cadical";
2021-08-22 12:46:34 +01:00
version = "1.4.1";
2020-04-04 16:22:36 +01:00
src = fetchFromGitHub {
owner = "arminbiere";
repo = "cadical";
rev = "rel-${version}";
2021-08-22 12:46:34 +01:00
sha256 = "0y44z3np4gssgdh4aj5qila7pshrbphycdxn2083i8ayyyjbxshp";
2020-04-04 16:22:36 +01:00
};
2021-07-19 13:00:00 +01:00
outputs = [ "out" "dev" "lib" ];
2020-06-24 06:39:37 +01:00
doCheck = true;
2021-07-19 13:00:00 +01:00
# the configure script is not generated by autotools and does not accept the
# arguments that the default configurePhase passes like --prefix and --libdir
configurePhase = ''
runHook preConfigure
./configure
runHook postConfigure
'';
2020-06-24 06:39:37 +01:00
2020-04-04 16:22:36 +01:00
installPhase = ''
2021-07-19 13:00:00 +01:00
runHook preInstall
2020-04-04 16:22:36 +01:00
install -Dm0755 build/cadical "$out/bin/cadical"
install -Dm0755 build/mobical "$out/bin/mobical"
2021-07-19 13:00:00 +01:00
install -Dm0644 src/ccadical.h "$dev/include/ccadical.h"
install -Dm0644 build/libcadical.a "$lib/lib/libcadical.a"
mkdir -p "$out/share/doc/${pname}/"
install -Dm0755 {LICEN?E,README*,VERSION} "$out/share/doc/${pname}/"
runHook postInstall
2020-04-04 16:22:36 +01:00
'';
meta = with lib; {
2020-04-04 16:22:36 +01:00
description = "Simplified Satisfiability Solver";
maintainers = with maintainers; [ shnarazk ];
platforms = platforms.unix;
license = licenses.mit;
homepage = "http://fmv.jku.at/cadical";
};
}