diff options
author | Stefano Lattarini <stefano.lattarini@gmail.com> | 2012-07-02 20:58:23 +0200 |
---|---|---|
committer | Stefano Lattarini <stefano.lattarini@gmail.com> | 2012-07-02 21:05:21 +0200 |
commit | 18dac9077caa49f69aa39e306b146ae700e14e9c (patch) | |
tree | dbe08d8f658906d7322c909d955baa46b8753098 /contrib/check-html.am | |
parent | 53d49841f875a7a1e86a874ee5e5d171872ac733 (diff) | |
download | automake-18dac9077caa49f69aa39e306b146ae700e14e9c.tar.gz |
contrib: simple improvements to check-html
Related to automake bug#11287.
* contrib/t/check-html.am (.log.html): Do not look for $RST2HTML in
the environment, looking for $(RST2HTML) should be enough (also, the
pre-existing code was broken, because it single-quoted $RST2HTML).
Fix the loop-and-search implementation to be more similar to the
one in 'contrib/t/parallel-tests-html.sh'. Prefer 'mv -f' over bare
'mv'. Do not break the recipe in
Signed-off-by: Stefano Lattarini <stefano.lattarini@gmail.com>
Diffstat (limited to 'contrib/check-html.am')
-rw-r--r-- | contrib/check-html.am | 20 |
1 files changed, 9 insertions, 11 deletions
diff --git a/contrib/check-html.am b/contrib/check-html.am index 4495ac05c..47e4f47ec 100644 --- a/contrib/check-html.am +++ b/contrib/check-html.am @@ -29,18 +29,16 @@ mostlyclean-check-html: rm -f $(TEST_SUITE_HTML) .log.html: - @list='$(RST2HTML) $$RST2HTML rst2html rst2html.py'; \ - for r2h in $$list; do \ - if ($$r2h --version) >/dev/null 2>&1; then \ - R2H=$$r2h; \ - fi; \ - done; \ - if test -z "$$R2H"; then \ - echo >&2 "cannot find rst2html, cannot create $@"; \ + @list='$(RST2HTML) rst2html rst2html.py'; \ + while :; do \ + for r2h in $$list; do \ + if ($$r2h --version) >/dev/null 2>&1; then break 2; \ + else :; fi; \ + done; \ + echo "cannot find rst2html, cannot create $@" >&2; \ exit 2; \ - fi; \ - $$R2H $< >$@.tmp - @mv $@.tmp $@ + done; \ + $$r2h $< >$@-t && mv -f $@-t $@ # Be sure to run check first, and then to convert the result. # Beware of concurrent executions. Run "check" not "check-TESTS", as |