Unverified Commit 3e1cfd92 authored by 7c6f434c's avatar 7c6f434c Committed by GitHub
Browse files

opensmt: 2.7.0 -> 2.9.2 (#453424)

parents 48093b50 edc8a602
Loading
Loading
Loading
Loading
+19 −16
Original line number Diff line number Diff line
@@ -10,46 +10,49 @@
  enableReadline ? false,
  readline,
  gtest,
  nix-update-script,
}:

stdenv.mkDerivation rec {
stdenv.mkDerivation (finalAttrs: {
  pname = "opensmt";
  version = "2.7.0";
  version = "2.9.2";

  src = fetchFromGitHub {
    owner = "usi-verification-and-security";
    repo = "opensmt";
    rev = "v${version}";
    sha256 = "sha256-zhNNnwc41B4sNq50kPub29EYhqV+FoDKRD/CLHnVyZw=";
    tag = "v${finalAttrs.version}";
    hash = "sha256-xKpYABMn2bsXRg2PMjiMhsx6+FbAsxitLRnmqa1kmu0=";
  };

  strictDeps = true;

  nativeBuildInputs = [
    cmake
    bison
    flex
  ];

  buildInputs = [
    libedit
    gmpxx
    gtest
  ]
  ++ lib.optional enableReadline readline;

  preConfigure = ''
    substituteInPlace test/CMakeLists.txt \
      --replace 'FetchContent_Populate' '#FetchContent_Populate'
    substituteInPlace test/CMakeLists.txt --replace-fail \
      'FetchContent_MakeAvailable' '#FetchContent_MakeAvailable'
  '';
  cmakeFlags = [
    "-Dgoogletest_SOURCE_DIR=${gtest.src}"
    "-Dgoogletest_BINARY_DIR=./gtest-build"
  ];

  meta = with lib; {
    broken = (stdenv.hostPlatform.isLinux && stdenv.hostPlatform.isAarch64);
  passthru.updateScript = nix-update-script { };

  meta = {
    broken = with stdenv.hostPlatform; (isLinux && isAarch64);
    description = "Satisfiability modulo theory (SMT) solver";
    mainProgram = "opensmt";
    maintainers = [ maintainers.raskin ];
    platforms = platforms.linux;
    license = if enableReadline then licenses.gpl2Plus else licenses.mit;
    maintainers = [ lib.maintainers.raskin ];
    platforms = lib.platforms.linux;
    license = if enableReadline then lib.licenses.gpl2Plus else lib.licenses.mit;
    homepage = "https://github.com/usi-verification-and-security/opensmt";
  };
}
})