A tool for writing definitions of programming languages and calculi
by Peter Sewell, Francesco Zappa Nardelli, and Scott Owens.
Repository and Package
We no longer provide non-github tarballs or a Windows distribution.
||auxiliary code (y2l) used to build the user guide|
||the Ott binary|
||the user guide, in html, pdf, and ps|
||auxiliary files for Coq|
||the user guide sources|
||an Ott Emacs mode|
||some larger example Ott files|
||auxiliary files for LaTeX|
||auxiliary files for HOL|
||auxiliary files for menhir|
||a copy of the ocamlgraph library|
||various small example Ott files|
||the (OCaml) Ott sources|
||a Makefile for the examples|
||the BSD-style licence terms|
||this file (Section 2 of the user guide)|
||the revision history|
If you have OPAM installed on your system,
opam install ott will install the latest Ott version. The Emacs mode
will be in
`opam config var prefix`/share/ott/emacs, and documentation in
`opam config var prefix`/doc/ott.
To install the Ott auxiliary files for Coq, first activate the
coq-released OPAM repository:
opam repo add coq-released https://coq.inria.fr/opam/released
and then run
opam install coq-ott.
Ott depends on OCaml version 4.00.0 or later. It builds with (at least) OCaml 4.02.3.
make world) builds the
ott binary in the
This will compile Ott using
ocamlopt. To force it to
ocamlc (which may give significantly slower execution
of Ott), do
To build the Ott auxiliary files for Coq, go to the
make. To install the resulting files in Coq's
Ott runs as a command-line tool. Executing
bin/ott shows the
usage and options. To run Ott on the test file
tests/test10.ott, generating LaTeX in
bin/ott -i tests/test10.ott -o test10.tex -o test10.v
Isabelle, HOL, and Lem can be generated with options
-o test10Script.sml, and
-o test10.lem, respectively.
The Makefile has various sample targets,
make test7, etc. Typically they generate:
||LaTeX source for a definition|
||the postscript built from that|
test8.ott, etc., in
emacs/ott-mode.el defines a very simple Emacs mode for syntax
highlighting of Ott source files. It can be used by, for example,
adding the following to your
.emacs file, replacing
PATH by a path to your
Ott Emacs directory.
(setq load-path (cons (expand-file-name "PATH") load-path)) (require 'ott-mode)
Web page with examples
The ocamlgraph library is distributed under the LGPL (from http://www.lri.fr/~filliatr/ftp/ocamlgraph/); we include a snapshot for convenience. For its authorship and copyright information see the files therein.
All other files are distributed under the BSD-style licence in LICENCE.