From a862c7d3368241e72a465ab944afa38ea62a6640 Mon Sep 17 00:00:00 2001 From: Reinhard Tartler Date: Sat, 23 Mar 2013 08:17:24 +0100 Subject: Integrate lcov/gcov into Libav The gcov/lcov are a common toolchain for visualizing code coverage with the GNU/Toolchain. The documentation and implementation of this integration was heavily inspired from the blog entry by Mike Melanson: http://multimedia.cx/eggs/using-lcov-with-ffmpeg/ --- tests/Makefile | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) (limited to 'tests/Makefile') diff --git a/tests/Makefile b/tests/Makefile index 67ce45e862..d60ee5a26e 100644 --- a/tests/Makefile +++ b/tests/Makefile @@ -123,6 +123,19 @@ $(FATE): $(FATE_UTILS:%=tests/%$(HOSTEXESUF)) fate-list: @printf '%s\n' $(sort $(FATE)) +coverage.info: TAG = LCOV +coverage.info: + $(M)lcov -d $(CURDIR) -b $(SRC_PATH) --capture -o $@ + +lcov: TAG = GENHTML +lcov: coverage.info + $(M)genhtml -o $(CURDIR)/lcov $< + +lcov-reset: TAG = LCOV +lcov-reset: + $(M)lcov -d $(CURDIR) --zerocounters + $(Q)$(RM) -f coverage.info + clean:: testclean testclean: @@ -132,4 +145,5 @@ testclean: -include $(wildcard tests/*.d) -.PHONY: fate* +.PHONY: fate* lcov lcov-reset +.INTERMEDIATE: coverage.info -- cgit v1.2.3