mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-09 12:23:04 +00:00
build: run checks in distinct directories
* tests/local.mk (maintainer-release-check) Import this rule from maint. Run maintainer-checks in separate directories. * configure.ac (AC_CONFIG_TESTDIR), tests/local.at: Adjust paths.
This commit is contained in:
@@ -220,7 +220,7 @@ AC_SUBST([aclocaldir])
|
||||
AC_CONFIG_FILES([etc/bench.pl], [chmod +x etc/bench.pl])
|
||||
|
||||
# Initialize the test suite.
|
||||
AC_CONFIG_TESTDIR(tests)
|
||||
AC_CONFIG_TESTDIR([tests], [$ac_abs_top_builddir/tests])
|
||||
AC_CONFIG_FILES([tests/atlocal])
|
||||
AC_CONFIG_FILES([tests/bison], [chmod +x tests/bison])
|
||||
AC_CHECK_PROGS([VALGRIND], [valgrind])
|
||||
|
||||
@@ -734,7 +734,7 @@ m4_define([AT_JAVA_COMPILE],
|
||||
[AT_KEYWORDS(java)
|
||||
AT_SKIP_IF([[test -z "$CONF_JAVAC"]])
|
||||
AT_SKIP_IF([[test -z "$CONF_JAVA"]])
|
||||
AT_CHECK([[$SHELL ../../../javacomp.sh ]$1],
|
||||
AT_CHECK([[$SHELL $abs_top_builddir/javacomp.sh ]$1],
|
||||
[[0]], [ignore], [ignore])])
|
||||
|
||||
# AT_LANG_COMPILE(OUTPUT, [SOURCES = OUTPUT.c]
|
||||
@@ -844,7 +844,7 @@ AT_CHECK([sed >&2 -e '/^profiling:.*:Merge mismatch for summaries/d' stderr],
|
||||
# AT_JAVA_PARSER_CHECK(COMMAND, EXIT-STATUS, EXPOUT, EXPERR, [PRE])
|
||||
# -----------------------------------------------------------------
|
||||
m4_define([AT_JAVA_PARSER_CHECK],
|
||||
[AT_CHECK([$5[ $SHELL ../../../javaexec.sh ]$1], [$2], [$3], [$4])])
|
||||
[AT_CHECK([$5[ $SHELL $abs_top_builddir/javaexec.sh ]$1], [$2], [$3], [$4])])
|
||||
|
||||
|
||||
# AT_TEST_TABLES_AND_PARSE(TITLE, COND-VALUE, TEST-SPEC,
|
||||
|
||||
@@ -80,8 +80,17 @@ $(TESTSUITE): $(TESTSUITE_AT)
|
||||
## Run the test suite. ##
|
||||
## -------------------- ##
|
||||
|
||||
# Move into tests/ so that testsuite.dir etc. be created there.
|
||||
RUN_TESTSUITE = $(TESTSUITE) -C tests $(TESTSUITEFLAGS)
|
||||
# Move into tests/ so that testsuite.dir etc. be created there. If a suffix is
|
||||
# specified, create it in a corresponding subdirectory of tests/.
|
||||
RUN_TESTSUITE = dir=tests/$$suf \
|
||||
&& { test -d $$dir || mkdir $$dir; } \
|
||||
&& { test -f $$dir/atconfig \
|
||||
&& diff -q $$dir/atconfig tests/atconfig \
|
||||
|| cp tests/atconfig $$dir; } \
|
||||
&& { test -f $$dir/atlocal \
|
||||
&& diff -q $$dir/atlocal tests/atlocal \
|
||||
|| cp tests/atlocal $$dir; } \
|
||||
&& $(TESTSUITE) -C $$dir $$TESTSUITEFLAGS
|
||||
check_SCRIPTS = $(BISON) tests/atconfig tests/atlocal
|
||||
RUN_TESTSUITE_deps = $(TESTSUITE) $(check_SCRIPTS)
|
||||
|
||||
@@ -99,16 +108,16 @@ installcheck-local: $(RUN_TESTSUITE_deps)
|
||||
# Be real mean with it.
|
||||
.PHONY: maintainer-check-g++
|
||||
maintainer-check-g++: $(RUN_TESTSUITE_deps)
|
||||
$(RUN_TESTSUITE) --compile-c-with-cxx
|
||||
suf=$@ $(RUN_TESTSUITE) --compile-c-with-cxx
|
||||
|
||||
.PHONY: maintainer-check-posix
|
||||
maintainer-check-posix: $(RUN_TESTSUITE_deps)
|
||||
$(RUN_TESTSUITE) POSIXLY_CORRECT=1 _POSIX2_VERSION=200112
|
||||
suf=$@ $(RUN_TESTSUITE) POSIXLY_CORRECT=1 _POSIX2_VERSION=200112
|
||||
|
||||
.PHONY: maintainer-check-valgrind
|
||||
maintainer-check-valgrind: $(RUN_TESTSUITE_deps)
|
||||
test -z '$(VALGRIND)' || \
|
||||
$(RUN_TESTSUITE) \
|
||||
suf=$@ $(RUN_TESTSUITE) \
|
||||
PREBISON='$(VALGRIND_PREBISON)' PREPARSER='$(VALGRIND) -q' \
|
||||
VALGRIND_OPTS='--leak-check=full --show-reachable=yes'
|
||||
|
||||
@@ -122,5 +131,8 @@ maintainer-push-check:
|
||||
|
||||
.PHONY: maintainer-xml-check
|
||||
maintainer-xml-check:
|
||||
$(MAKE) $(AM_MAKEFLAGS) maintainer-check \
|
||||
$(MAKE) $(AM_MAKEFLAGS) maintainer-check \
|
||||
TESTSUITEFLAGS='BISON_TEST_XML=1 $(TESTSUITEFLAGS)'
|
||||
|
||||
.PHONY: maintainer-release-check
|
||||
maintainer-release-check: maintainer-check maintainer-push-check maintainer-xml-check
|
||||
|
||||
Reference in New Issue
Block a user