-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathMakefile.am
89 lines (73 loc) · 2.35 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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
ACLOCAL_AMFLAGS = -I m4
SUBDIRS = \
libsrc \
bin \
examples
if ENABLE_PYTHON
SUBDIRS += \
modulesrc \
geomodelgrids
endif
if ENABLE_TESTING
SUBDIRS += tests
endif
DIST_SUBDIRS = $(SUBDIRS) \
docs \
models
EXTRA_DIST = \
README.md \
CHANGES.md \
CODE_OF_CONDUCT.md \
CONTRIBUTING.md \
DISCLAIMER.md \
LICENSE.md \
setup.py \
setup.cfg \
code.json \
developer/autopep8.cfg \
developer/uncrustify.cfg \
docker/README.md \
docker/build_binary.py \
docker/builder.py \
docker/update_testenv.py \
docker/debian-stable \
docker/debian-testing \
docker/ubuntu-20.04 \
docker/ubuntu-22.04 \
docker/ubuntu-23.04 \
docker/ubuntu-23.10 \
docker/fedora-38 \
docker/fedora-39 \
docker/rockylinux-8 \
docker/rockylinux-9 \
docker/geomodelgrids-binaryenv \
docker/geomodelgrids-testenv \
docker/geomodelgrids-devenv \
docker/geomodelgrids-userenv \
ci-config/run_tests.sh
.PHONY: coverage-libtests coverage-pytests coverage-html clean-coverage
LCOV_FLAGS=--ignore-errors inconsistent --ignore-errors unused
if ENABLE_TEST_COVERAGE
coverage-libtests:
$(LCOV) $(LCOV_FLAGS) --directory libsrc --capture --output-file coverage-libtests.info
$(LCOV) $(LCOV_FLAGS) --remove coverage-libtests.info '*/usr/*' '/Library/*' "v1" -o coverage-libtests.info
$(LCOV) $(LCOV_FLAGS) --list coverage-libtests.info
coverage-pybind11:
$(LCOV) $(LCOV_FLAGS) --directory modulesrc --capture --output-file coverage-pybind11.info
$(LCOV) $(LCOV_FLAGS) --remove coverage-pybind11.info '*/usr/*' '/Library/*' "v1" "pybind11" -o coverage-pybind11.info
$(LCOV) $(LCOV_FLAGS) --list coverage-pybind11.info
coverage-pytests:
$(PYTHON_COVERAGE) xml -o coverage-pytests.xml $(top_builddir)/tests/pytests/coverage.xml
coverage-html: coverage-libtests coverage-pytests coverage-pybind11
genhtml $(LCOV_FLAGS) -o coverage-libtests coverage-libtests.info
genhtml $(LCOV_FLAGS) -o coverage-pybind11 coverage-pybind11.info
$(PYTHON_COVERAGE) html -d coverage-pytests --data-file=$(top_builddir)/tests/pytests/.coverage
clean-coverage:
$(RM) `find . -name "*.gcda"`
$(RM) `find . -name ".coverage"`
${RM} -r coverage-libtests coverage-pybind11 coverage-pytests coverage-libtests.info coverage-pybind11.info coverage-pytests.xml
else
coverage-libtests coverage-pytests coverage-html clean-coverage:
$(warning Test coverage not enabled. Ignoring test coverage targets)
endif
# End of file