aboutsummaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorCharles Kerr <charles.kerr@canonical.com>2012-04-12 10:13:15 -0500
committerCharles Kerr <charles.kerr@canonical.com>2012-04-12 10:13:15 -0500
commit859a831ee1ca77b17331caa3e3a154f56beb4199 (patch)
treed317a292d80b078154dd1e61606a2176d488768e /configure.ac
parentd4b572c408dcfa78695b47f0c1f2860e8819276f (diff)
parent6f293994f8f9c260401fd76a189c7461b1b5f994 (diff)
downloadlibayatana-appindicator-859a831ee1ca77b17331caa3e3a154f56beb4199.tar.gz
libayatana-appindicator-859a831ee1ca77b17331caa3e3a154f56beb4199.tar.bz2
libayatana-appindicator-859a831ee1ca77b17331caa3e3a154f56beb4199.zip
merge lp:~allanlesage/libappindicator/TDD to add gcov targets to our autotools build for code-coverage reporting. For more information, see this blog post: http://qualityhour.wordpress.com/2012/01/29/test-coverage-tutorial-for-cc-autotools-projects/ .
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac14
1 files changed, 14 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index bc42585..1a34310 100644
--- a/configure.ac
+++ b/configure.ac
@@ -216,6 +216,19 @@ AC_ARG_ENABLE([tests],
AM_CONDITIONAL([WANT_TESTS], [test "x$enable_tests" != "xno"])
###########################
+# gcov coverage reporting
+###########################
+
+m4_include([m4/gcov.m4])
+AC_TDD_GCOV
+AM_CONDITIONAL([HAVE_GCOV], [test "x$ac_cv_check_gcov" = xyes])
+AM_CONDITIONAL([HAVE_LCOV], [test "x$ac_cv_check_lcov" = xyes])
+AM_CONDITIONAL([HAVE_GCOVR], [test "x$ac_cv_check_gcovr" = xyes])
+AC_SUBST(COVERAGE_CFLAGS)
+AC_SUBST(COVERAGE_CXXFLAGS)
+AC_SUBST(COVERAGE_LDFLAGS)
+
+###########################
# Files
###########################
@@ -256,4 +269,5 @@ Libappindicator Configuration:
GTK+ Version: $with_gtk
Tests: $enable_tests
Mono tests: $have_nunit
+ gcov: $use_gcov
])