changelog: don't cluster multiple entries under the same "date line"
[automake.git] / lib / am / check-html.am
blob13f0a47a886c7d4c32c7c2e2288e1e5a776cde5b
1 ## automake - create Makefile.in from Makefile.am
2 ## Copyright (C) 2001, 2003, 2006, 2007, 2008, 2009, 2010, 2011, 2012
3 ## Free Software Foundation, Inc.
4 ##
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)
8 ## any later version.
9 ##
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/>.
18 ## Makefile.am fragment to produce HTML output from RST-formatted
19 ## log files produced by the parallel-tests output.
20 ## This fragment was part of the automake core in the 1.11.x release
21 ## series, but is to be moved out in the 1.12 release.
23 TEST_SUITE_HTML = $(TEST_SUITE_LOG:.log=.html)
25 mostlyclean-am: am--mostlyclean-test-html
26 .PHONY: am--mostlyclean-test-html
27 am--mostlyclean-test-html:
28 ## Expand $(TEST_LOGS) only once, to avoid exceeding line length limits.
29         list='$(TEST_LOGS:.log=.html)'; test -z "$$list" || rm -f $$list
30         rm -f $(TEST_SUITE_HTML)
32 .log.html:
33         @list='$(RST2HTML) $$RST2HTML rst2html rst2html.py';            \
34         for r2h in $$list; do                                           \
35           if ($$r2h --version) >/dev/null 2>&1; then                    \
36             R2H=$$r2h;                                                  \
37           fi;                                                           \
38         done;                                                           \
39         if test -z "$$R2H"; then                                        \
40           echo >&2 "cannot find rst2html, cannot create $@";            \
41           exit 2;                                                       \
42         fi;                                                             \
43         $$R2H $< >$@.tmp
44         @mv $@.tmp $@
46 # Be sure to run check first, and then to convert the result.
47 # Beware of concurrent executions.  Run "check" not "check-TESTS", as
48 # check-SCRIPTS and other dependencies are rebuilt by the former only.
49 # And expect check to fail.
50 check-html recheck-html:
51         @target=`echo $@ | sed 's/-html$$//'`; \
52         rv=0; $(MAKE) $(AM_MAKEFLAGS) $$target || rv=$$?; \
53 ## The nullification of $(TEST_LOGS) is required to ensure that
54 ## "make recheck-html" do not try to uselessly re-run tests.
55         $(MAKE) $(AM_MAKEFLAGS) $(TEST_SUITE_HTML) TEST_LOGS= || exit 4; \
56         exit $$rv
58 AM_RECURSIVE_TARGETS += check-html recheck-html
60 .PHONY: check-html recheck-html
61 .MAKE: check-html recheck-html