Boost logo

Boost-Build :

From: Vladimir Prus (ghost_at_[hidden])
Date: 2005-03-04 04:49:20


On Thursday 03 March 2005 01:11, jim_at_[hidden] wrote:
> I've been trying to work ion how to build a build tool and then use it
> myself, but am currently stuck on the question of how to find the location
> of a built file.
>
> I.e. if I have a rule that generates an executable
>
> exe builder : builder.c ;
>
> I would like to be able to say
>
> local builder-exe = ?? Something ?? ;
> echo Builder executable file is at $(builder-exe) ;
>
> There seem to be differences between current CVS and m10 here. Any
> advice on which to use and how to go about it?

You can do this. Since you can build with 10 different property sets at a
moment, and Jamfiles are read only once, it's not clear which of 10 paths
should be assigned to variable "builder-exe".

However, you can do something. Say:

exe builder : builder.c ;

some_rule_of_yours a : a.cpp : <command>builder ;

where 'command' is a dependency property that you should define and the
'some_rule_of_yours' rule should make use of that property.

You can take a look at tools/quickbook.jam, which does roughly the same. The
only different is that quickbook.jam tries to automatically generate the tool
if you use any *.qbk sources, so the logic is more complex. But basically it
defines <quickbook-binary> property which is used by 'quickbook-to-boostbook'
action. The property is set by a generator, but maybe in your case a property
can be set manually like in the example above.

Should you have any problems, please ask again.

- 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