forked from cheng-zhao/libcfg
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMakefile.am
39 lines (29 loc) · 1.07 KB
/
Makefile.am
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
SUBDIRS = src tests
if ENABLE_DOC
SUBDIRS += doc
endif
EXTRA_DIST = libtool ltmain.sh
ACLOCAL_AMFLAGS = -Im4
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = libcfgcli.pc
if ENABLE_COVERAGE
if HAVE_GCOVR
COVERAGE_NAME = coverage
GCOVR_BIN = gcovr
GCOVR_OPTS = --object-directory src
clean-local:
-rm -f $(COVERAGE_NAME).*
check-local:
@echo You can run \'make $(COVERAGE_NAME)\' now to produce the coverage reports
$(COVERAGE_NAME): $(COVERAGE_NAME).html $(COVERAGE_NAME).json $(COVERAGE_NAME).xml
$(COVERAGE_NAME).html: check
$(GCOVR_BIN) $(GCOVR_OPTS) --sort-percentage --html-self-contained --html-details -o $@
@echo You can visit the file $@ with your favorite browser to see the report. Try \'firefox $@\' or visit file://${PWD}/$@
$(COVERAGE_NAME).json: check
$(GCOVR_BIN) $(GCOVR_OPTS) --json-pretty -o $@
@echo You can visit the file $@ to see the report in JSON format.
$(COVERAGE_NAME).xml: check
$(GCOVR_BIN) $(GCOVR_OPTS) --exclude-unreachable-branches --print-summary --xml-pretty -o $@
@echo You can visit the file $@ to see the report in XML format.
endif
endif