Boost logo

Boost-Build :

Subject: Re: [Boost-build] <name> property in <conditional> rule
From: Vladimir Prus (ghost_at_[hidden])
Date: 2009-09-03 12:44:16


On Monday 31 August 2009 Gaydov Victor wrote:

> i want to write something like:
>
> lib a : : <conditional>@config-lib1 ;
> rule config-lib1 ( props * )
> {
> return <name>lib1_2.5 ;
> }
>
> but definition of the 'lib' rule contains this code:
>
> if ! $(sources) && ! <name> in $(requirements:G)
> && ! <file> in $(requirements:G)
> {
> r += <name>$(name) ;
> }
>
> so after running config-lib1 there are two <name> properties
> and i get extra argument error in rule
> object(searched-lib-target)@154.__init__ ( name : project : shared ? :
> search * : action )
> (2 names are passed)
>
> is it possible to avoid this ?
> if not, could you or i patch rule definition and add check for example
> for <name-will-be-in-conditional> feature ?

Victor,

I suggest you use

        searched-lib xxx ...

instead of

    lib xxx

Because this is more explicit already, no checks for <name> in properties is
done, and your usecase should just work.

HTH,
Volodya


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