File tree Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Expand file tree Collapse file tree 2 files changed +9
-0
lines changed Original file line number Diff line number Diff line change @@ -8,6 +8,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
88### Added
99### Changed
1010### Fixed
11+ - [ Issue #22 ] ( https://github.com/suikan4github/template_application/issues/22 ) : Error message from GCOV
1112
1213## [ 1.4.0] - 2022-01-22
1314### Added
Original file line number Diff line number Diff line change @@ -19,6 +19,14 @@ set(TEST_EXECUTABLE_NAME test_${PROJECT_NAME})
1919# Add the executable for the testcase which is using googletest
2020add_executable (${TEST_EXECUTABLE_NAME} ${TEST_SRC} ${LIB_SRC} )
2121
22+ # Delete the gcov data file before linking. Otherwise, we will get many errors.
23+ add_custom_command (
24+ TARGET ${TEST_EXECUTABLE_NAME} PRE_LINK
25+ COMMAND find . -name "*.gcda" -delete
26+ COMMENT "Deleting *.gcda files under ${CMAKE_BINARY_DIR} "
27+ WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
28+ VERBATIM )
29+
2230 # Add the library under test.
2331 target_link_libraries (${TEST_EXECUTABLE_NAME}
2432 "gtest_main"
You can’t perform that action at this time.
0 commit comments