1
0
mirror of git://sourceware.org/git/lvm2.git synced 2024-12-21 13:34:40 +03:00

configure: lcov needs -fprofile-update=atomic

To avoid negative counters.
See: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=68080
This commit is contained in:
Zdenek Kabelac 2024-03-27 00:19:52 +01:00
parent f98d2ffe87
commit 2b864aeb14
3 changed files with 4 additions and 4 deletions

View File

@ -194,10 +194,10 @@ ifneq ("$(GENHTML)", "")
lcov:
$(RM) -rf $(LCOV_REPORTS_DIR)
$(MKDIR_P) $(LCOV_REPORTS_DIR)
$(LCOV) --capture --directory $(top_builddir) --ignore-errors source,negative \
$(LCOV) --capture --directory $(top_builddir) --ignore-errors source \
--output-file $(LCOV_REPORTS_DIR)/out.info
-test ! -s $(LCOV_REPORTS_DIR)/out.info || \
$(GENHTML) -o $(LCOV_REPORTS_DIR) --ignore-errors source,negative \
$(GENHTML) -o $(LCOV_REPORTS_DIR) --ignore-errors source \
$(LCOV_REPORTS_DIR)/out.info
endif

2
configure vendored
View File

@ -11574,7 +11574,7 @@ printf "%s\n" "$PROFILING" >&6; }
if test "$PROFILING" = "yes"
then :
COPTIMISE_FLAG="$COPTIMISE_FLAG -fprofile-arcs -ftest-coverage"
COPTIMISE_FLAG="$COPTIMISE_FLAG -fprofile-arcs -fprofile-update=atomic -ftest-coverage"
if test -n "$ac_tool_prefix"; then
# Extract the first word of "${ac_tool_prefix}lcov", so it can be a program name with args.
set dummy ${ac_tool_prefix}lcov; ac_word=$2

View File

@ -839,7 +839,7 @@ AC_ARG_ENABLE(profiling,
AC_MSG_RESULT([$PROFILING])
AS_IF([test "$PROFILING" = "yes"], [
COPTIMISE_FLAG="$COPTIMISE_FLAG -fprofile-arcs -ftest-coverage"
COPTIMISE_FLAG="$COPTIMISE_FLAG -fprofile-arcs -fprofile-update=atomic -ftest-coverage"
AC_PATH_TOOL(LCOV, lcov)
AC_PATH_TOOL(GENHTML, genhtml)
AS_IF([test -z "$LCOV" || test -z "$GENHTML"], [