diff options
author | Alex Bennée <alex.bennee@linaro.org> | 2019-04-30 14:44:10 +0100 |
---|---|---|
committer | Alex Bennée <alex.bennee@linaro.org> | 2019-05-28 10:28:51 +0100 |
commit | 90e671a9b2a92ec80d671c249f6bdb876bf37d5f (patch) | |
tree | c3a1ad8beae46e312a7cc7a570825ea05a5852c8 /Makefile.target | |
parent | 5eda6e42cce506658f40aed6e40a8fed47ca5ad6 (diff) |
Makefile.target: support per-target coverage reports
Add support for generating a single targets coverage report. Execute:
make coverage-report
In the target build directory. This coverage report only cares about
target specific blobs so only searches the target build subdirectory.
Signed-off-by: Alex Bennée <alex.bennee@linaro.org>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Diffstat (limited to 'Makefile.target')
-rw-r--r-- | Makefile.target | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/Makefile.target b/Makefile.target index 4ef4ce5996..ecd856e3a3 100644 --- a/Makefile.target +++ b/Makefile.target @@ -238,3 +238,19 @@ endif generated-files-y += config-target.h Makefile: $(generated-files-y) + +# Reports/Analysis +# +# The target specific coverage report only cares about target specific +# blobs and not the shared code. +# + +%/coverage-report.html: + @mkdir -p $* + $(call quiet-command,\ + gcovr -r $(SRC_PATH) --object-directory $(CURDIR) \ + -p --html --html-details -o $@, \ + "GEN", "coverage-report.html") + +.PHONY: coverage-report +coverage-report: $(CURDIR)/reports/coverage/coverage-report.html |