Boost logo

Boost-Build :

Subject: [Boost-build] How to write such a feature?
From: Sherwood Hu (sherwood_at_[hidden])
Date: 2009-09-21 21:23:56


The <define> property in Boost.Build does not propagate. This causes
problems in my project, as the unit tests require a macro UNIT_TEST to
be defined and the main library is built with this macro defined.
Because <define> does not propagate, I have to specify <define>UNIT_TEST
at the command line. If the library is built first without this macro,
the unit tests will not be built successfully.

 

I am considering to add a <unit-test> feature and make <define>UNIT_TEST
propagate.

 

Import feature : feature ;

 

Feature unit-test : on off : propagated ;

 

But how to add <define>UNIT_TEST when <unit-test>on?

 

Thanks.

 

 

 



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