From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@sympa.inria.fr Delivered-To: caml-list@sympa.inria.fr Received: from mail3-relais-sop.national.inria.fr (mail3-relais-sop.national.inria.fr [192.134.164.104]) by sympa.inria.fr (Postfix) with ESMTPS id 2EC337EE49 for ; Thu, 19 Sep 2013 12:50:43 +0200 (CEST) Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of rdicosmo@gmail.com) identity=pra; client-ip=74.125.82.177; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="rdicosmo@gmail.com"; x-sender="rdicosmo@gmail.com"; x-conformance=sidf_compatible Received-SPF: Pass (mail3-smtp-sop.national.inria.fr: domain of rdicosmo@gmail.com designates 74.125.82.177 as permitted sender) identity=mailfrom; client-ip=74.125.82.177; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="rdicosmo@gmail.com"; x-sender="rdicosmo@gmail.com"; x-conformance=sidf_compatible; x-record-type="v=spf1" Received-SPF: None (mail3-smtp-sop.national.inria.fr: no sender authenticity information available from domain of postmaster@mail-we0-f177.google.com) identity=helo; client-ip=74.125.82.177; receiver=mail3-smtp-sop.national.inria.fr; envelope-from="rdicosmo@gmail.com"; x-sender="postmaster@mail-we0-f177.google.com"; x-conformance=sidf_compatible X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AmkCACvWOlJKfVKxlGdsb2JhbABbgz9Mu3OGYBYOAQEBAQcLCwkSKoIlAQEFDCYBDQEUExEBAwwBBQUYCQwZDwUgAQUBASETCYdoAw8EAwWbYI9YhDEnDYlcAQUMCo4CFgKBSIMUgQADl3uBMIsWg0dBgWGCbYFnCBc X-IPAS-Result: AmkCACvWOlJKfVKxlGdsb2JhbABbgz9Mu3OGYBYOAQEBAQcLCwkSKoIlAQEFDCYBDQEUExEBAwwBBQUYCQwZDwUgAQUBASETCYdoAw8EAwWbYI9YhDEnDYlcAQUMCo4CFgKBSIMUgQADl3uBMIsWg0dBgWGCbYFnCBc X-IronPort-AV: E=Sophos;i="4.90,936,1371074400"; d="scan'208";a="27391240" Received: from mail-we0-f177.google.com ([74.125.82.177]) by mail3-smtp-sop.national.inria.fr with ESMTP/TLS/RC4-SHA; 19 Sep 2013 12:50:42 +0200 Received: by mail-we0-f177.google.com with SMTP id t60so7677583wes.36 for ; Thu, 19 Sep 2013 03:50:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=sender:date:from:to:cc:subject:message-id:references:mime-version :content-type:content-disposition:content-transfer-encoding :in-reply-to:user-agent; bh=YNBp5U6YyS7vBc9yyGhdHc5yHBJ3cgOGmumcEKFxQfA=; b=c+j5eAK9B/i4OpADhxaN4x/W50PKXn48MqWyTvJv1ddCVpteeGFQCYthKC3CD0qs3F vsWPP7BcYIjfG+4bBFVfesir5aKBIMkvclosoIRGGX+kYtztU1RwOkLby0MKMNOahE8a d102an3UYjjWkkh4QlL3LgXjTy2o335s0eburWw3pdOmEjTZy5vp6jNHJpEJOT3ToIU9 dPOkzAy8dy8QQEq9DTXc+rnGZ7IZomvl1HSyaN1UZtqiCc39CVUOWLTeAwxI8BpF7VZA V4ohhZIFi1kJ/QSAy8PFoqPabUB+hzs4cy+r10wueK+/jcukPw1ep67SMEwZlBt9P5mV M2sA== X-Received: by 10.180.185.97 with SMTP id fb1mr729381wic.61.1379587842044; Thu, 19 Sep 2013 03:50:42 -0700 (PDT) Received: from voyager (maths.r-prg.net.univ-paris7.fr. [81.194.27.158]) by mx.google.com with ESMTPSA id e5sm17894077wiy.2.1969.12.31.16.00.00 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Thu, 19 Sep 2013 03:50:40 -0700 (PDT) Sender: Roberto Di Cosmo Received: from dicosmo by voyager with local (Exim 4.80) (envelope-from ) id 1VMbol-0001HA-Oe; Thu, 19 Sep 2013 12:50:39 +0200 Date: Thu, 19 Sep 2013 12:50:39 +0200 From: Roberto Di Cosmo To: Dagnat Fabien Cc: "caml-list@inria.fr" Message-ID: <20130919105039.GA27278@voyager> References: MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: User-Agent: Mutt/1.5.20 (2009-06-14) Subject: Re: [Caml-list] Opam use for teaching lab infrastructure Hi Fabien, we have been using opam last year in the advanced functional programming course here at Paris Diderot, and we were confronted to issues similar to yours. Here are some lesson learnt: On the student laptops ---------------------- The students *love* opam once they have it installed properly on their machines! But getting opam up and running on a random laptop of a student can be quite a challenge, though: - opam packages are not available/up to date for all distros - the opam binary installer is only available for 64-bit machines, so one may end up needing to recompile it, but there many things can go wrong: some machines do not have the proper development libraries/tools to compile OCaml/opam, and the students need help when they are left with a failed ./configure; some other students may install the OCaml package from the GNU/Linux distribution, then compile opam, and then start using opam with the OCaml installed globally, which can lead to great confusion when they start mixing up the ocamlfind from opam with the ocamlfind from the distribution. - My suggestion is to tell them clearly to compile opam, then perform an opam switch to (re)compile an opam-local version of OCaml, and then religiously stick to it, by putting the eval `opam config -env` in their bash/chs/whatever init script (opam does a pretty good job to detect the running shell and exporting the right parameters). You may need to help them installing the necessary development environment (gcc, m4, devl libraries, etc.), I do not know how to avoid this on a random laptop :-( On the machines in the lab -------------------------- Unfortunately, our students have a pretty low quota (you might wonder why, when Seagate is working on 5TB disks that will cost just a few hundred bucks, but that's another story), so we could not afford a local opam repo for each student. Instead, we just use a specific account where opam is installed locally, and then tell the students to use eval `opam config -env --root=/path/to/the/shared/.opam/dir` This way it's easy to add new libraries, visible to all the students, with no need to bother the sysadmin, but of course, they cannot play with different libraries by themselves. You will probably need to carefully set the rights on the shared .opam repo to make this work. Hope this helps! -- Roberto On Thu, Sep 19, 2013 at 11:38:41AM +0200, Dagnat Fabien wrote: > Hello, > I'm teaching (basic) functional programming and (simple) compilation in ocaml > (to master students). Currently, I ask the system administrators to install a > basic ocaml package. I'm thinking on switching to opam to make it easier for > students to experiment various libraries. > > Does anyone has used opam for labs with student? I would be glad to hear any > report on this mainly on the following points: > - Is opam really usable when you keep changing of machine? > - Having a .opam for all student accounts seem interesting so that they can > freely experiment without interfering with others but has the cost of > duplicating lot of common files. Any thoughts? > - What is the usual size of an .opam directory? Mine is 1G but I don't know if > it's usual. > - What kind of ocaml libs do you introduce to the students? I was thinking of > utop, ounit, core / batteries, menhir. > > Thanks in advance > Fabien > > > Fabien DAGNAT > Maître de conférences au département informatique > Responsable de la filière Systèmes Logiciels et Réseaux > Télécom Bretagne Tél. : (0 | 33) 2 29 00 14 09 > Technopôle Brest-Iroise, CS 83818 > 29238 Brest Cedex 3, France > Site web Télécom BretagneBlog Télécom Bretagne > Une école de l'Institut Mines-Télécom > > -- Roberto Di Cosmo ------------------------------------------------------------------ Professeur En delegation a l'INRIA PPS E-mail: roberto@dicosmo.org Universite Paris Diderot WWW : http://www.dicosmo.org Case 7014 Tel : ++33-(0)1-57 27 92 20 5, Rue Thomas Mann F-75205 Paris Cedex 13 Identica: http://identi.ca/rdicosmo FRANCE. Twitter: http://twitter.com/rdicosmo ------------------------------------------------------------------ Attachments: MIME accepted, Word deprecated http://www.gnu.org/philosophy/no-word-attachments.html ------------------------------------------------------------------ Office location: Bureau 3020 (3rd floor) Batiment Sophie Germain Avenue de France Metro Bibliotheque Francois Mitterrand, ligne 14/RER C ----------------------------------------------------------------- GPG fingerprint 2931 20CE 3A5A 5390 98EC 8BFC FCCA C3BE 39CB 12D3