summaryrefslogtreecommitdiff
path: root/Makefile.am
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile.am')
-rw-r--r--Makefile.am21
1 files changed, 21 insertions, 0 deletions
diff --git a/Makefile.am b/Makefile.am
index a30c0de..6f243f7 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -9,3 +9,24 @@ SUBDIRS += editor
endif
DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc
+
+.PHONY: lcov lcov-clean
+# use recursive makes in order to ignore errors during check
+lcov:
+ -$(MAKE) $(AM_MAKEFLAGS) lcov-clean
+ -$(MAKE) $(AM_MAKEFLAGS) -k check
+ lcov --directory $(top_builddir) --capture --output-file dconf-lcov.info --test-name dconf --no-checksum --compat-libtool
+ LANG=C genhtml --prefix $(top_builddir) --output-directory lcov-html --legend --show-details dconf-lcov.info
+ @echo
+ @echo " file://$(abs_top_builddir)/lcov-html/index.html"
+ @echo
+
+clean-am: lcov-clean gcno-clean
+
+gcno-clean:
+ -find -name '*.gcno' -exec rm -f '{}' ';'
+
+lcov-clean:
+ -lcov --directory $(top_builddir) -z
+ -find -name '*.gcda' -exec rm -f '{}' ';'
+ rm -rf lcov-html dconf-lcov.info