[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Automake-commit] [SCM] GNU Automake branch, testsuite-work, updated. v1
From: |
Stefano Lattarini |
Subject: |
[Automake-commit] [SCM] GNU Automake branch, testsuite-work, updated. v1.11-820-g8061d84 |
Date: |
Tue, 03 May 2011 17:12:10 +0000 |
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU Automake".
http://git.sv.gnu.org/gitweb/?p=automake.git;a=commitdiff;h=8061d84e54c81305fa3ad22e20de9726bec82909
The branch, testsuite-work has been updated
via 8061d84e54c81305fa3ad22e20de9726bec82909 (commit)
via 7b6ab07442b28a62389fc4dc8f35276f31348c13 (commit)
from 6f8f38cfbe6ec39e3677e0276235b9c7a2ac5fbf (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 8061d84e54c81305fa3ad22e20de9726bec82909
Merge: 6f8f38c 7b6ab07
Author: Stefano Lattarini <address@hidden>
Date: Tue May 3 19:08:30 2011 +0200
Merge branch 'check-tests-list' into testsuite-work
commit 7b6ab07442b28a62389fc4dc8f35276f31348c13
Author: Stefano Lattarini <address@hidden>
Date: Sat Jan 30 01:23:44 2010 +0100
maintcheck: consistency of list of test scripts
* CheckListOfTests.am: New file.
(maintainer-check-list-of-tests): New target,
check for consistency between list of tests defined in the
including Makefile and list of tests on the filesystem.
(clean-maintcheck-testslist-tmp): New rule, to clean up the
temporary files that might be left around by the rules associated
with the previous target.
(clean-local): Depend on it.
* lib/Automake/tests/Makefile.am: Include `CheckListOfTests.am'.
(maintainer-check): Added dependency from the new target
`maintainer-check-list-of-tests'.
* tests/Makefile.am: Likewise.
* Makefile.am (maintainer-check-list-of-test): New target,
calling recursively into `tests/' and `lib/Automake/tests/',
using ...
(TEST_SUBDIRS): ... this new variable.
-----------------------------------------------------------------------
Summary of changes:
ChangeLog | 22 +++++++++++
CheckListOfTests.am | 76 ++++++++++++++++++++++++++++++++++++++++
Makefile.am | 23 ++++++++++--
Makefile.in | 19 +++++++++-
lib/Automake/tests/Makefile.am | 5 ++-
lib/Automake/tests/Makefile.in | 70 +++++++++++++++++++++++++++++++------
tests/Makefile.am | 7 ++++
tests/Makefile.in | 54 +++++++++++++++++++++++++++-
8 files changed, 257 insertions(+), 19 deletions(-)
create mode 100644 CheckListOfTests.am
diff --git a/ChangeLog b/ChangeLog
index 6193e98..24e2428 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,27 @@
2011-05-03 Stefano Lattarini <address@hidden>
+ maintcheck: consistency of list of test scripts
+ * CheckListOfTests.am: New file.
+ (maintainer-check-list-of-tests): New target,
+ check for consistency between list of tests defined in the
+ including Makefile and list of tests on the filesystem.
+ (clean-maintcheck-testslist-tmp): New rule, to clean up the
+ temporary files that might be left around by the rules associated
+ with the previous target.
+ (clean-local): Depend on it.
+ * lib/Automake/tests/Makefile.am: Include `CheckListOfTests.am'.
+ (maintainer-check): Added dependency from the new target
+ `maintainer-check-list-of-tests'.
+ * tests/Makefile.am: Likewise. Also ...
+ (checked_test_extensions): Define to `.test'.
+ (expected_test_list): Define properly.
+ * Makefile.am (maintainer-check-list-of-test): New target,
+ calling recursively into `tests/' and `lib/Automake/tests/',
+ using ...
+ (TEST_SUBDIRS): ... this new variable.
+
+2011-05-03 Stefano Lattarini <address@hidden>
+
tests: drop useless requirements of gcc (plus testsuite tweakings)
* tests/libobj14.test ($required): Remove 'gcc', as we never run
the C compiler.
diff --git a/CheckListOfTests.am b/CheckListOfTests.am
new file mode 100644
index 0000000..28cb795
--- /dev/null
+++ b/CheckListOfTests.am
@@ -0,0 +1,76 @@
+## -*- Automake -*-
+##
+## Copyright (C) 2011 Free Software Foundation, Inc.
+##
+## This program is free software; you can redistribute it and/or modify
+## it under the terms of the GNU General Public License as published by
+## the Free Software Foundation; either version 2, or (at your option)
+## any later version.
+##
+## This program is distributed in the hope that it will be useful,
+## but WITHOUT ANY WARRANTY; without even the implied warranty of
+## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+## GNU General Public License for more details.
+##
+## You should have received a copy of the GNU General Public License
+## along with this program. If not, see <http://www.gnu.org/licenses/>.
+##
+
+## Temporary files used in the `check-list-of-tests' target.
+am__tmk = tests-in-makefile-list.tmp
+am__tfs = tests-on-filesystem-list.tmp
+am__tdf = diff-in-tests-lists.tmp
+
+## Check that the list of tests given in the Makefile is equal to the
+## list of all test scripts in the Automake testsuite.
+.PHONY: maintainer-check-list-of-tests
+maintainer-check-list-of-tests:
+## Prefer unified diffs over plain diffs, for readability.
+ @if diff -u /dev/null /dev/null >/dev/null 2>&1; then \
+ diff='diff -u'; \
+ else \
+ diff='diff'; \
+ fi; \
+## Determine which files are to be considered test scripts.
+## Do not blindly look for `$(TEST_EXTENSIONS)', because the parallel
+## testsuite driver provided by Automake allow entries in `$(TESTS)'
+## not to be real files, but rather paramaters for the corresponding
+## LOG_COMPILER (well, sort of).
+ set X $(checked_test_extensions); shift; \
+ if test $$# -eq 0; then \
+ set X $(TEST_EXTENSIONS); shift; \
+ fi; \
+ if test $$# -eq 0; then \
+ echo '$@: internal error: $$(checked_test_extensions) and' \
+ '$$(TEST_EXTENSIONS) are both undefined or empty' >&2; \
+ exit 255; \
+ fi; \
+## List of tests in Makefile.
+ lst='$(expected_list_of_tests)'; \
+ test -n "$$lst" || lst='$(TESTS)'; \
+ for t in $$lst; do \
+ echo "$$t"; \
+ done | sort >$(am__tmk); \
+## List of tests on filesystem. Be careful to cater for VPATH builds too.
+ for ext in $$*; do \
+ ls *$$ext 2>/dev/null; \
+ if test $(srcdir) != $(builddir); then \
+ (cd $(srcdir) && ls *$$ext 2>/dev/null); \
+ fi; \
+ done | sort | uniq >$(am__tfs); \
+## Compare the two lists, complain if they differ.
+ if $$diff $(am__tmk) $(am__tfs) >$(am__tdf); then \
+ result=0; \
+ else \
+ echo '$@: list of tests in Makefile an on filesystem differ' >&2; \
+ echo "+ $$diff in-makefile on-filesystem" >&2; \
+ cat $(am__tdf) >&2; \
+ result=1; \
+ fi; \
+ rm -f $(am__tmk) $(am__tfs) $(am__tdf); \
+ exit $$result;
+
+.PHONY: clean-maintcheck-testslist-tmp
+clean-local: clean-maintcheck-testslist-tmp
+clean-maintcheck-testslist-tmp:
+ rm -f $(am__tmk) $(am__tfs) $(am__tdf)
diff --git a/Makefile.am b/Makefile.am
index 7ee282b..9f98106 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -24,6 +24,8 @@
## run aclocal and automake.
SUBDIRS = lib . doc m4 tests
+TEST_SUBDIRS = lib/Automake/tests tests
+
bin_SCRIPTS = automake aclocal
CLEANFILES = $(bin_SCRIPTS)
@@ -99,8 +101,6 @@ INSTALL: lib/INSTALL
$(AM_V_GEN)cp $(srcdir)/lib/INSTALL $@
## recheck: convenience proxy target for the test suites.
-TEST_SUBDIRS = lib/Automake/tests tests
-
.PHONY: recheck
recheck:
@failcom='exit 1'; \
@@ -205,7 +205,24 @@ sc_at_in_texi
.PHONY: $(syntax_check_rules)
$(syntax_check_rules): automake aclocal
-maintainer-check: $(syntax_check_rules)
+
+## Check that the list of tests given in the Makefile is equal to the
+## list of all test scripts in the Automake testsuite.
+.PHONY: maintainer-check-list-of-tests
+maintainer-check-list-of-tests:
+ @failcom='exit 1'; \
+ for f in x $$MAKEFLAGS; do \
+ case $$f in \
+ *=* | --[!k]*);; \
+ *k*) failcom='fail=yes';; \
+ esac; \
+ done; \
+ for subdir in $(TEST_SUBDIRS); do \
+ (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $@) || eval $$failcom; \
+ done; \
+ test -z "$$fail"
+
+maintainer-check: $(syntax_check_rules) maintainer-check-list-of-tests
## Look for test whose names can cause spurious failures when used as
## first argument to AC_INIT (chiefly because they might contain an
diff --git a/Makefile.in b/Makefile.in
index 9b976a7..6494ca0 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -246,6 +246,7 @@ top_build_prefix = @top_build_prefix@
top_builddir = @top_builddir@
top_srcdir = @top_srcdir@
SUBDIRS = lib . doc m4 tests
+TEST_SUBDIRS = lib/Automake/tests tests
bin_SCRIPTS = automake aclocal
CLEANFILES = $(bin_SCRIPTS)
AUTOMAKESOURCES = automake.in aclocal.in
@@ -275,7 +276,6 @@ do_subst = sed \
-e 's,address@hidden@],Generated from address@hidden; do not edit by
hand.,g' \
-e 's,address@hidden@],$(datadir),g'
-TEST_SUBDIRS = lib/Automake/tests tests
# Perl coverage statistics.
PERL_COVERAGE_DB = $(abs_top_builddir)/cover_db
@@ -1024,7 +1024,22 @@ clean-local: clean-coverage
.PHONY: $(syntax_check_rules)
$(syntax_check_rules): automake aclocal
-maintainer-check: $(syntax_check_rules)
+
+.PHONY: maintainer-check-list-of-tests
+maintainer-check-list-of-tests:
+ @failcom='exit 1'; \
+ for f in x $$MAKEFLAGS; do \
+ case $$f in \
+ *=* | --[!k]*);; \
+ *k*) failcom='fail=yes';; \
+ esac; \
+ done; \
+ for subdir in $(TEST_SUBDIRS); do \
+ (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $@) || eval $$failcom; \
+ done; \
+ test -z "$$fail"
+
+maintainer-check: $(syntax_check_rules) maintainer-check-list-of-tests
sc_test_names:
@m4_builtin_rx=`echo $(m4_builtins) | sed 's/ /|/g'`; \
m4_macro_rx="\\<($$m4_builtin_rx)\\>|\\<_?(A[CUMHS]|m4)_"; \
diff --git a/lib/Automake/tests/Makefile.am b/lib/Automake/tests/Makefile.am
index b4f09f1..c6254a3 100644
--- a/lib/Automake/tests/Makefile.am
+++ b/lib/Automake/tests/Makefile.am
@@ -1,6 +1,7 @@
## Process this file with automake to create Makefile.in
-# Copyright (C) 2002, 2003, 2008, 2009 Free Software Foundation, Inc.
+# Copyright (C) 2002, 2003, 2008, 2009, 2010 Free Software Foundation,
+# Inc.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -42,3 +43,5 @@ Version2.pl \
Version3.pl
EXTRA_DIST = $(TESTS)
+
+include $(top_srcdir)/CheckListOfTests.am
diff --git a/lib/Automake/tests/Makefile.in b/lib/Automake/tests/Makefile.in
index 4eb7c6a..d82bd74 100644
--- a/lib/Automake/tests/Makefile.in
+++ b/lib/Automake/tests/Makefile.in
@@ -15,7 +15,8 @@
@SET_MAKE@
-# Copyright (C) 2002, 2003, 2008, 2009 Free Software Foundation, Inc.
+# Copyright (C) 2002, 2003, 2008, 2009, 2010 Free Software Foundation,
+# Inc.
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -47,8 +48,9 @@ NORMAL_UNINSTALL = :
PRE_UNINSTALL = :
POST_UNINSTALL = :
build_triplet = @build@
+DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
+ $(top_srcdir)/CheckListOfTests.am
subdir = lib/Automake/tests
-DIST_COMMON = $(srcdir)/Makefile.am $(srcdir)/Makefile.in
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/amversion.m4 \
$(top_srcdir)/m4/auxdir.m4 $(top_srcdir)/m4/init.m4 \
@@ -303,11 +305,14 @@ Version2.pl \
Version3.pl
EXTRA_DIST = $(TESTS)
+am__tmk = tests-in-makefile-list.tmp
+am__tfs = tests-on-filesystem-list.tmp
+am__tdf = diff-in-tests-lists.tmp
all: all-am
.SUFFIXES:
.SUFFIXES: .html .log .pl
-$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
+$(srcdir)/Makefile.in: $(srcdir)/Makefile.am
$(top_srcdir)/CheckListOfTests.am $(am__configure_deps)
@for dep in $?; do \
case '$(am__configure_deps)' in \
*$$dep*) \
@@ -544,7 +549,7 @@ maintainer-clean-generic:
@echo "it deletes files that may require special tools to rebuild."
clean: clean-am
-clean-am: clean-generic mostlyclean-am
+clean-am: clean-generic clean-local mostlyclean-am
distclean: distclean-am
-rm -f Makefile
@@ -612,17 +617,60 @@ uninstall-am:
recheck-html
.PHONY: all all-am check check-TESTS check-am check-html clean \
- clean-generic distclean distclean-generic distdir dvi dvi-am \
- html html-am info info-am install install-am install-data \
- install-data-am install-dvi install-dvi-am install-exec \
- install-exec-am install-html install-html-am install-info \
- install-info-am install-man install-pdf install-pdf-am \
- install-ps install-ps-am install-strip installcheck \
- installcheck-am installdirs maintainer-clean \
+ clean-generic clean-local distclean distclean-generic distdir \
+ dvi dvi-am html html-am info info-am install install-am \
+ install-data install-data-am install-dvi install-dvi-am \
+ install-exec install-exec-am install-html install-html-am \
+ install-info install-info-am install-man install-pdf \
+ install-pdf-am install-ps install-ps-am install-strip \
+ installcheck installcheck-am installdirs maintainer-clean \
maintainer-clean-generic mostlyclean mostlyclean-generic pdf \
pdf-am ps ps-am recheck recheck-html uninstall uninstall-am
+.PHONY: maintainer-check-list-of-tests
+maintainer-check-list-of-tests:
+ @if diff -u /dev/null /dev/null >/dev/null 2>&1; then \
+ diff='diff -u'; \
+ else \
+ diff='diff'; \
+ fi; \
+ set X $(checked_test_extensions); shift; \
+ if test $$# -eq 0; then \
+ set X $(TEST_EXTENSIONS); shift; \
+ fi; \
+ if test $$# -eq 0; then \
+ echo '$@: internal error: $$(checked_test_extensions) and' \
+ '$$(TEST_EXTENSIONS) are both undefined or empty' >&2; \
+ exit 255; \
+ fi; \
+ lst='$(expected_list_of_tests)'; \
+ test -n "$$lst" || lst='$(TESTS)'; \
+ for t in $$lst; do \
+ echo "$$t"; \
+ done | sort >$(am__tmk); \
+ for ext in $$*; do \
+ ls *$$ext 2>/dev/null; \
+ if test $(srcdir) != $(builddir); then \
+ (cd $(srcdir) && ls *$$ext 2>/dev/null); \
+ fi; \
+ done | sort | uniq >$(am__tfs); \
+ if $$diff $(am__tmk) $(am__tfs) >$(am__tdf); then \
+ result=0; \
+ else \
+ echo '$@: list of tests in Makefile an on filesystem differ' >&2; \
+ echo "+ $$diff in-makefile on-filesystem" >&2; \
+ cat $(am__tdf) >&2; \
+ result=1; \
+ fi; \
+ rm -f $(am__tmk) $(am__tfs) $(am__tdf); \
+ exit $$result;
+
+.PHONY: clean-maintcheck-testslist-tmp
+clean-local: clean-maintcheck-testslist-tmp
+clean-maintcheck-testslist-tmp:
+ rm -f $(am__tmk) $(am__tfs) $(am__tdf)
+
# Tell versions [3.59,3.63) of GNU make to not export all variables.
# Otherwise a system limit (for SysV at least) may be exceeded.
.NOEXPORT:
diff --git a/tests/Makefile.am b/tests/Makefile.am
index 0cba6a8..26ee87e 100644
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -1062,6 +1062,13 @@ yflags-force-override.test \
yflags-force-conditional.test \
yflags-var-expand.test
+
+## Checking the test of tests.
+checked_test_extensions = .test
+expected_list_of_tests = $(handwritten_tests) $(generated_tests)
+include $(top_srcdir)/CheckListOfTests.am
+maintainer-check-list-of-tests: $(expected_list_of_tests)
+
# Each test case depends on defs, aclocal, and automake.
$(TEST_LOGS): defs aclocal-$(APIVERSION) automake-$(APIVERSION)
diff --git a/tests/Makefile.in b/tests/Makefile.in
index fd06043..98b5827 100644
--- a/tests/Makefile.in
+++ b/tests/Makefile.in
@@ -51,7 +51,8 @@ build_triplet = @build@
DIST_COMMON = README $(srcdir)/Makefile.am $(srcdir)/Makefile.in \
$(srcdir)/aclocal.in $(srcdir)/automake.in $(srcdir)/defs \
$(srcdir)/defs-static.in $(srcdir)/depmod-tests.am \
- $(srcdir)/instspc-tests.am $(srcdir)/parallel-tests.am
+ $(srcdir)/instspc-tests.am $(srcdir)/parallel-tests.am \
+ $(top_srcdir)/CheckListOfTests.am
subdir = tests
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
am__aclocal_m4_deps = $(top_srcdir)/m4/amversion.m4 \
@@ -1322,11 +1323,16 @@ yflags-force-override.test \
yflags-force-conditional.test \
yflags-var-expand.test
+checked_test_extensions = .test
+expected_list_of_tests = $(handwritten_tests) $(generated_tests)
+am__tmk = tests-in-makefile-list.tmp
+am__tfs = tests-on-filesystem-list.tmp
+am__tdf = diff-in-tests-lists.tmp
all: all-am
.SUFFIXES:
.SUFFIXES: .depmod .html .instspc .log .test
-$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(srcdir)/parallel-tests.am
$(srcdir)/instspc-tests.am $(srcdir)/depmod-tests.am $(am__configure_deps)
+$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(srcdir)/parallel-tests.am
$(srcdir)/instspc-tests.am $(srcdir)/depmod-tests.am
$(top_srcdir)/CheckListOfTests.am $(am__configure_deps)
@for dep in $?; do \
case '$(am__configure_deps)' in \
*$$dep*) \
@@ -1731,6 +1737,50 @@ $(depmod_tests:.depmod=.log): depmod-tests.sh
depmod-data.log
# expected log files from the `.depmod.log' suffix rule.
$(depmod_tests):
+.PHONY: maintainer-check-list-of-tests
+maintainer-check-list-of-tests:
+ @if diff -u /dev/null /dev/null >/dev/null 2>&1; then \
+ diff='diff -u'; \
+ else \
+ diff='diff'; \
+ fi; \
+ set X $(checked_test_extensions); shift; \
+ if test $$# -eq 0; then \
+ set X $(TEST_EXTENSIONS); shift; \
+ fi; \
+ if test $$# -eq 0; then \
+ echo '$@: internal error: $$(checked_test_extensions) and' \
+ '$$(TEST_EXTENSIONS) are both undefined or empty' >&2; \
+ exit 255; \
+ fi; \
+ lst='$(expected_list_of_tests)'; \
+ test -n "$$lst" || lst='$(TESTS)'; \
+ for t in $$lst; do \
+ echo "$$t"; \
+ done | sort >$(am__tmk); \
+ for ext in $$*; do \
+ ls *$$ext 2>/dev/null; \
+ if test $(srcdir) != $(builddir); then \
+ (cd $(srcdir) && ls *$$ext 2>/dev/null); \
+ fi; \
+ done | sort | uniq >$(am__tfs); \
+ if $$diff $(am__tmk) $(am__tfs) >$(am__tdf); then \
+ result=0; \
+ else \
+ echo '$@: list of tests in Makefile an on filesystem differ' >&2; \
+ echo "+ $$diff in-makefile on-filesystem" >&2; \
+ cat $(am__tdf) >&2; \
+ result=1; \
+ fi; \
+ rm -f $(am__tmk) $(am__tfs) $(am__tdf); \
+ exit $$result;
+
+.PHONY: clean-maintcheck-testslist-tmp
+clean-local: clean-maintcheck-testslist-tmp
+clean-maintcheck-testslist-tmp:
+ rm -f $(am__tmk) $(am__tfs) $(am__tdf)
+maintainer-check-list-of-tests: $(expected_list_of_tests)
+
# Each test case depends on defs, aclocal, and automake.
$(TEST_LOGS): defs aclocal-$(APIVERSION) automake-$(APIVERSION)
hooks/post-receive
--
GNU Automake
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Automake-commit] [SCM] GNU Automake branch, testsuite-work, updated. v1.11-820-g8061d84,
Stefano Lattarini <=