|
Subject: Wishes for an easy install of Ocaml Newsgroups: gmane.comp.lang.caml.inria Date: 2004-12-24 08:58:58 GMT (5 years, 6 weeks, 5 days, 11 hours and 26 minutes ago)
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.
_______________________________________________
Caml-list mailing list. Subscription management:
http://yquem.inria.fr/cgi-bin/mailman/listinfo/caml-list
Archives: http://caml.inria.fr
Beginner's list: http://groups.yahoo.com/group/ocaml_beginners
Bug reports: http://caml.inria.fr/bin/caml-bugs
|
|
|