]>
Commit | Line | Data |
---|---|---|
c75acc4c | 1 | SUBDIRS = src man conf init testing |
cf00cffe | 2 | |
157742be TB |
3 | if USE_FUZZING |
4 | SUBDIRS += fuzz | |
5 | endif | |
6 | ||
cf00cffe TB |
7 | if USE_SCRIPTS |
8 | SUBDIRS += scripts | |
9 | endif | |
10 | ||
d0f01a58 MW |
11 | if USE_SILENT_RULES |
12 | AM_MAKEFLAGS = -s | |
13 | endif | |
14 | ||
c0e56a66 | 15 | ACLOCAL_AMFLAGS = -I m4/config |
e455ae13 | 16 | |
3fa8d773 | 17 | EXTRA_DIST = Doxyfile.in LICENSE Android.common.mk.in Android.common.mk Android.mk |
dcb4651d | 18 | CLEANFILES = Doxyfile |
3fa8d773 TB |
19 | BUILT_SOURCES = Android.common.mk |
20 | MAINTAINERCLEANFILES = Android.common.mk | |
807c12ce | 21 | |
b188f231 | 22 | if USE_DEV_HEADERS |
7300eb29 MW |
23 | config_includedir = $(ipseclibdir)/include |
24 | nodist_config_include_HEADERS = config.h | |
b188f231 | 25 | endif |
7300eb29 | 26 | |
127f65db | 27 | # we leave config files behind intentionally so prevent distcheck from complaining |
9691e537 | 28 | distuninstallcheck_listfiles = find . -type f \! -name '*.conf' \! -name '*.secrets' -print |
127f65db | 29 | |
c577b5eb | 30 | Android.common.mk : Android.common.mk.in configure.ac |
0be946dc | 31 | $(AM_V_GEN) \ |
807c12ce TB |
32 | sed \ |
33 | -e "s:\@PACKAGE_VERSION\@:$(PACKAGE_VERSION):" \ | |
34 | $(srcdir)/$@.in > $@ | |
b1e69188 MW |
35 | |
36 | Doxyfile : Doxyfile.in | |
0be946dc | 37 | $(AM_V_GEN) \ |
b1e69188 MW |
38 | sed \ |
39 | -e "s:\@PACKAGE_VERSION\@:$(PACKAGE_VERSION):" \ | |
40 | -e "s:\@PACKAGE_NAME\@:$(PACKAGE_NAME):" \ | |
945fdeb9 | 41 | -e "s:\@SRC_DIR\@:$(srcdir):g" \ |
ea7e89c7 | 42 | $(srcdir)/$@.in > $@ |
b1e69188 MW |
43 | |
44 | apidoc : Doxyfile | |
882c993b | 45 | @test -d apidoc || doxygen |
1f3dbb1b | 46 | @! find Doxyfile $(top_srcdir)/src/ \( -name '*.h' -o -name '*.md' \) -newer apidoc | \ |
882c993b | 47 | grep -q '' || doxygen && touch apidoc |
dcb4651d | 48 | |
ab73ae67 | 49 | cov-reset-common: |
1f14b4a1 | 50 | @rm -rf $(top_builddir)/coverage |
6122bfd2 | 51 | @find $(top_builddir)/src $(top_builddir)/scripts -name "*.gcda" -delete |
ab73ae67 TB |
52 | |
53 | if COVERAGE | |
54 | cov-reset: cov-reset-common | |
1f14b4a1 TB |
55 | @lcov --zerocounters --directory $(top_builddir) |
56 | ||
57 | cov-report: | |
58 | @mkdir $(top_builddir)/coverage | |
906a4fd1 TB |
59 | lcov -c -o $(top_builddir)/coverage/coverage.info -d $(top_builddir) \ |
60 | --rc lcov_branch_coverage=1 | |
3bc8a4a5 | 61 | lcov -r $(top_builddir)/coverage/coverage.info '*/tests/*' '*/suites/*' '/usr*' \ |
0d11d7b1 | 62 | -o $(abs_top_builddir)/coverage/coverage.cleaned.info \ |
906a4fd1 | 63 | --rc lcov_branch_coverage=1 |
b98551c7 | 64 | genhtml --num-spaces 4 --legend --branch-coverage --ignore-errors source \ |
1f14b4a1 TB |
65 | -t "$(PACKAGE_STRING)" \ |
66 | -o $(top_builddir)/coverage/html \ | |
67 | -p `readlink -m $(abs_top_srcdir)`/src \ | |
ab73ae67 | 68 | $(top_builddir)/coverage/coverage.cleaned.info |
1f14b4a1 TB |
69 | @echo "Coverage Report at $(top_builddir)/coverage/html" >&2 |
70 | ||
71 | coverage: | |
72 | @$(MAKE) cov-reset | |
73 | @$(MAKE) check | |
74 | @$(MAKE) cov-report | |
75 | else | |
1f14b4a1 TB |
76 | coverage: |
77 | @echo "reconfigure with --enable-coverage" | |
78 | endif | |
79 | ||
ab73ae67 | 80 | clean-local: cov-reset-common |
6122bfd2 | 81 | @find $(top_builddir)/src $(top_builddir)/scripts -name "*.gcno" -delete |
ab73ae67 TB |
82 | @rm -rf apidoc |
83 | ||
882c993b | 84 | .PHONY: cov-reset-common cov-reset cov-report coverage apidoc |