From: Stefano Lattarini Date: Sun, 30 Oct 2011 09:12:28 +0000 (+0100) Subject: missing: if GNU tar exists but fails when called, give up X-Git-Tag: v1.11.2b~18^2~18^2~2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=82bf2d3511ce31739156b60d51cda76e73eb6ec2;p=thirdparty%2Fautomake.git missing: if GNU tar exists but fails when called, give up * lib/missing: If the code trying to run GNU tar is reached, don't continue if the invoked GNU tar program fails, as there is little point in doing so (and can even be confusing and counter-productive). --- diff --git a/ChangeLog b/ChangeLog index 2d2bcdb22..92297ecfe 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,11 @@ +2011-12-22 Stefano Lattarini + + missing: if GNU tar exists but fails when called, give up + * lib/missing: If the code trying to run GNU tar is reached, + don't continue if the invoked GNU tar program fails, as there + is little point in doing so (and can even be confusing and + counter-productive). + 2011-12-22 Stefano Lattarini missing: miscellaneous fixlets diff --git a/lib/missing b/lib/missing index df2faf6f9..411123ff7 100755 --- a/lib/missing +++ b/lib/missing @@ -320,14 +320,13 @@ WARNING: \`$1' is $msg. You should only need it if tar*) shift - # We have already tried tar in the generic part. - # Look for gnutar/gtar before invocation to avoid ugly error - # messages. + # We have already tried tar in the generic part. So try with GNU tar. + # Look for gnutar/gtar before invocation to avoid ugly error messages. if (gnutar --version) > /dev/null 2>&1; then - gnutar "$@" && exit 0 + exec gnutar "$@" fi if (gtar --version) > /dev/null 2>&1; then - gtar "$@" && exit 0 + exec gtar "$@" fi firstarg=$1 if shift; then