Условие для включения проверки покрытия кода

This commit is contained in:
Andrei Astafev 2019-10-09 01:00:33 +03:00
parent d57bbeb634
commit f76b9c6758

View File

@ -1,7 +1,7 @@
function(add_code_coverage)
list(GET ARGN 0 _target)
if(CMAKE_CXX_COMPILER_IS_GCC)
if(ENABLE_CODE_COVERAGE AND CMAKE_CXX_COMPILER_IS_GCC)
find_program(LCOV_EXE NAMES lcov)
find_program(GENHTML_EXE NAMES genhtml)
target_compile_options(${_target} PUBLIC "--coverage")