If you want to install O'Caml to work with cygwin, these notes may
help you or they may not. Basically, your instructor did this a few
weeks ago and wrote these notes as he went along.
- If you have an older version of O'Caml installed (unlikely), you
may need to go delete some Windows environment variables.
- Go get the sources for version 3.06 off the web. They're a
.tar.gz file which Winzip has no trouble opening. (You can also use
gunzip and tar via cygwin.) (Version 3.07 was released right at the
beginning of the quarter. I have not upgraded; it probably does not
matter if you do.)
- You can read the INSTALL file to learn more, but this recipe from
the bash command line worked for me:
- ./configure -no-tk -bindir /usr/bin -libdir /usr/lib/ocaml
-mandir /usr/man/man1
- make world.opt
- make install
- To explain the recipe above:
- -no-tk disables Tk bindings. You do not need them. The build
failed on some C file without this flag.
- If you want the binaries, libraries, or manpages elsewhere, do
the needful. But you may need to set some environment variables as
a result. (PATH and CAMLLIB are the obvious suspects.) You can set
environment variables via bash or via the Windows control panel.
- make world.opt builds a lot more than you need. You can read
about other targets in INSTALL. But if make world.opt works, you'll
almost surely have no more problems. And it took less than 4
minutes on my machine.
- I had trouble using ocaml (the read-eval-print loop as opposed to
the compiler) from the bash shell. It seg-faulted on any syntax or
type error. But I always use the compiler.
- I can make my emacs files available if you want pretty colors and
indentation like me. Just remind me.