1 include $(top_srcdir)/config/doxygen.am
3 AM_CXXFLAGS = -Wall -Wno-unknown-pragmas
5 AUTOMAKE_OPTIONS = foreign
6 ACLOCAL_AMFLAGS = -I config
8 SUBDIRS_BASE = src test contrib
10 SUBDIRS = proofs/signatures proofs/lfsc_checker $(SUBDIRS_BASE)
12 SUBDIRS = $(SUBDIRS_BASE)
14 DIST_SUBDIRS = proofs/signatures proofs/lfsc_checker $(SUBDIRS_BASE) examples
18 (cd examples && $(MAKE) $(AM_MAKEFLAGS))
20 .PHONY: install-examples
22 (cd examples && $(MAKE) $(AM_MAKEFLAGS) install-data)
24 .PHONY: units systemtests regress regress0 regress1 regress2 regress3
25 systemtests regress regress0 regress1 regress2 regress3: all
26 +(cd test && $(MAKE) $(AM_MAKEFLAGS) $@) || exit 1
27 # We descend into "src" with the "check" target here to ensure that
28 # the test prerequisites are all built.
30 (cd src && $(MAKE) $(AM_MAKEFLAGS) check)
31 +(cd test && $(MAKE) $(AM_MAKEFLAGS) $@) || exit 1
39 "$(abs_top_builddir)/test/*"
44 @echo '==============================================================================='
45 @echo 'This CVC4 build was configured with:'
46 @echo ' configure $(cvc4_config_cmdline)'
47 @echo '==============================================================================='
50 .PHONY: lcov lcov-all lcov18
53 # lcov 1.7 has some bugs that we have to work around (can't do
54 # baseline measurement, merge between different test-names doesn't
58 (cd src && $(MAKE) $(AM_MAKEFLAGS) check)
59 +(cd test/unit && $(MAKE) $(AM_MAKEFLAGS) check)
60 $(LCOV) -c -d . -t cvc4_units -o cvc4-coverage-full.info
61 $(LCOV) -o cvc4-coverage.info -r cvc4-coverage-full.info $(LCOV_EXCLUDES)
62 mkdir -p "@top_srcdir@/html"
63 $(GENHTML) -o "@top_srcdir@/html" cvc4-coverage.info
64 @echo "De-mangling C++ symbols..."
65 @find "@top_srcdir@/html" -name '*.func.html' | \
66 xargs perl -pi -e 's#(<td class="coverFn"><a href=".*">)(.*)(</a></td>)#$$_=`c++filt "$$2"`;chomp;print "$$1<xmp>$$_</xmp>$$3\n";#e'
70 (cd src && $(MAKE) $(AM_MAKEFLAGS) check)
71 +(cd test && $(MAKE) $(AM_MAKEFLAGS) check)
72 $(LCOV) -c -d . -t cvc4_units -o cvc4-coverage-full.info
73 $(LCOV) -o cvc4-coverage.info -r cvc4-coverage-full.info $(LCOV_EXCLUDES)
74 mkdir -p "@top_srcdir@/html"
75 $(GENHTML) -o "@top_srcdir@/html" cvc4-coverage.info
76 @echo "De-mangling C++ symbols..."
77 @find "@top_srcdir@/html" -name '*.func.html' | \
78 xargs perl -pi -e 's#(<td class="coverFn"><a href=".*">)(.*)(</a></td>)#$$_=`c++filt "$$2"`;chomp;print "$$1<xmp>$$_</xmp>$$3\n";#e'
80 # when we get a working lcov, we can do better stats for
81 # modules/test-types; unfortunately lcov 1.8 directory paths
82 # are broken(?) or at least different than 1.7
84 +@for testtype in public black white; do \
85 echo; echo "=== Collecting coverage data from $$testtype unit tests ==="; \
86 echo $(LCOV) -z -d .; \
87 $(LCOV) -z -d . || exit 1; \
88 echo "(cd src && $(MAKE) $(AM_MAKEFLAGS) check) || exit 1"; \
89 (cd src && $(MAKE) $(AM_MAKEFLAGS) check) || exit 1; \
90 echo "(cd test/unit && $(MAKE) $(AM_MAKEFLAGS) check TEST_SUFFIX=_$$testtype) || exit 1"; \
91 (cd test/unit && $(MAKE) $(AM_MAKEFLAGS) check TEST_SUFFIX=_$$testtype) || exit 1; \
92 echo $(LCOV) -c -d . -t $$testtype -o cvc4-coverage-$$testtype-full.info || exit 1; \
93 $(LCOV) -c -d . -t $$testtype -o cvc4-coverage-$$testtype-full.info || exit 1; \
94 echo $(LCOV) -o cvc4-coverage-$$testtype.info -r cvc4-coverage-$$testtype-full.info $(LCOV_EXCLUDES); \
95 $(LCOV) -o cvc4-coverage-$$testtype.info -r cvc4-coverage-$$testtype-full.info $(LCOV_EXCLUDES) || exit 1; \
98 mkdir -p "@top_srcdir@/html"
99 $(GENHTML) -o "@top_srcdir@/html" cvc4-coverage-public.info cvc4-coverage-black.info cvc4-coverage-white.info
100 @echo "De-mangling C++ symbols..."
101 @find "@top_srcdir@/html" -name '*.func.html' | \
102 xargs perl -ni -e 's,(<td class="coverFn"><a href=".*">)(.*)(</a></td>.*),$$_=`c++filt "$$2"`;chomp;print "$$1<xmp>$$_</xmp>$$3\n";,e || print'
106 lcov lcov-all lcov18:
108 @echo "Coverage is not enabled in this build." >&2
109 @echo "Please run configure with --enable-coverage." >&2
115 # abs_srcdir is required here to get this Makefile instead of the
116 # Makefile in the builddir (since $(srcdir) is stripped off of
126 doc/find_public_interface.sh \
127 doc/cvc4.1_template.in \
129 doc/libcvc4.3_template.in \
130 doc/SmtEngine.3cvc_template.in \
131 doc/options.3cvc_template.in \
132 doc/libcvc4parser.3.in \
133 doc/libcvc4compat.3.in
142 doc/libcvc4parser.3 \
145 doc/pcvc4.1: doc/cvc4.1
149 # Can't put the first several in EXTRA_DIST because those are processed
150 # *before* recursive "make dist", and these files are generated in a
151 # subdirectory invocation of "make dist".
153 # The Makefile also can't go in EXTRA_DIST, because then automake thinks
154 # it's the one in the builddir and we want the one from the srcdir.
155 dist-hook: doc/cvc4.1 doc/libcvc4.3 doc/SmtEngine.3cvc doc/options.3cvc
156 cp -p $^ "$(distdir)/doc"
157 cp -p "$(srcdir)/Makefile" "$(distdir)/Makefile"
160 test -z "$(DX_DOCDIR)" || rm -fr "$(DX_DOCDIR)"
162 # these have .in versions
165 doc/cvc4.1_template \
169 doc/libcvc4.3_template \
170 doc/libcvc4compat.3 \
171 doc/libcvc4parser.3 \
173 doc/SmtEngine.3cvc_template \
175 doc/options.3cvc_template