OCaml Development Tools
Overview Screenshots Installation notes Download Tutorial Next release

Installation notes

[en] [fr]
1 November 2013, by Emmanuel Dieul


First, you need to have Eclipse installed on your system.

If you don’t have any Eclipse distribution installed, please download it (Eclipse is free). ODT should be compatible with every Eclipse release (ODT only uses the Eclipse kernel). Eclipse is usually either a package rpm or an archive (zip, tgz...) to install or uncompress. Please refer to Eclipse install notes.

Eclipse and ODT needs a Java Virtual Machine (JVM) to work. If you already have Java installed, you can check its version by typing "java -version" in a terminal/shell.
If Java is not installed, visit the java website to download the latest Java JDK or JRE (also free).

You also need to have an operational OCaml distribution. If you don’t already have one, you can download and install the one corresponding to your OS. The OCaml binaries must be accessible with your PATH environment variable. If your configuration is OCaml under Cygwin, don’t forget to put the "/bin" directory of Cygwin in your PATH to let windows access the dll of Cygwin and executes the OCaml binaries from everywhere.

compatibility table
3.0 3.7 .. 4.3 1.6..1.7 3.10 .. 4.00.1
2.3 3.7 .. 4.2 1.6 3.10 .. 4.00.1
2.2 ±3.7 1.6 3.10 .. 3.12.1
2.1 ±3.7 1.6 3.10 .. 3.12.0
2.0 ±3.7 1.6 3.10 .. 3.12.0
1.3.1 ±3.6.1 1.5 .. 1.6 3.10 .. 3.12.0
1.3 ±3.5 1.5 .. 1.6 3.10 .. 3.11

Install notes

There are now two ways to install ODT into Eclipse. Both uses the Eclipse software installer. When Eclipse is launched, this one is accessible via the "Help > Install New Software".

If it’s the first time you install ODT by this way, click the "Add..." button to add a new source location for ODT.

PNG - 11.5 kb

The most simple way is to refer to the online source location of ODT:

  1. in the "Name" field, type "OCaml Development Tools"
  2. in the "Location" field, type "http://odt.sf.net"
  3. click OK

The online location is now defined and the ODT plugins should be shown.

PNG - 45.8 kb

Follow the installation instructions of the Eclipse installer. Now ODT is installed.

The other way is to download the ODT plugins from the download page. Instead of typing the online location of ODT into the "Location" field, just click on the "Archive..." button and select the downloaded zip file. The installation proceeds just like with the online location. But take care: the updates won’t be available by this way.

When an ODT online location is already stored into the Eclipse installer, updates can simply be retrieved by the "Help > Check for Updates" Eclipse menu.

Note: if you have an old installation of ODT into Eclipse (prior to ODT 1.3), plugins should be deleted manually from your Eclipse installation.

Usage with Cygwin

Some Cygwin releases generate error messages which makes the ocamlc compilation problem analysis impossible for ODT.

To fix this problem, you have to set the CYGWIN environment variable to "nodosfilewarning", and then close and reopen your Windows session. More details into the dedicated article.

Restriction / Patch

The outline view is not fully functional for the OCaml versions under 3.10 (3.10 and above is OK). This is due to an ambiguous abstract syntax tree provided by the "-dparsetree" ocamlc option. If you want to have an operational outline view, you need to patch your OCaml installation:
- download a source distribution (e.g. 3.09.3)
- uncompress the downloaded archive
- patch the "parsing/printast.ml" file by replacing the function "list"
let list i f ppf l = List.iter (f i ppf) l;;

let list i f ppf l =
 match l with
 | [] -> line i ppf "[]\n";
 | h::t ->
    line i ppf "[\n";
    List.iter (f (i+1) ppf) l;
    line i ppf "]\n";

- compile the binaries (./configure options; make world ; make bootstrap ; make install)

Then your compiler is patched and the outline view is functional.

This restriction does not impact the other features of the ODT.


November 2013

ODT 3.0 released: code completion and others

January 2013

ODT 2.3 released : OCaml 4.00 support

April 2012

ODT 2.2 released : folding code and full indentation

January 2012

ODT 2.1 released : interface generation, libraries and referenced projects

September 2011

ODT 2.0 released : camlp4 integration, separate compilation and more...

December 2010

ODT 1.3.1 released : OCaml 3.12.0 support

October 2010

ODT 1.3 released : many improvements