caml-list - the Caml user's mailing list
 help / color / mirror / Atom feed
* Wishes for an easy install of Ocaml
@ 2004-12-24  8:58 Philippe Lelédy
  2004-12-24 11:04 ` [Caml-list] " Stefano Zacchiroli
                   ` (4 more replies)
  0 siblings, 5 replies; 17+ messages in thread
From: Philippe Lelédy @ 2004-12-24  8:58 UTC (permalink / raw)
  To: Caml-list

I introduce me a little:

I am a French teacher who give to my students their first  course in 
Computer Science, which include learning Caml (as the first language).

I give them strong advice to install an  Unix-like OS on their own 
computer, with some success (Linux, MacOS X).
But because they have absolutly no Unix experience,  I'd like to say 
them  that  installing  Ocaml is  as  simple as

apt-get install ocaml (for instance)

but it is not. Another step is mandatory

apt-get install tuareg

but it is not enough, adding some obscure lines to .emacs is necessary 
b/c the old Caml mode is effective by default but Tuareg is not. Time 
spent to explain that is very counter-productive to Unix new-bies. 
Debian tuareg-mode does half the job by adding tuareg-mode directory to 
emacs load-path, but manual addition of (load "append-tuareg") is still 
necessary.

I've discovered another issue: if your emacs defaults to utf-8 encoding 
you need some extra lines in your .emacs, that I had to struggle a long 
time to find out:

(modify-coding-system-alist 'file "\\.ml\\'" 'iso-latin-9)
(modify-coding-system-alist 'file "\\.mli\\'" 'iso-latin-9)

(modify-coding-system-alist 'process "ocaml" 'iso-latin-9)

That's a bare minimum to have Ocaml working on a student own computer.

Other steps are usefull for a more comfortable  experience, for instance 
(on Debian):

(custom-set-variables
 ;; custom-set-variables was added by Custom -- don't edit or cut/paste it!
 ;; Your init file should contain only one such instance.
[...]
 '(tuareg-library-path "/usr/lib/ocaml/3.08")
 )

That last line is not release independant.

And here is what I add to .emacs for an easy access to  Ocaml  manual:
 
  (setq tuareg-manual-url 
"file:///usr/share/doc/ocaml/docs/ocaml.html/index.html")
  (setq tuareg-browser 'phl-browser-new-tab)
  (setq tuareg-library-path "/usr/lib/ocaml/3.08/")

Here is my browser function:

(defun phl-browser-new-tab (url)
   (start-process-shell-command
     "firefox" nil
      (concat "firefox -remote 'openURL (" url  ", new-tab)' || firefox 
" url)
))
it opens a new tab if firefox has yet been started, and starts a new 
firefox if not.

Also more lines in .emacs are necessary to make Emacs behave more like a 
non Unix geek would expect.

And mozcaml Sidebar for Firefox can be said a must have.

You can't expect a new bie to do all that.

My  provisionnal answer is  making a Linux live CD for my students with 
all that; much work, only x86 and not a way to  really install the OS.

Better ideas ? Making a ocaml-goodies-for-newbies package which  would 
include all this customizations ?

Ph. L.

  

 


^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2005-01-15 12:29 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-12-24  8:58 Wishes for an easy install of Ocaml Philippe Lelédy
2004-12-24 11:04 ` [Caml-list] " Stefano Zacchiroli
2004-12-24 11:36   ` skaller
2004-12-27 15:18   ` Ralf Treinen
2004-12-27 16:54     ` Sven Luther
2004-12-31 16:20       ` Richard Jones
2004-12-31 22:31         ` Sven Luther
2005-01-15 12:29           ` Lionel Elie Mamane
2005-01-02  1:21         ` Jacques Garrigue
2005-01-02 10:50           ` Richard Jones
2005-01-02 11:13             ` Janne Hellsten
2005-01-02 12:16             ` Jacques GARRIGUE
2005-01-02 15:44           ` tuareg-mode v.s. caml-mode (was: Wishes for an easy install of Ocaml) Christophe TROESTLER
2004-12-24 11:22 ` [Caml-list] Wishes for an easy install of Ocaml Christophe TROESTLER
2004-12-24 17:24 ` Sylvain LE GALL
2004-12-24 18:21 ` Matthew O'Connor
2004-12-27 16:35 ` Didier Remy

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).