Boost logo

Boost-Build :

From: Toon Knapen (toon.knapen_at_[hidden])
Date: 2004-08-24 08:58:24


Vladimir Prus wrote:

>>However what do you mean with _messy_ order-sensitivity. Why do you
>>think it is messy ?
>
>
> I generally believe that non-obvious order sensitivity is bad. If "-la -lb"
> means something different from "-lb -la", it's non-obvious

I can not agree with you here. Actually I find the library-order
sensitivity a good thing. First of all the order allows the linker to
optimise the search operations for finding definitions. OTOH this makes
that developers should be aware of the dependencies between the
libraries which is also a good thing: this forces developers to avoid
circular dependencies.

> I've seen a lot
> of folks type
>
> gcc -o hello -lm hello.o
>
> and then wonder why math function are not found.

But users should learn first about using the tool (from the
documentation e.g.) instead of trying a tool and complain that it does
not work as _they_ expect.

> Yes, the order sensitivity
> can be handy when one library wants to override symbols from the other.
> That is, if two libraries define function 'userinit', then the first
> definition is used. But such cases are not common and could be solved with
> explicit mechanisms.

I never considered this a feature of the order-dependency, I also find
this kind of use 'dirty'.

> Anyway, that's just philosophical ideas of mine, so
> don't take them too seriously.

I was just curious about your opinion. In our company I find it very
important that developers know what the different development tools
actually do and how these tools work (and eventually how a computer
works): I think it improves code-quality.

 


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