Woot Woot

social coding

Programming languages matter.

Programming languages affect the reliability, security, and efficiency of the code you write, as well as how easy it is to read, refactor, and extend. The languages you know can also change how you think, influencing the way you design software even when you're not using them.

OCaml Installation

Step 1: Install OPAM

On Mac OS X : my version is Maverick

$ brew update
$ brew install opam

On Ubuntu 12 : mine is from http://www.contiki-os.org/start.html

$ add-apt-repository ppa:avsm/ppa
$ apt-get update
$ apt-get install curl build-essential m4 ocaml opam

Step 2: Install OPAM modules

On either Max OS X or Ubuntu 12:

$ opam init
$ opam install core utop
$ opam install async yojson core_extended core_bench \
               cohttp async_graphics cryptokit menhir
$ eval `opam config env`

Step 3: Edit the '.ocamlinit' file

$ vi .ocamlinit

Add the following lines:

#use "topfind";;
#thread;;
#camlp4o;;
#require "core.top";;
#require "core.syntax";;

Step 4: Start the 'ocaml' shell or the 'utop' shell

$ ocaml
$ utop

Type Ctrl-D to quit.