|
Boost-Build : |
From: Ali Azarbayejani (ali_at_[hidden])
Date: 2003-06-09 09:42:45
Trevor Taylor wrote:
>
>
> In my experience most compilers are sensitive to the order. Also
> the order and repetition required depends on whether shared or
> archive libraries are linked in. The only feasable way to
> handle libraries in a build system (I think) is to allow the
> user to specify exactly the order and repetition they want. (Sometimes
> other flags are interleaved with libraries in a specific order too :-(
I do not completely agree, with respect to library order. I do agree
that the user should ultimately be able to override any aspect of the
system, including link line, but in the case of library order in
particular, we should be able to get it right every time automatically.
In BBv2, we actually KNOW the library dependency order internally
(because we have a full dependency graph representatino), but that
information is not currently being used to order libraries on the link
line. Once this problem is solved, it should be right all the time,
except in certain cases when a dependency between two libraries has not
been properly expressed. When this type of problem occurs, it should be
fixed by the user specifying that dependency between libraries, not
manually messing with the link line.
In the case of co-dependent libraries, first the authors of such
libraries should be summarily executed, but afterward we do need to have
a way of specifying that these libraries must be repeated on the link
line. I believe this could also be solved automatically in the
dependency tree by allowing circular dependencies to be expressed
between libraries. The system could be smart enough to detect these,
cut the loops, and use that information to generate repeat libraries on
link lines.
With regards to flags being interleaved with libraries, that's a tough one.
IMO,
--Ali
Boost-Build list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk