3 ## Copyright (C) 2011-2012 Free Software Foundation, Inc.
5 ## This program is free software; you can redistribute it and/or modify
6 ## it under the terms of the GNU General Public License as published by
7 ## the Free Software Foundation; either version 2, or (at your option)
10 ## This program is distributed in the hope that it will be useful,
11 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
12 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 ## GNU General Public License for more details.
15 ## You should have received a copy of the GNU General Public License
16 ## along with this program. If not, see <http://www.gnu.org/licenses/>.
19 ## Temporary files used in the 'check-list-of-tests' recipe.
20 am__tmk = tests-in-makefile-list.tmp
21 am__tfs = tests-on-filesystem-list.tmp
22 am__tdf = diff-in-tests-lists.tmp
24 ## Check that the list of tests given in the Makefile is equal to the
25 ## list of all test scripts in the Automake testsuite.
26 .PHONY: maintainer-check-list-of-tests
27 maintainer-check-list-of-tests:
28 ## Prefer unified diffs over plain diffs, for readability.
29 @if diff -u /dev/null /dev/null >/dev/null 2>&1; then \
34 ## List of tests in Makefile.
35 lst='$(expected_list_of_tests)'; \
36 test -n "$$lst" || lst='$(TESTS)'; \
39 done | sort >$(am__tmk); \
40 ## List of subdirs where to look for tests.
41 dirs='$(test_subdirs)'; \
42 test -n "$$dirs" || dirs=.; \
43 ## List of tests on filesystem. Be careful to cater for VPATH builds too.
44 test_extensions='$(TEST_EXTENSIONS)'; \
45 for ext in $$test_extensions; do \
46 for dir in $$dirs; do \
47 ls $$dir/*$$ext 2>/dev/null; \
48 if test $(srcdir) != $(builddir); then \
49 ($(am__cd) $(srcdir) && ls $$dir/*$$ext 2>/dev/null); \
52 done | sed 's,^\./,,' | sort | uniq >$(am__tfs); \
53 ## Compare the two lists, complain if they differ.
54 if $$diff $(am__tmk) $(am__tfs) >$(am__tdf); then \
57 echo '$@: list of tests in Makefile an on filesystem differ' >&2; \
58 echo "+ $$diff in-makefile on-filesystem" >&2; \
62 rm -f $(am__tmk) $(am__tfs) $(am__tdf); \
65 .PHONY: clean-maintcheck-testslist-tmp
66 clean-local: clean-maintcheck-testslist-tmp
67 clean-maintcheck-testslist-tmp:
68 rm -f $(am__tmk) $(am__tfs) $(am__tdf)