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=1.7 required=5.0 tests=AWL,DNS_FROM_RFC_ABUSE, DNS_FROM_RFC_POST autolearn=disabled version=3.1.3 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 E9AEABBAF for ; Wed, 8 Jul 2009 12:35:47 +0200 (CEST) X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: AskBAKsTVEpDww/NmGdsb2JhbACRKodkAQEBAQEICQwHE6Q8gRqRNAEFAwGEBAU X-IronPort-AV: E=Sophos;i="4.42,368,1243807200"; d="scan'208";a="30852432" Received: from web111513.mail.gq1.yahoo.com ([67.195.15.205]) by mail3-smtp-sop.national.inria.fr with SMTP; 08 Jul 2009 12:35:45 +0200 Received: (qmail 5919 invoked by uid 60001); 8 Jul 2009 10:35:43 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s1024; t=1247049343; bh=ZHTqjHFtdQT9M2oOf28KENfxbracNtBBjp1lLNr0nHk=; h=Message-ID:X-YMail-OSG:Received:X-Mailer:Date:From:Subject:To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=ndNwqvwHBEm6mqJywqg8hNWw8Zk65cqd1L+VCFrx3EQ2N1Iy6yaLffDd7UqkQkBD/ZcZMzkn9uAvkmr22B5UM2ZA1KanNYV7Rpx8TxZ/xg6B5AI0auQXrIgO2Esg364X3+vxXKuloK/6bdmoKTemuOuEhwsrzx0Ib8gn0+lhGac= DomainKey-Signature:a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=Message-ID:X-YMail-OSG:Received:X-Mailer:Date:From:Subject:To:MIME-Version:Content-Type:Content-Transfer-Encoding; b=kpQR3KYStVGFCsZIOBjzlj55FZU0BpTXNimFw++bcBDULKhEPDrCPGbG6YiDF18JDWI2JZMimEV2Z8j1SKP4MXZ7LLTI+snxXf8kHC8jDYstYuOpR3eASfPIRKQup11QYtHXnDWgUGh199nsoIcie6hD91nVPqagU6e++A/sdt8=; Message-ID: <379032.5491.qm@web111513.mail.gq1.yahoo.com> X-YMail-OSG: psfYzhMVM1lGyDBzi8U4Li6bUmXI.rcwba8rFh7dk5rmv0pRUQKgn.yO7H8gWUl6_TTSIZPwVVPcKGQYmPDfc_rPGieDiLy0u1dpdVxeS63o5_CqKOoIdtX4gFPO0AnsmvjkgMecoyP22a4MNJz.S8BvN2zySNyZYlsL_t6cH7rc43.XtL8o2O.XeT6Eex8X.lf12iNrKVtcM_ebhfAGeH9oBItFKfC5jym.EMneokqvmXPz3_xLwZ5gtqVsG0CACDkEQD6k3a1_vWYuy31IvFhYEKeY5d1bE4rmf.0jgQbjfSz69Jk5AwiyC6uwsMQkMS1oHzg- Received: from [213.205.71.48] by web111513.mail.gq1.yahoo.com via HTTP; Wed, 08 Jul 2009 03:35:43 PDT X-Mailer: YahooMailClassic/5.4.17 YahooMailWebService/0.7.289.15 Date: Wed, 8 Jul 2009 03:35:43 -0700 (PDT) From: Dario Teixeira Subject: Re: [Caml-list] Virtual packages in findlib To: caml-list@yquem.inria.fr, Stefano Zacchiroli MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam: no; 0.00; findlib:01 dependencies:01 findlib:01 dependencies:01 re-order:01 cheers:01 caml-list:01 dependency:01 dependency:01 preserve:03 latter:03 explicit:04 depends:04 hack:04 problem:05 Hi,=0A=0A> Can you explain that? I don't see why virtual packages can resol= ve=0A> ordering problems.=0A=0ABecause without virtual packages, one cannot= list the true dependencies=0Aof a package, thus causing ordering problems.= =0A=0AConsider the minimal example of there being two packages: A and B, wi= th=0AB depending on A, and therefore having to be linked after. However, A= is=0Anot a real package, but instead a virtual one instantiated by either= =0AA1, A2, A3, etc.=0A=0ABut alas, there is no virtual package support in f= indlib (I assume).=0ABecause of this, the META file for B does not list A a= s a dependency.=0A(Yes, the META is "wrong", but how could it be made right= ?)=0A=0ANow, we tell ocamlbuild that the project depends on A1 (for instanc= e) and B.=0ABecause there is no *declared* dependency between A1 and B (tho= ugh in fact=0Athere should be), ocamlbuild probably assumes that it is indi= fferent to=0Alink "A1; B" or "B; A1". However, the latter case will cause = an error.=0A=0ATherefore, there are two solutions to this problem:=0A=0Aa) = Make ocamlbuild preserve the order of the given packages *when there=0A i= s no explicit dependency among them*. (Obviously if there are dependencies= =0A then Ocamlbuild should re-order the packages as fit).=0A=0Ab) Find so= me virtual package mechanism in findlib (thus rendering the=0A hack a) mo= ot).=0A=0ACheers,=0ADario Teixeira=0A=0A=0A=0A