Boost logo

Boost :

From: Alexander Grund (alexander.grund_at_[hidden])
Date: 2019-12-15 13:21:31


Hi,

I want to build at least the tests but better also the library sources itself with warnings enabled and warnings-as-errors to avoid regressions.

>From BoostAssert I found the following snipped added to the top of test/Jamfile.v2:

project : requirements
  <warnings>pedantic
  <warnings-as-errors>on ;

Further down I have a dependency on BoostFilesystem like:

run test_stdio.cpp : : : <library>/boost/filesystem//boost_filesystem ;

But now the build of BoostFilesystem fails:

gcc.compile.c++ bin.v2/libs/filesystem/build/gcc-5.4.0/release/cxxstd-11-iso/threading-multi/visibility-hidden/directory.o
libs/filesystem/src/directory.cpp:217:48: error: unused parameter 'buffer' [-Werror=unused-parameter]

Is there any way to restrict the warnings to my project only? Or at least the warnings-as-errors option?
Is there a way to set warnings-as-errors via b2 command only for this library? This would avoid putting it in the Jamfile which could affect end-users, but having it on CI is actually enough.

Alex


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