Boost logo

Boost :

Subject: [boost] Tests that enable <warnings-as-errors>on
From: Peter Dimov (lists_at_[hidden])
Date: 2015-01-15 09:50:47


Some test suites, for example Pool and Units, use '<warnings-as-errors>on'
in their project requirements, to test for a warning-free compilation.

Pool, f.ex. has

project
    : requrements
    <toolset>gcc:<warnings-as-errors>on <toolset>msvc:<warnings-as-errors>on
;

(among others.)

This, however, is propagated to dependencies, so that in

[ run test_threading.cpp : : : <threading>multi
<library>/boost/thread//boost_thread ]

Boost.Thread is also built with '<warnings-as-errors>on', which fails. (In
addition, some other tests also fail because of warnings.)

So I tried to use '<warnings-as-errors>off' only for some tests, but I was
unable to come up with a syntax that worked.
Putting -<toolset>msvc:<warnings-as-errors>on in the test requirements
didn't (no effect). <toolset>msvc:<warnings-as-errors>off didn't
(conflict). -<warnings-as-errors>on didn't (no
effect). -<warnings-as-errors>on <warnings-as-errors>off didn't (no effect).

Is there a way to override the project requirements from the run rule?


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk