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 mail3-relais-sop.national.inria.fr (mail3-relais-sop.national.inria.fr [192.134.164.104]) by yquem.inria.fr (Postfix) with ESMTP id C90BFBC37 for ; Mon, 22 Feb 2010 17:11:59 +0100 (CET) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Av8BACs7gkvRVdvUkGdsb2JhbACRHIlfCBUBAQEBCQkMBxMDH6xugVmEUYhyAQEDBYRmBIMV X-IronPort-AV: E=Sophos;i="4.49,518,1262559600"; d="scan'";a="45397817" Received: from mail-ew0-f212.google.com ([209.85.219.212]) by mail3-smtp-sop.national.inria.fr with ESMTP; 22 Feb 2010 17:11:59 +0100 Received: by ewy4 with SMTP id 4so366592ewy.7 for ; Mon, 22 Feb 2010 08:11:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:message-id:date:notmuch-help :notmuch-help:notmuch-help:notmuch-help:from:subject:to:cc :in-reply-to:references; bh=jx1vBECI56i9W9mClxJ9U7uLRUEXDz3TwmyzoStWVLc=; b=lCpDVAhQpKd6b6mAUgY90mG1cY20DvIZwOHfgOENPrM2mxdwkS+umHCSSFEI4g2Opw as8D0mZOWPiNAiORlLHHdaFceORsXscyuckVzDdHfRiUd+risX0xsv8BJox6fKSGA/0U znLwxd5A4Tg9njJTzVBOumNkvq2xG+rrBceys= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=message-id:date:notmuch-help:from:subject:to:cc:in-reply-to :references; b=tOcX3E7TIrs6XqjhVajfps5NlfSVGDSKeeERMRHNb8cKdZ7HsLmM28gXdcSAQdWf0P MySM1TPgrFbfYXtpMRL8tLofaS4VsLzLKOLqGyoLoYrJaFw+VFQC2D1LzUUmzBEg3Lq5 oLuMyZl3MfCh69UxI4pRu2GieYIQi0I6ikEqg= Received: by 10.213.53.71 with SMTP id l7mr4459317ebg.10.1266855114486; Mon, 22 Feb 2010 08:11:54 -0800 (PST) Received: from localhost (ks.feydakins.org [91.121.104.209]) by mx.google.com with ESMTPS id 16sm2517179ewy.14.2010.02.22.08.11.52 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 22 Feb 2010 08:11:53 -0800 (PST) Message-ID: <4b82acc9.1067f10a.2adf.ffffc714@mx.google.com> Date: Mon, 22 Feb 2010 08:11:53 -0800 (PST) Notmuch-Help: ,a - attach a file Notmuch-Help: ,s - send the message (Notmuch-Help lines will be removed) Notmuch-Help: ,q - abort the message Notmuch-Help: - skip through header lines From: Nicolas Pouillard Subject: Re: [Caml-list] ocamlbuild - how to force the rebuilding of a target inside a plugin? To: Vincent Aravantinos Cc: caml-list@yquem.inria.fr In-Reply-To: <4807FA06-9ECF-4EA9-81CA-23059F35E235@gmail.com> References: <2511B816-C3D0-4DA1-8465-19DF43CDF587@gmail.com> <4b828a63.1067f10a.27f2.ffffbdf8@mx.google.com> <4807FA06-9ECF-4EA9-81CA-23059F35E235@gmail.com> X-Spam: no; 0.00; rebuilding:01 0100,:01 0100,:01 rebuilt:01 concretely:01 compilation:01 recompile:01 compilation:01 simulated:01 rubber:98 wrote:01 wrote:01 compile:01 caml-list:01 dependency:01 On Mon, 22 Feb 2010 15:30:14 +0100, Vincent Aravantinos wrote: > > Le 22 févr. 10 à 14:45, Nicolas Pouillard a écrit : > > > On Sun, 21 Feb 2010 23:15:09 +0100, Vincent Aravantinos > > wrote: > >> Hi list, > >> > >> does anybody (Nicolas?) knows if it is possible to force a target to > >> be rebuilt from within an ocamlbuild plugin? > >> > >> Concretely I am making a plugin for LaTeX compilation and would like > >> to say to ocamlbuild: > >> "first compile the source, then if the .aux file has changed then > >> recompile it". > > > > I would suggest to not try to bypass the dependency system and to > > instead > > try to make a rule that fits ocamlbuild mechanism. However the simpler > > is maybe to call a tool which does this job like rubber. > > Great, I didn't know of this tool! I'll use it. > > Still, would have it been possible to make a dependency on the .aux > file such that ocamlbuild can be aware that this file changed in order > to launch a new compilation? No there is no such behavior, but this may be simulated by having two rules, one .tex->.aux+... and one .tex+.aux->... and putting them in the right order might work. -- Nicolas Pouillard http://nicolaspouillard.fr