From: Dario Teixeira <darioteixeira@yahoo.com>
To: caml-list@yquem.inria.fr, Stefano Zacchiroli <zack@upsilon.cc>
Subject: Re: [Caml-list] Virtual packages in findlib
Date: Wed, 8 Jul 2009 03:35:43 -0700 (PDT) [thread overview]
Message-ID: <379032.5491.qm@web111513.mail.gq1.yahoo.com> (raw)
Hi,
> Can you explain that? I don't see why virtual packages can resolve
> ordering problems.
Because without virtual packages, one cannot list the true dependencies
of a package, thus causing ordering problems.
Consider the minimal example of there being two packages: A and B, with
B depending on A, and therefore having to be linked after. However, A is
not a real package, but instead a virtual one instantiated by either
A1, A2, A3, etc.
But alas, there is no virtual package support in findlib (I assume).
Because of this, the META file for B does not list A as a dependency.
(Yes, the META is "wrong", but how could it be made right?)
Now, we tell ocamlbuild that the project depends on A1 (for instance) and B.
Because there is no *declared* dependency between A1 and B (though in fact
there should be), ocamlbuild probably assumes that it is indifferent to
link "A1; B" or "B; A1". However, the latter case will cause an error.
Therefore, there are two solutions to this problem:
a) Make ocamlbuild preserve the order of the given packages *when there
is no explicit dependency among them*. (Obviously if there are dependencies
then Ocamlbuild should re-order the packages as fit).
b) Find some virtual package mechanism in findlib (thus rendering the
hack a) moot).
Cheers,
Dario Teixeira
next reply other threads:[~2009-07-08 10:35 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-07-08 10:35 Dario Teixeira [this message]
2009-07-13 22:55 ` Gerd Stolpmann
2009-07-14 20:47 ` Dario Teixeira
-- strict thread matches above, loose matches on Subject: below --
2009-07-07 18:07 Dario Teixeira
2009-07-08 7:41 ` [Caml-list] " Stefano Zacchiroli
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=379032.5491.qm@web111513.mail.gq1.yahoo.com \
--to=darioteixeira@yahoo.com \
--cc=caml-list@yquem.inria.fr \
--cc=zack@upsilon.cc \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox