Skip to content

Commit

Permalink
Update coverage_snippet
Browse files Browse the repository at this point in the history
  • Loading branch information
uvilla authored Dec 7, 2022
1 parent 54303cb commit 7bbbc34
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions autotools-macros/coverage_snippet
Original file line number Diff line number Diff line change
Expand Up @@ -12,17 +12,17 @@ lcov_dir=$(top_builddir)/coverage/lcov
lcov-report:
@mkdir -p $(lcov_dir)

$(top_srcdir)/src/lcov/lcov --compat-libtool --directory . --capture --output-file $(lcov_dir)/lcov.info
$(top_srcdir)/src/lcov/lcov --list-full-path -l $(lcov_dir)/lcov.info | grep -v "`cd -P $(top_srcdir)/src && pwd`" | cut -d\| -f1 > $(lcov_dir)/remove
$(top_srcdir)/src/lcov/lcov -q -r $(lcov_dir)/lcov.info `cat $(lcov_dir)/remove` > $(lcov_dir)/lcov.cleaned.info
lcov --compat-libtool --directory . --capture --output-file $(lcov_dir)/lcov.info
lcov --list-full-path -l $(lcov_dir)/lcov.info | grep -v "`cd -P $(top_srcdir)/src && pwd`" | cut -d\| -f1 > $(lcov_dir)/remove
lcov -q -r $(lcov_dir)/lcov.info `cat $(lcov_dir)/remove` > $(lcov_dir)/lcov.cleaned.info
@rm $(lcov_dir)/remove
@mv $(lcov_dir)/lcov.cleaned.info $(lcov_dir)/lcov.info
$(top_srcdir)/src/lcov/genhtml -t "Project 1" -o $(lcov_dir) $(lcov_dir)/lcov.info
genhtml -t "Project 1" -o $(lcov_dir) $(lcov_dir)/lcov.info

lcov-reset:
@rm -rf $(lcov_dir)
@find . -name "*.gcda" -exec rm {} \;
$(top_srcdir)/src/lcov/lcov --directory . --zerocounters
lcov --directory . --zerocounters

coverage: test lcov-reset check lcov-report

Expand Down

0 comments on commit 7bbbc34

Please sign in to comment.