Note that there are some explanatory texts on larger screens.

plurals
  1. POBjam for gcov coverage analysis?
    text
    copied!<p>I am looking to integrate a non-trivial cross-platform build system for a project predominately written in C++. I've evaluated Cmake and Scons, so far, and while they both represent an improvement over (GNU) make, neither approach seemed either elegant or transparent in the context I was trying to use these tools. This brought me to Boost Build (Bjam) and I am encouraged that, given my project is dependent upon Boost, bjam should be available for any viable target platform already.</p> <p>I've run into difficulty trying to neatly integrate code-coverage for unit tests of a library... with a view to eventual integration into a build server such as Jenkins. While I'm willing to be guided by Bjam best/standard practice, I think I need three distinct "variants":</p> <ul> <li>release - to build optimised static library only</li> <li>debug - to build non-optimised static library and unit tests</li> <li>coverage - to build coverage-enabled library and link with non-coverage enabled unit tests.</li> </ul> <p>Essentially, in addition to the standard debug and release builds, I'd like a special purpose debug build that also collects coverage data.</p> <p>I need to build with (at least) g++ and msvc... and use gcov switches only with g++. This means my library target needs different "compilerflags" to the unit-test executable target... and only for one of my compiler suites... and for only one variant.</p> <p>I am unclear how best to achieve this with Bjam - though, I suspect, it should be a fairly common use case. Does Bjam have explicit support for gcov coverage analysis (possibly presenting results using lcov)? If not, can anyone recommend a strategy which would support the above (simplified) scenario?</p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload