From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by yquem.inria.fr (Postfix) with ESMTP id E7DBEBCA2 for ; Fri, 12 Aug 2005 17:17:02 +0200 (CEST) Received: from pauillac.inria.fr (pauillac.inria.fr [128.93.11.35]) by nez-perce.inria.fr (8.13.0/8.13.0) with ESMTP id j7CFH2Bb017110 for ; Fri, 12 Aug 2005 17:17:02 +0200 Received: from nez-perce.inria.fr (nez-perce.inria.fr [192.93.2.78]) by pauillac.inria.fr (8.7.6/8.7.3) with ESMTP id RAA18420 for ; Fri, 12 Aug 2005 17:17:02 +0200 (MET DST) Received: from furbychan.cocan.org (furbychan.cocan.org [80.68.91.176]) by nez-perce.inria.fr (8.13.0/8.13.0) with ESMTP id j7CFH0Z0017103 (version=TLSv1/SSLv3 cipher=EDH-RSA-DES-CBC3-SHA bits=168 verify=NO) for ; Fri, 12 Aug 2005 17:17:01 +0200 Received: from rich by furbychan.cocan.org with local (Exim 3.35 #1 (Debian)) id 1E3bSN-0001Zi-00 for ; Fri, 12 Aug 2005 16:28:27 +0100 Date: Fri, 12 Aug 2005 16:28:27 +0100 To: caml-list@inria.fr Subject: Usability problems with ocamlmktop / toplevels Message-ID: <20050812152827.GA4162@furbychan.cocan.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.3.28i From: Richard Jones X-Miltered: at nez-perce with ID 42FCBD6E.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Miltered: at nez-perce with ID 42FCBD6C.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Spam: no; 0.00; ocamlmktop:01 toplevels:01 toplevel:01 toplevel:01 toplevels:01 'ocaml:01 foo:01 ml':01 'foo:01 ml':01 ocamlfind:01 ocamlmktop:01 -custom:01 -package:01 netclient:01 X-Spam-Checker-Version: SpamAssassin 3.0.3 (2005-04-27) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=disabled version=3.0.3 I'm experimenting with building a custom toplevel, but have run across some problems. (1) I want to have some modules 'open' already in the toplevel - we have lots and lots of modules, some with long names, and most of these should be opened by default. The partial solution is to add lots of 'open' statements to a .ocamlinit file in the current directory, but this assumes that you know what the current directory is, and that you only need to use one type of toplevel in that directory. (2) Toplevels don't work the same way as 'ocaml'. The difference is that our custom toplevel ignores any command line arguments passed to it, whereas 'ocaml foo.ml' runs 'foo.ml'. This means that we can't use our toplevel to write scripts: #!./adwords (or variations we've tried) doesn't work. (3) Some libraries are linked into the toplevel, but apparently can't be accessed. For instance, Calendar ExtLib must be linked into the toplevel because our main code relies on them; however no symbols from either are visible: $ ./adwords Objective Caml version 3.08.2 # Date.today ();; Unbound value Date.today # open Date;; Unbound module Date # ExtString.String.split;; Unbound value ExtString.String.split Rich. PS. This is how we build the toplevel: ocamlfind ocamlmktop -custom -package pxp-lex-iso88591,pxp-engine,netclient,netstring,extlib,pcre,calendar -I ../ocsoap -I ../csv -linkpkg ../ocsoap/oCSoap.cmo ../csv/csv.cma adwords.cma -o adwords -- Richard Jones, CTO Merjis Ltd. Merjis - web marketing and technology - http://merjis.com Team Notepad - intranets and extranets for business - http://team-notepad.com