Put the code coverage stuff behind a build flag.
This commit is contained in:
@@ -56,13 +56,10 @@ add_subdirectory(3rdparty/toluapp)
|
||||
set(conky_libs ${conky_libs} toluapp_lib_static)
|
||||
|
||||
if(BUILD_TESTS)
|
||||
if(USING_CLANG)
|
||||
message(STATUS "Detected clang, enabling test coverage reports")
|
||||
if(CODE_COVERAGE)
|
||||
# Enable coverage checks
|
||||
include(CodeCoverage)
|
||||
append_coverage_compiler_flags()
|
||||
else()
|
||||
message(STATUS "NOT enabling test coverage reports")
|
||||
endif()
|
||||
include(Catch)
|
||||
endif()
|
||||
|
@@ -84,6 +84,7 @@ option(RELEASE "Build release package" false)
|
||||
mark_as_advanced(RELEASE)
|
||||
|
||||
option(MAINTAINER_MODE "Enable maintainer mode" false)
|
||||
option(CODE_COVERAGE "Enable code coverage report generation" false)
|
||||
|
||||
option(BUILD_DOCS "Build documentation" false)
|
||||
option(BUILD_EXTRAS "Build extras (includes syntax files for editors)" false)
|
||||
|
@@ -23,7 +23,7 @@ add_executable(test-conky test-common.cc ${test_srcs})
|
||||
target_link_libraries(test-conky conky_core)
|
||||
catch_discover_tests(test-conky)
|
||||
|
||||
if(USING_CLANG)
|
||||
if(CODE_COVERAGE)
|
||||
set(COVERAGE_LCOV_EXCLUDES
|
||||
"*/include/c++/v1/*"
|
||||
"/usr/include/*"
|
||||
|
Reference in New Issue
Block a user