diff options
author | Morgan Deters <mdeters@gmail.com> | 2011-09-24 18:04:08 +0000 |
---|---|---|
committer | Morgan Deters <mdeters@gmail.com> | 2011-09-24 18:04:08 +0000 |
commit | b79e8b369649f053ce3a39d3d178e4e2dbcf9993 (patch) | |
tree | 0d75973130594b7b498cee4dc60b83a267fbad2d /Makefile.am | |
parent | a63064385c56600143ac470108fe8e640a4ca3ee (diff) |
Fix to building and linking for unit tests. (This should fix the segfaulting units in optimized-dynamic. The problem was that the code incorrectly determined the address of one of the thread-scoped global variables, and I think it's because the same library was linked twice into the unit test in two different ways, confusing the runtime support code.)
Diffstat (limited to 'Makefile.am')
-rw-r--r-- | Makefile.am | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/Makefile.am b/Makefile.am index b293da744..f8538b548 100644 --- a/Makefile.am +++ b/Makefile.am @@ -10,7 +10,10 @@ SUBDIRS = src test contrib .PHONY: units systemtests regress regress0 regress1 regress2 regress3 systemtests regress regress0 regress1 regress2 regress3: all +(cd test && $(MAKE) $(AM_MAKEFLAGS) $@) || exit 1 +# We descend into "src" with the "check" target here to ensure that +# the test prerequisites are all built. units: all + (cd src && $(MAKE) $(AM_MAKEFLAGS) check) +(cd test && $(MAKE) $(AM_MAKEFLAGS) $@) || exit 1 LCOV = lcov @@ -29,6 +32,7 @@ if COVERAGE_ENABLED # work...) lcov: all $(LCOV) -z -d . + $(MAKE) check -C src +$(MAKE) check -C test/unit $(LCOV) -c -d . -t cvc4_units -o cvc4-coverage-full.info $(LCOV) -o cvc4-coverage.info -r cvc4-coverage-full.info $(LCOV_EXCLUDES) @@ -40,6 +44,7 @@ lcov: all lcov-all: all $(LCOV) -z -d . + $(MAKE) check -C src +$(MAKE) check -C test $(LCOV) -c -d . -t cvc4_units -o cvc4-coverage-full.info $(LCOV) -o cvc4-coverage.info -r cvc4-coverage-full.info $(LCOV_EXCLUDES) @@ -57,6 +62,8 @@ lcov18: all echo; echo "=== Collecting coverage data from $$testtype unit tests ==="; \ echo $(LCOV) -z -d .; \ $(LCOV) -z -d . || exit 1; \ + echo $(MAKE) check -C src || exit 1; \ + $(MAKE) check -C src || exit 1; \ echo $(MAKE) check -C test/unit TEST_SUFFIX=_$$testtype || exit 1; \ $(MAKE) check -C test/unit TEST_SUFFIX=_$$testtype || exit 1; \ echo $(LCOV) -c -d . -t $$testtype -o cvc4-coverage-$$testtype-full.info || exit 1; \ |