2017-12-10 08:49:17 +01:00
|
|
|
{ stdenv, fetchFromGitHub, pkgconfig, ocaml }:
|
2014-09-15 22:47:37 +02:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2019-08-15 14:41:18 +02:00
|
|
|
pname = "ott";
|
2020-01-26 10:43:23 +01:00
|
|
|
version = "0.30";
|
2014-09-15 22:47:37 +02:00
|
|
|
|
2017-12-10 08:49:17 +01:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "ott-lang";
|
|
|
|
repo = "ott";
|
|
|
|
rev = version;
|
2020-01-26 10:43:23 +01:00
|
|
|
sha256 = "16bxfnm30z94x36vr8vs6zd6fj55vnb7aypjl6hf7clk42040brc";
|
2014-09-15 22:47:37 +02:00
|
|
|
};
|
|
|
|
|
2017-09-05 23:26:13 +02:00
|
|
|
nativeBuildInputs = [ pkgconfig ];
|
2017-12-10 08:49:17 +01:00
|
|
|
buildInputs = [ ocaml ];
|
2014-09-15 22:47:37 +02:00
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out/bin
|
|
|
|
cp src/ott.opt $out/bin
|
|
|
|
ln -s $out/bin/ott.opt $out/bin/ott
|
|
|
|
|
|
|
|
mkdir -p $out/share/emacs/site-lisp
|
2017-12-10 08:49:17 +01:00
|
|
|
cp emacs/ott-mode.el $out/share/emacs/site-lisp
|
2014-09-15 22:47:37 +02:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "Ott: tool for the working semanticist";
|
|
|
|
longDescription = ''
|
|
|
|
Ott is a tool for writing definitions of programming languages and
|
|
|
|
calculi. It takes as input a definition of a language syntax and
|
|
|
|
semantics, in a concise and readable ASCII notation that is close to
|
|
|
|
what one would write in informal mathematics. It generates LaTeX to
|
|
|
|
build a typeset version of the definition, and Coq, HOL, and Isabelle
|
|
|
|
versions of the definition. Additionally, it can be run as a filter,
|
|
|
|
taking a LaTeX/Coq/Isabelle/HOL source file with embedded (symbolic)
|
|
|
|
terms of the defined language, parsing them and replacing them by
|
|
|
|
target-system terms.
|
|
|
|
'';
|
2020-04-01 03:11:51 +02:00
|
|
|
homepage = "http://www.cl.cam.ac.uk/~pes20/ott";
|
2014-11-06 01:44:33 +01:00
|
|
|
license = stdenv.lib.licenses.bsd3;
|
2014-09-15 22:47:37 +02:00
|
|
|
maintainers = with stdenv.lib.maintainers; [ jwiegley ];
|
|
|
|
platforms = stdenv.lib.platforms.unix;
|
|
|
|
};
|
|
|
|
}
|