nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 stdenv,
3 lib,
4 fetchFromGitHub,
5 cmake,
6 libedit,
7 gmpxx,
8 bison,
9 flex,
10 enableReadline ? false,
11 readline,
12 gtest,
13 nix-update-script,
14}:
15
16stdenv.mkDerivation (finalAttrs: {
17 pname = "opensmt";
18 version = "2.9.2";
19
20 src = fetchFromGitHub {
21 owner = "usi-verification-and-security";
22 repo = "opensmt";
23 tag = "v${finalAttrs.version}";
24 hash = "sha256-xKpYABMn2bsXRg2PMjiMhsx6+FbAsxitLRnmqa1kmu0=";
25 };
26
27 strictDeps = true;
28
29 nativeBuildInputs = [
30 cmake
31 bison
32 flex
33 ];
34
35 buildInputs = [
36 libedit
37 gmpxx
38 gtest
39 ]
40 ++ lib.optional enableReadline readline;
41
42 preConfigure = ''
43 substituteInPlace test/CMakeLists.txt --replace-fail \
44 'FetchContent_MakeAvailable' '#FetchContent_MakeAvailable'
45 '';
46
47 passthru.updateScript = nix-update-script { };
48
49 meta = {
50 broken = with stdenv.hostPlatform; (isLinux && isAarch64);
51 description = "Satisfiability modulo theory (SMT) solver";
52 mainProgram = "opensmt";
53 maintainers = [ lib.maintainers.raskin ];
54 platforms = lib.platforms.linux;
55 license = if enableReadline then lib.licenses.gpl2Plus else lib.licenses.mit;
56 homepage = "https://github.com/usi-verification-and-security/opensmt";
57 };
58})