parallel-tests: avoid possible implicit "make all" in test-suite.log rule
authorStefano Lattarini <stefano.lattarini@gmail.com>
Mon, 30 Dec 2013 22:21:03 +0000 (23:21 +0100)
committerStefano Lattarini <stefano.lattarini@gmail.com>
Mon, 30 Dec 2013 22:21:03 +0000 (23:21 +0100)
This change fixes automake bug#16302.

* lib/am/check.am ($(TEST_SUITE_LOG)): Avoid running "make $redo_logs"
when $redo_logs expands to empty, since in that case we are actually
ending up invoking a full "make all".  That shouldn't be required, and
can cause slowdowns for people implementing their extra "laziness
wrappers" around check-TESTS (automake bug#16302).
* NEWS: Update.

Signed-off-by: Stefano Lattarini <stefano.lattarini@gmail.com>
NEWS
lib/am/check.am

diff --git a/NEWS b/NEWS
index dd2812a82c699a0d16c0c43e94c4c77f8ab3d43c..a73804a3998f134bc3286a78b85031f1ce1bd702 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -93,6 +93,10 @@ New in 1.15:
     implementation of the TAP driver (that is documented in the manual)
     is more portable and has feature parity with the perl implementation.
 
+  - The rule generating 'test-suite.log' no longer risk incurring in an
+    extra useless "make all" recursive invocation in some corner cases
+    (automake bug#16302).
+
 * Bug fixes:
 
   - The user can now extend the special .PRECIOUS target, the same way
index 7012d5a2b5c2a3343132f1e76f3c7745247836e0..4d2a498a306000116124b091ec01aa9d9e2cc8c8 100644 (file)
@@ -274,7 +274,9 @@ $(TEST_SUITE_LOG): $(TEST_LOGS)
        if test -n "$$am__remaking_logs"; then \
          echo "fatal: making $(TEST_SUITE_LOG): possible infinite" \
               "recursion detected" >&2; \
-       else \
+## Invoking this unconditionally could cause a useless "make all" to
+## be invoked when '$redo_logs' expands to empty (automake bug#16302).
+       elif test -n "$$redo_logs"; then \
          am__remaking_logs=yes $(MAKE) $(AM_MAKEFLAGS) $$redo_logs; \
        fi; \
        if $(am__make_dryrun); then :; else \