mirror of
https://github.com/GerbilSoft/zlib-ng.git
synced 2025-06-18 19:45:37 -04:00
Added CMake status message when code coverage is enabled.
This commit is contained in:
parent
6a553e0129
commit
1f8eef39dc
@ -15,6 +15,7 @@ macro(add_code_coverage)
|
||||
if(HAVE_COVERAGE)
|
||||
add_compile_options(-coverage)
|
||||
add_link_options(-coverage)
|
||||
message(STATUS "Code coverage enabled using: -coverage")
|
||||
else()
|
||||
# Some versions of GCC don't support -coverage shorthand
|
||||
if(CMAKE_VERSION VERSION_LESS 3.14)
|
||||
@ -29,6 +30,7 @@ macro(add_code_coverage)
|
||||
if(HAVE_TEST_COVERAGE)
|
||||
add_compile_options(-ftest-coverage -fprofile-arcs -fprofile-values)
|
||||
add_link_options(-lgcov -fprofile-arcs)
|
||||
message(STATUS "Code coverage enabled using: -ftest-coverage")
|
||||
else()
|
||||
message(WARNING "Compiler does not support code coverage")
|
||||
set(WITH_CODE_COVERAGE OFF)
|
||||
|
Loading…
Reference in New Issue
Block a user