nixpkgs/pkgs/development/interpreters/maude/default.nix

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

78 lines
2.2 KiB
Nix
Raw Normal View History

{ lib, stdenv, fetchurl, unzip, makeWrapper, flex, bison, ncurses, buddy, tecla
, libsigsegv, gmpxx, cln, yices
# passthru.tests
, tamarin-prover
2016-12-22 11:42:02 +00:00
}:
2016-12-22 11:42:02 +00:00
let
version = "3.3.1";
2016-12-22 11:42:02 +00:00
in
2019-08-13 21:52:01 +00:00
stdenv.mkDerivation {
2019-08-13 21:52:01 +00:00
pname = "maude";
inherit version;
2016-12-22 11:42:02 +00:00
src = fetchurl {
url = "https://github.com/SRI-CSL/Maude/archive/refs/tags/Maude${version}.tar.gz";
sha256 = "ueM8qi3fLogWT8bA+ZyBnd9Zr9oOKuoiu2YpG6o5J1E=";
};
nativeBuildInputs = [ flex bison unzip makeWrapper ];
2016-12-29 11:18:28 +00:00
buildInputs = [
ncurses buddy tecla gmpxx libsigsegv cln yices
2016-12-29 11:18:28 +00:00
];
hardeningDisable = [ "stackprotector" ] ++
lib.optionals stdenv.isi686 [ "pic" "fortify" ];
# Fix for glibc-2.34, see
# https://gitweb.gentoo.org/repo/gentoo.git/commit/dev-lang/maude/maude-3.1-r1.ebuild?id=f021cc6cfa1e35eb9c59955830f1fd89bfcb26b4
configureFlags = [ "--without-libsigsegv" ];
# Certain tests (in particular, Misc/fileTest) expect us to build in a subdirectory
# We'll use the directory Opt/ as suggested in INSTALL
2014-01-13 16:14:40 +00:00
preConfigure = ''
mkdir Opt; cd Opt
2014-01-13 16:14:40 +00:00
configureFlagsArray=(
2016-12-22 11:42:02 +00:00
--datadir="$out/share/maude"
2014-01-13 16:14:40 +00:00
TECLA_LIBS="-ltecla -lncursesw"
2016-12-29 11:18:28 +00:00
LIBS="-lcln"
2014-01-13 16:14:40 +00:00
CFLAGS="-O3" CXXFLAGS="-O3"
)
'';
configureScript = "../configure";
doCheck = true;
2014-01-13 16:14:40 +00:00
postInstall = ''
for n in "$out/bin/"*; do wrapProgram "$n" --suffix MAUDE_LIB ':' "$out/share/maude"; done
'';
passthru.tests = {
# tamarin-prover only supports specific versions of maude explicitly
inherit tamarin-prover;
};
enableParallelBuilding = true;
meta = {
homepage = "http://maude.cs.illinois.edu/";
description = "High-level specification language";
mainProgram = "maude";
license = lib.licenses.gpl2Plus;
longDescription = ''
Maude is a high-performance reflective language and system
supporting both equational and rewriting logic specification and
programming for a wide range of applications. Maude has been
influenced in important ways by the OBJ3 language, which can be
regarded as an equational logic sublanguage. Besides supporting
equational specification and programming, Maude also supports
rewriting logic computation.
'';
platforms = lib.platforms.unix;
maintainers = [ lib.maintainers.peti ];
};
}