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 52648D45F for ; Mon, 31 Oct 2005 10:26:58 +0100 (CET) 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 j9V9QvsC003845 for ; Mon, 31 Oct 2005 10:26:57 +0100 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 KAA02963 for ; Mon, 31 Oct 2005 10:26:56 +0100 (MET) Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.126.190]) by nez-perce.inria.fr (8.13.0/8.13.0) with ESMTP id j9V9QuvM003842 for ; Mon, 31 Oct 2005 10:26:56 +0100 Received: from [212.227.126.160] (helo=mrelayng.kundenserver.de) by moutng.kundenserver.de with esmtp (Exim 3.35 #1) id 1EWVwC-0002br-00; Mon, 31 Oct 2005 10:26:44 +0100 Received: from [84.58.137.12] (helo=gate.lan.gerd-stolpmann.de) by mrelayng.kundenserver.de with asmtp (Exim 3.35 #1) id 1EWVwC-0001nj-00; Mon, 31 Oct 2005 10:26:44 +0100 Received: from flakew.lan.gerd-stolpmann.de (flakew.lan.gerd-stolpmann.de [192.168.0.32]) by gate.lan.gerd-stolpmann.de (Postfix) with ESMTP id 81349C097; Mon, 31 Oct 2005 11:26:44 +0100 (CET) Subject: Re: [Caml-list] ocamlfind syntax problem From: Gerd Stolpmann To: Pietro Abate Cc: ocaml ml In-Reply-To: <20051031030150.GA601@pulp.anu.edu.au> References: <20051031030150.GA601@pulp.anu.edu.au> Content-Type: text/plain Date: Mon, 31 Oct 2005 10:26:43 +0100 Message-Id: <1130750803.5348.34.camel@localhost.localdomain> Mime-Version: 1.0 X-Mailer: Evolution 2.2.1.1 Content-Transfer-Encoding: 7bit X-Provags-ID: kundenserver.de abuse@kundenserver.de auth:a6865a839c0178d9aa0ce41878507ea2 X-Miltered: at nez-perce with ID 4365E361.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Miltered: at nez-perce with ID 4365E360.000 by Joe's j-chkmail (http://j-chkmail.ensmp.fr)! X-Spam: no; 0.00; caml-list:01 ocamlfind:01 syntax:01 gerd:01 stolpmann:01 ocamlfind:01 syntax:01 ocaml:01 stdlib:01 destdir:01 cmo:01 ocamlc:01 -package:01 ocamlc:01 -package: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.1 required=5.0 tests=FORGED_RCVD_HELO autolearn=disabled version=3.0.3 Am Montag, den 31.10.2005, 14:01 +1100 schrieb Pietro Abate: > Hi all, > > I'm trying to learn how to use ocamlfind with camlp4 syntax files. > > The problem is that my syntax file uses extlib and I get an undefined > reference to ExtLib when I try to compile everything with ocamlfind. > > Since now I've compiled it following these steps: > > 1) I generate the ocaml code from my example using my syntax (with str > and extlib) > # camlp4o $STDLIB/str.cma $DESTDIR/extlib/extLib.cma syntaxfile.cma pr_o.cmo myex.ml > myex-pp.ml > 2) I compile the result using other packages and ocamlfind. > # ocamlfind ocamlc -package mypackages myex-pp.ml > > now I'm trying to skip the intermediate step. Therefore I've created > my meta file that looks like this: > > version = "0.1" > description = "syn file" > requires = "camlp4 extlib" > archive(syntax,preprocessor) = "syntaxfile.cma" > > and I'm trying to link everything together with: > #ocamlfind ocamlc -package mypackages,syntaxfile -syntax syntaxfile myex.ml > > but it complains that syntaxfile.cma has a Reference to undefined global `ExtLib'. That's a known bug. Use -syntax camlp4o,byte as workaround. The problem is that without "byte" all the archive(byte)="..." settings are ignored. Gerd > adding extlib to mypackages doesn't help... > how can I pass $STDLIB/str.cma $DESTDIR/extlib/extLib.cma to the preprocessor > via ocamlfind ? > > :) > p > > ps: my compilation infrastructure is more complex, but I think the > problem boils down to what I've described above. > -- ------------------------------------------------------------ Gerd Stolpmann * Viktoriastr. 45 * 64293 Darmstadt * Germany gerd@gerd-stolpmann.de http://www.gerd-stolpmann.de Telefon: 06151/153855 Telefax: 06151/997714 ------------------------------------------------------------