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=2.6 required=5.0 tests=AWL,DNS_FROM_RFC_POST, SPF_NEUTRAL 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 6FA6DBBAF for ; Thu, 26 Feb 2009 14:05:46 +0100 (CET) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ApUGAOAhpknRVdypYGdsb2JhbACUOjUXCA0HDrMckEEBAwEDhA4GgmSBfg X-IronPort-AV: E=Sophos;i="4.38,271,1233529200"; d="scan'208";a="24715336" Received: from mail-fx0-f169.google.com ([209.85.220.169]) by mail1-smtp-roc.national.inria.fr with ESMTP; 26 Feb 2009 14:05:46 +0100 Received: by fxm17 with SMTP id 17so591033fxm.27 for ; Thu, 26 Feb 2009 05:05:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:sender:message-id:from:to :in-reply-to:content-type:content-transfer-encoding:mime-version :subject:date:references:x-mailer; bh=uE++BERqzmi492gFyevBd92cYhajLC3f0hnRgAM03PQ=; b=Z6mpW+kjIewXF9Kfx54SF1YSGZkuLj8ntSR7o3sFxIwBZBr5njSsC+wk2pjuyyPwtt GksA8iJYIE84KfFt0QpsyaxYYvx9aTr+Y+I0rn31Xi6m7qcG7FYtOPFT6orXDr1f6YJS 5k3ipVeItG436U9QAfF0FvaEKkfK7MxklYx4A= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=sender:message-id:from:to:in-reply-to:content-type :content-transfer-encoding:mime-version:subject:date:references :x-mailer; b=P3br4pQ4LKQRGuaAYDRf7UGh4esdosHha2g/BjcpgFHUvgu8v13XAc7R8OKXdbFm5t ndw1CCkCJHqw7EeNuLntDCc61J9f2wNirsDcG3/o3ewwnM1+D2ABPfmBy5hVvrYy2jtt Ax8PhS5X6Z9pSRW7SOZV1F734L+Ta3tAXefIU= Received: by 10.223.126.69 with SMTP id b5mr2096844fas.34.1235653545726; Thu, 26 Feb 2009 05:05:45 -0800 (PST) Received: from ?192.168.1.34? (100-227.77-83.cust.bluewin.ch [83.77.227.100]) by mx.google.com with ESMTPS id p9sm14563238fkb.21.2009.02.26.05.05.44 (version=TLSv1/SSLv3 cipher=RC4-MD5); Thu, 26 Feb 2009 05:05:45 -0800 (PST) Sender: =?UTF-8?Q?Daniel_B=C3=BCnzli?= Message-Id: From: =?ISO-8859-1?Q?Daniel_B=FCnzli?= To: OCaml List In-Reply-To: <231BADDB-F88E-4A3D-994B-863579C20810@erratique.ch> Content-Type: text/plain; charset=ISO-8859-1; format=flowed; delsp=yes Content-Transfer-Encoding: quoted-printable Mime-Version: 1.0 (Apple Message framework v930.3) Subject: Re: [Caml-list] ocamlbuild & deps Date: Thu, 26 Feb 2009 14:04:56 +0100 References: <499ECEB7.6010709@lri.fr> <49A04DAE.6010109@lri.fr> <231BADDB-F88E-4A3D-994B-863579C20810@erratique.ch> X-Mailer: Apple Mail (2.930.3) X-Spam: no; 0.00; bunzli:01 buenzli:01 deps:01 bunzli:01 dependencies:01 deps:01 dependencies:01 nodes:01 simulate:01 vice-versa:01 simulate:01 caml-list:01 argument:02 argument:02 tree:02 Le 21 f=E9vr. 09 =E0 21:19, Daniel B=FCnzli a =E9crit : > If the above is true then I think it would be usefull to mention =20 > this in the documentation about the 'build' argument. It seems to be false. Suppose we have the following dependencies ("->" =20= is "depends") A -> {B, C} B -> {B1, B2} C -> {C1, C2} The idea is that ocamlbuild will take the static ~deps of the rules =20 and construct a first tree of dependencies. Given this tree, =20 ocamlbuild will start to build the dependencies from the leaves; I =20 wasn't able to get precise information about how the nodes of this =20 tree are followed but what seems to be sure is that it will try to =20 build all the leaves first, thus some order exists. This means that =20 for the example above if all dependencies are known via ~deps =20 arguments the build order is going to be something like this (at least =20= that would be the most sensible way of doing it, breadth-first order =20 reversed). (B1 || B2 || C1 || C2); (C || B); A where "||" is parallel, and ";" is sequencing. Now if you try to simulate the static dependencies ~deps as I =20 suggested in my last email. The build order you will get is : (((B1 || B2); B) || ((C1 || C2); C)); A and this order will give you different results when B can be built but =20= C cannot (or vice-versa) as in that case you will build B (or C) =20 whereas it won't be with static dependencies. Hence the conclusion is =20= that you cannot simulate the ~deps argument as I suggested in my last =20= email. Best, Daniel=