2 Commits

Author SHA1 Message Date
c98b793c67 Namespace embedded coverage target
Some checks failed
libakerror CI Build / cmake_build (push) Successful in 2m52s
libakerror CI Build / mutation_test (push) Has been cancelled
libakerror CI Build / coverage (push) Has been cancelled
2026-08-03 13:15:56 -04:00
fdb8ffaad0 Merge pull request 'Annotate intentional handler fallthrough' (#19) from 18 into main
All checks were successful
libakerror CI Build / coverage (push) Successful in 2m47s
libakerror CI Build / cmake_build (push) Successful in 2m53s
libakerror CI Build / mutation_test (push) Successful in 39m42s
Reviewed-on: #19
2026-08-03 12:14:30 -04:00

View File

@@ -305,7 +305,14 @@ if(Python3_FOUND)
# The script configures and drives its own instrumented build tree (under
# ${CMAKE_BINARY_DIR}/coverage) so this build's binaries and its coverage
# counters can never be stale or half-instrumented. Reports via gcov.
add_custom_target(coverage
# Keep the convenient generic name at the top level, but namespace it when
# embedded so a parent project can provide its own coverage target.
if(CMAKE_SOURCE_DIR STREQUAL CMAKE_CURRENT_SOURCE_DIR)
set(AKERR_COVERAGE_TARGET coverage)
else()
set(AKERR_COVERAGE_TARGET akerror_coverage)
endif()
add_custom_target(${AKERR_COVERAGE_TARGET}
COMMAND ${Python3_EXECUTABLE}
${CMAKE_CURRENT_SOURCE_DIR}/scripts/coverage.py
--source-root ${CMAKE_CURRENT_SOURCE_DIR}