From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.1.3 (2006-06-01) on yquem.inria.fr X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=none autolearn=disabled version=3.1.3 X-Original-To: caml-list@yquem.inria.fr Delivered-To: caml-list@yquem.inria.fr Received: from mail1-relais-roc.national.inria.fr (mail1-relais-roc.national.inria.fr [192.134.164.82]) by yquem.inria.fr (Postfix) with ESMTP id D9288BBAF for ; Fri, 9 Jan 2009 15:06:49 +0100 (CET) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Aj4CAEvpZkmVnFmTgWdsb2JhbACUEQEBFiKwPoVchSaFbw X-IronPort-AV: E=Sophos;i="4.37,239,1231110000"; d="scan'208";a="22224212" Received: from mail.uj.edu.pl ([149.156.89.147]) by mail1-smtp-roc.national.inria.fr with ESMTP; 09 Jan 2009 15:06:27 +0100 MIME-version: 1.0 Content-transfer-encoding: 7BIT Content-type: text/plain; charset=ISO-8859-1; format=flowed Received: from [137.73.5.196] by mail.uj.edu.pl (Sun Java(tm) System Messaging Server 6.3-5.02 (built Oct 12 2007; 32bit)) with ESMTPA id <0KD7007IQJ6PSHD0@mail.uj.edu.pl> for caml-list@yquem.inria.fr; Fri, 09 Jan 2009 15:06:26 +0100 (CET) X-Antivirus-Code: 100000 X-Antivirus: Dr.Web (R) for Mail Servers on pandora host Message-id: <496759E1.3070104@uj.edu.pl> Date: Fri, 09 Jan 2009 14:06:25 +0000 From: Dawid Toton User-Agent: Thunderbird 1.5.0.12 (X11/20090107) To: caml-list@yquem.inria.fr Subject: Toplevel - load cmo from given location X-Spam: no; 0.00; toplevel:01 cmo:01 usr:01 ocamlrun:01 ocaml:01 enum:01 cmo:01 enum:01 usr:01 ocamlrun:01 ocaml:01 cmi:01 cmi:01 toplevel:01 unbound:01 I've noticed stange behaviour: The following works OK (using #directory directive): #!/usr/bin/ocamlrun ocaml #directory "/home/dt2/Calc1/CalcEngine/src/_build/extlib/" #load "enum.cmo" open Enum But this version not (using the full path directly): #!/usr/bin/ocamlrun ocaml #load "/home/dt2/Calc1/CalcEngine/src/_build/extlib/enum.cmo" open Enum The problem is that it gives "Unbound module Enum" while no error about loading the cmo&cmi is shown. So: * if it finds correctly the enum.cmi: why "open Enum" doesn't work? * if the cmi is not found, why I see no message like "*Cannot find file */home/dt2/Calc1/CalcEngine/src/_build/extlib/enum.cmi*" - as chapter 9.4 of docs suggests? Does the toplevel check for the cmi in the same location as cmo? * (I tested this with the cmi file existing there as built by ocamlbuild) Dawid