From: Matthew Herrmann (matthew.herrmann_at_[hidden])
Date: 2006-02-27 16:59:49
Sorry all, please ignore the previous message, it was incomplete.
> > Well, don't put 'pre_test.configure_check' to sources:
> > lib my_library
> > : [ glob *.cpp ]
> > : <dependency>pre_test.configure_check
> > ;
> > Assuming your configure check does not puts files into source directory,
> > but only to build directory, this will have the right effect.
> > In fact, is there any reason why your configure check creates .o files?
> > I'm not 100% understand the approach you took.
Thanks for your help.
I am using OBJ as an output as it is a valid source for a library, and this
was how I could 'wedge' in the test script execution to the compilation
dependency model. If I move the .check file to being a dependency requirement
instead of a source, bjam doesn't call my script. With the current approach I
am using, the script is being called, but unfortunately does not prevent
other sources such as the CPP files from being compiled on failure, although
at least the overall build is marked as a fail, which is still very useful.
Here's the script I am currently using:
import type ;
type.register CHECK_SCRIPT : check ;
import generators ;
generators.register-standard check.run_script : CHECK_SCRIPT : OBJ ;
echo Running checking script...
rm -f $(<)
if test $? -eq 0 ; then
import check ;
: # sources
[ glob *.cpp ]
Many thanks again,
-- Matthew Herrmann matthew.herrmann_at_[hidden] Vice President, Software Architecture Zomojo Pty Ltd
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