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 mail1-relais-roc.national.inria.fr (mail1-relais-roc.national.inria.fr [192.134.164.82]) by sympa.inria.fr (Postfix) with ESMTPS id 385D87ED34 for ; Tue, 17 Jul 2012 09:00:37 +0200 (CEST) X-IronPort-AV: E=Sophos;i="4.77,599,1336341600"; d="scan'208";a="167104231" Received: from zmbs4.inria.fr ([128.93.142.17]) by mail1-relais-roc.national.inria.fr with ESMTP; 17 Jul 2012 09:00:37 +0200 Date: Tue, 17 Jul 2012 09:00:37 +0200 (CEST) From: Xavier Clerc To: Francois Berenger , caml-list@inria.fr Cc: xavier clerc Message-ID: <1657861881.12110434.1342508437161.JavaMail.root@inria.fr> In-Reply-To: <5004F744.5070600@riken.jp> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Originating-IP: [128.93.57.40] X-Mailer: Zimbra 7.2.0_GA_2669 (ZimbraWebClient - SAF3 (Mac)/7.2.0_GA_2669) Subject: Re: [Caml-list] ocamlbuild generates .annot files in _build ----- Mail original ----- > On 07/17/2012 02:12 PM, Francois Berenger wrote: > > Hello, > > > > Shouldn't it generate theses files where the source files > > are? > > > > The emacs plugin can no more find the types in case > > the .annot files are not where the source file is. > > Also, the preprocessor INCLUDE directives don't work anymore because > ocamlbuild did not copy the .ml file to include in _build. > > You have to use INCLUDE "../[your_file]" instead, which is dirty. I don't know if you will find my suggestion clean, but when I encounter a similar problem I design an ocamlbuild plugin that just copies the file to the build directory. This will avoid relying upon a relative path, and fits ocamlbuild structure by just declaring a dependency and a rule to barely copy the file from its original place to the build directory. Notice that this is akin to what ocamlbuild actually does for source file, the only difference is that ocamlbuild cannot determine the dependency in your case. Hence, you have to declare it manually. Hope this helps, Xavier Clerc