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 discorde.inria.fr (discorde.inria.fr [192.93.2.38]) by yquem.inria.fr (Postfix) with ESMTP id 86F5BBC69 for ; Wed, 11 Apr 2007 08:58:52 +0200 (CEST) Received: from out4.smtp.messagingengine.com (out4.smtp.messagingengine.com [66.111.4.28]) by discorde.inria.fr (8.13.6/8.13.6) with ESMTP id l3B6wp4j030609 for ; Wed, 11 Apr 2007 08:58:52 +0200 Received: from compute2.internal (compute2.internal [10.202.2.42]) by out1.messagingengine.com (Postfix) with ESMTP id 8EAEF216D03; Wed, 11 Apr 2007 02:59:12 -0400 (EDT) Received: from heartbeat1.messagingengine.com ([10.202.2.160]) by compute2.internal (MEProxy); Wed, 11 Apr 2007 02:58:52 -0400 X-Sasl-enc: 9xp89XR4ROQIrV0UHZS4vh+FO5VRA0xOlbqb8dBY8I1H 1176274731 Received: from adsl-75-3-207-61.dsl.sndg02.sbcglobal.net (adsl-75-3-207-61.dsl.sndg02.sbcglobal.net [75.3.207.61]) by mail.messagingengine.com (Postfix) with ESMTP id C26761C9BE; Wed, 11 Apr 2007 02:58:51 -0400 (EDT) Date: Tue, 10 Apr 2007 23:58:43 -0700 (PDT) From: Martin Jambon X-X-Sender: martin@droopy To: Jeff Henrikson Cc: caml-list@inria.fr Subject: Re: [Caml-list] nonresolved .cma files and errors In-Reply-To: <461C50C7.6090802@yahoo.com> Message-ID: References: <461C50C7.6090802@yahoo.com> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Miltered: at discorde with ID 461C872B.001 by Joe's j-chkmail (http://j-chkmail . ensmp . fr)! X-Spam: no; 0.00; ens-lyon:01 henrikson:01 camlp:01 camlp:01 notation:01 cmo:01 jehenrik:01 ocamlc:01 -pp:01 functor:01 jehenrik:01 ocamlc:01 -pp:01 cmo:01 functor:01 On Tue, 10 Apr 2007, Jeff Henrikson wrote: > Hello caml-list, > > I recently had a shocking realization about why some of my experiments with > camlp4 weren't compiling. I had been linking camlp4.cma, which was the old > name of the library. Now camlp4.cma doesn't exist and there are multiple > flavors Camlp4xxx.cma where the xxx is the same flavor notation of the the > preprocessor binaries. So the trouble is, why was linking such a library not > a fatal? Apparently all missing .cma and .cmo files passed on the command > line are considered non-errors. It seems intutive to me that both should be > fatals! > > ~/src/camlp4-beta jehenrik$ ocamlc -I +camlp4 -pp camlp4orf junk.cma > camlp4orf.cma -c dynamic_functor_example3.ml > ~/src/camlp4-beta jehenrik$ ocamlc -I +camlp4 -pp camlp4orf junk.cmo > camlp4orf.cma -c dynamic_functor_example3.ml > ~/src/camlp4-beta jehenrik$ ocamlc -I +camlp4 -pp camlp4orf junk.ml > camlp4orf.cma -c dynamic_functor_example3.ml > I/O error: "junk.ml: No such file or directory" > Preprocessor error In general, a syntax extension that (like before) uses quotations in the revised syntax would be compiled using such a command: ocamlc -c -I +camlp4 -pp camlp4orf pa_foo.ml It replaces ocamlc -c -I +camlp4 -pp 'camlp4o pa_extend.cmo q_MLast.cmo' pa_foo.ml There might be some slight error in the commands I just wrote (it happens). You can have a look at my updated json-static package that you'll find on my web site. It supports both the old and the new camlp4, and it works for sure with 3.10.0+beta [it uses two different source files of course]. Martin -- Martin Jambon http://martin.jambon.free.fr