Tell gcov to look in .libs to find coverage data

This commit is contained in:
Daniel P. Berrange 2008-04-29 15:38:13 +00:00
parent 12af012644
commit 624ab0be4c
1 changed files with 11 additions and 9 deletions

View File

@ -148,16 +148,18 @@ EXTRA_DIST += parthelper.c
endif
cov: clean-cov
for i in $(CLIENT_SOURCES); do \
case $$i in *.c) ;; *) continue;; esac; \
b=$$(basename $$i .c); \
o_files=; \
for i in '' _test; do \
for i in $(CLIENT_SOURCES); do \
case $$i in *.c) ;; *) continue;; esac; \
b=$$(basename $$i .c); \
o_files=; \
for i in '' _test; do \
g="$(LV_LIBTOOL_OBJDIR)/libvirt$${i}_la-$$b.gcda"; \
o="$(LV_LIBTOOL_OBJDIR)/libvirt$${i}_la-$$b.o"; \
test -f "$$o" \
&& o_files="$$o_files $$o"; \
done; \
gcov -b -f $$o_files > $$b.cov; \
test -f "$$o" -a -f "$$g" \
&& o_files="$$o_files $$o"; \
done; \
test -n "$$o_files" \
&& gcov -o $(LV_LIBTOOL_OBJDIR) -b -f $$o_files > $$b.cov; \
done
clean-cov: