aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDave Wallace <dwallacelf@gmail.com>2024-08-26 20:55:49 -0400
committerDamjan Marion <dmarion@0xa5.net>2024-10-23 09:38:11 +0000
commit66fcfb845b8e588901b4f663435e9e1b30499467 (patch)
treeb276598e479c3a8fe9896ee113986d0d1421130f
parentec906a266b958f527b9aef400a33cca26e71134a (diff)
build: fix gcov failure on ubuntu 24.04
Type: make Change-Id: Ieee6562de4b9f68d701c27a3c3018431b28eb3b0 Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
-rw-r--r--src/CMakeLists.txt2
-rw-r--r--test/Makefile6
2 files changed, 4 insertions, 4 deletions
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index d5c7fd1c718..1fbb624b972 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -164,7 +164,7 @@ elseif (${CMAKE_BUILD_TYPE_LC} MATCHES "coverity")
add_compile_options(-O0)
add_compile_definitions(__COVERITY__)
elseif (${CMAKE_BUILD_TYPE_LC} MATCHES "gcov")
- add_compile_options(-O0 -fprofile-arcs -ftest-coverage)
+ add_compile_options(-O0 -fprofile-arcs -ftest-coverage -fprofile-update=prefer-atomic)
add_compile_definitions(CLIB_DEBUG CLIB_GCOV)
link_libraries(gcov)
endif()
diff --git a/test/Makefile b/test/Makefile
index bc5bc0cf129..79feba9165e 100644
--- a/test/Makefile
+++ b/test/Makefile
@@ -393,14 +393,14 @@ COV_REM_ALT_TEST="*/plugins/hs_apps/*" "*/plugins/http/*.h"
.PHONY: cov-post
cov-post: wipe-cov $(BUILD_COV_DIR)
- @lcov --capture \
+ @lcov --ignore-errors --capture \
--directory $(VPP_BUILD_DIR) \
--output-file $(BUILD_COV_DIR)/coverage$(HS_TEST).info
@test -z "$(EXTERN_COV_DIR)" || \
- lcov --capture \
+ lcov --ignore-errors --capture \
--directory $(EXTERN_COV_DIR) \
--output-file $(BUILD_COV_DIR)/extern-coverage$(HS_TEST).info
- @lcov --remove $(BUILD_COV_DIR)/coverage$(HS_TEST).info \
+ @lcov --ignore-errors --remove $(BUILD_COV_DIR)/coverage$(HS_TEST).info \
$(COV_REM_NOT_CODE) \
$(COV_REM_DRIVERS) \
$(COV_REM_TODO_NO_TEST) \