Boost logo

Boost-Build :

From: David Abrahams (dave_at_[hidden])
Date: 2007-04-24 15:46:47


on Wed Apr 18 2007, Vladimir Prus <ghost-AT-cs.msu.su> wrote:

> On Wednesday 18 April 2007 05:54, David Abrahams wrote:
>>
>> on Wed Apr 18 2007, "Konstantin Litvinenko" <Konstantin.Litvinenko-AT-malva.ua> wrote:
>>
>> > VP> Comments?
>> >
>> > I don't like Devid's way, but really like your's one. Current
>> > Boost.Build behaviour is fail to build if requirements not fully matched.
>>
>> That is *not* the current behavior when there's only one alternative.
>
> Under my proposal, you'll be able to say:
>
> lib a : a.cpp : when <threading>single ;
>
> and this target will fail to build unless <threading>single in requested.

Except that if <threading>multi happens to be the default, you'll
again very likely be linking together single- and multi- threaded
targets because your proposal _completely_ separates requirements from
target selection criteria. What you really meant was the rather
redundant-looking

  lib a : a.cpp : <threading>single when <threading>single ;

It should be more economical to express this common need.
Furthermore, if single- and multi- threaded targets are really
link-incompatible with a particular compiler, it shouldn't be
necessary to express that for every target that requires one build or
the other. The fact of that link incompatibility should be
represented explicitly in the system.

-- 
Dave Abrahams
Boost Consulting
http://www.boost-consulting.com
Don't Miss BoostCon 2007! ==> http://www.boostcon.com

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