test: Hook up gcov to require the test name

Make check will simply overwrite results of a previous test. Hook up gcov so that the test has to be
explicitly passed to avoid confusion here.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
Peter Hutterer 2013-06-27 09:24:05 +10:00
parent 045c3f50a8
commit 32f86f97f6

View file

@ -32,7 +32,9 @@ CLEANFILES = gcov-report.txt
gcov-clean:
@rm -f *.gcov
gcov-report.txt: gcov-clean check-TESTS
gcov-report.txt: gcov-clean $(TEST)
$(AM_V_GEN)test -n "$$TEST" || (echo "Run as 'make gcov TEST=<test>'" && exit 1)
$(AM_V_GEN)($(builddir)/$(TEST))
$(AM_V_GEN)(rm -rf $@; \
echo "========== coverage report ========" >> $@; \
for file in `find $(top_srcdir)/libevdev -name "*.c" -printf "%P\n"`; do \