Merge branch 'simplify-exit-trap-workaround' into maint
[platform/upstream/automake.git] / t / subdir-order.sh
index 7a84b34..0ce19d9 100644 (file)
@@ -124,6 +124,17 @@ all-local:
        : > run
 END
 
+echo dummy: > Makefile
+if using_gmake; then
+  jobs=-j12
+elif $MAKE -j12; then
+  jobs=-j12
+elif $MAKE -j 12; then
+  jobs="-j 12"
+else
+  jobs=none
+fi
+rm -f Makefile
 
 $ACLOCAL
 $AUTOCONF
@@ -131,7 +142,8 @@ $AUTOMAKE -c --add-missing
 
 ./configure
 
-for j in '' -j12; do
+for j in '' "$jobs"; do
+  test x"$j" = x"none" && continue
   $MAKE $j
   test -f run
   test -f sub0/run