summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorDmitry V. Levin <ldv@altlinux.org>2021-01-12 08:00:00 +0000
committerDmitry V. Levin <ldv@altlinux.org>2021-01-12 09:09:25 +0000
commit2a16a0fc7e353f8fcfc27a57710e008840297847 (patch)
tree79d54ce2a51409f081457ca836c7e966fec43acd /configure.ac
parentada269939a17f973cb883a29d40e437ad39ca292 (diff)
downloadelfutils-2a16a0fc7e353f8fcfc27a57710e008840297847.tar.gz
Add coverage target
Implement a target for capturing code coverage using lcov. It is available when elfutils is configured using --enable-gcov. Tested with autoreconf -if && ./configure --enable-maintainer-mode --enable-gcov && make && make check && make coverage Signed-off-by: Dmitry V. Levin <ldv@altlinux.org>
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac3
1 files changed, 3 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 60747bc8..346ab800 100644
--- a/configure.ac
+++ b/configure.ac
@@ -311,6 +311,9 @@ if test "$use_gcov" = yes; then
CFLAGS="$CFLAGS -fprofile-arcs -ftest-coverage"
CXXFLAGS="$CXXFLAGS -fprofile-arcs -ftest-coverage"
LDFLAGS="$LDFLAGS -fprofile-arcs"
+ AC_CHECK_PROG([GCOV], [gcov], [gcov])
+ AC_CHECK_PROG([LCOV], [lcov], [lcov])
+ AC_CHECK_PROG([GENHTML], [genhtml], [genhtml])
fi
AM_CONDITIONAL(GCOV, test "$use_gcov" = yes)