|
Boost-Build : |
Subject: Re: [Boost-build] really dumb bjam question(2)
From: Robert Ramey (ramey_at_[hidden])
Date: 2012-07-14 17:21:02
Steven Watanabe wrote:
> AMDG
>
> On 07/13/2012 03:23 PM, Robert Ramey wrote:
>> I have some jamfile.v2 files in the test directory.
>>
>> In order to get the result I want, I need to invoke bjam like this:
>>
>> bjam toolset=gcc --dump-tests --preserve_test_targets. The problem
>> is that one doesn't always remember the extra switches.
>>
>> Is there a way I can include the functionalty of
>> the --dump-tests --preserve_test_targets
>> inside the jamfile itself?
>>
>> So that then I could just use
>>
>> bjam toolset gcc
>>
>> and it would do what I wanted it to?
>>
>
> preserve-test-targets is a feature, so
>
> project : requirements <preserve-test-targets>on ;
>
> should work.
>
> There's no good way to set --dump-tests from
> a Jamfile. It can be done by editing ARGV:
> module { ARGV += --dump-tests ; }
> but I don't recommend this, since Boost.Build
> usually assumes that ARGV doesn't change.
>
> Also, please remember that even if you always
> want to use these options, other people running
> your tests may not want them.
OK - see this for --preserve_test_targets.
But what about --dump-tests ? It's not clear to me what
the point of running bjam on the test/jamfile.jam would be
without this switch - that's what underlies my question. I've
run the tests this way - but I don't get much of a useful result
execept some sort of indicator in the bjam log.
Robert Ramey
And here's another dumb bjam question: I have:
safe_numerics
Jamroot.jam
test
Jamfile.jam
which I invoke with
bjam toolset=gcc --dump_tests --preserve_test_targets
from the test directory.
and which works fine when my jamfile.jam looks like:
import testing ;
run test_subtract.cpp
test_subtract1.cpp
test_subtract2.cpp
test_subtract3.cpp
: # args
: # input files
: # requirements
<include>"C:/BoostRelease"
: # target-name
: # default-build ...
;
But when I remove the "include" and use the following
project safe_numerics
# : source-location ... # not needed for header files
: requirements
<include>"C:/BoostRelease"
<toolset>gcc:<cxxflags>-pedantic
<toolset>gcc:<cxxflags>-std=c++0x
# : default-build - default none
# : build-dir - default = ./bin
;
It doesn't seem to use the "include". From reading the documentation
I expect this to work. What might I be mising here?
Rboert Ramey
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