From: Gary V. Vaughan Date: Thu, 18 Oct 2012 16:41:53 +0000 (+0700) Subject: extract-trace: only source funclib.sh when $progname is extract-trace. X-Git-Tag: v2.4.2.418~121 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=64c02af9f1d62963844f68c7d02c46d2b9100216;p=thirdparty%2Flibtool.git extract-trace: only source funclib.sh when $progname is extract-trace. * build-aux/extract-trace: $usage is too generic, and can cause sourced extract-trace to re-source options-parser. We already require that funclib.sh be sourced before sourcing options-parser, so it's safer to check that $progname is correct before sourcing options-parser again from here. Signed-off-by: Gary V. Vaughan --- diff --git a/build-aux/extract-trace b/build-aux/extract-trace index 2143c76f9..d8be25cab 100755 --- a/build-aux/extract-trace +++ b/build-aux/extract-trace @@ -1,8 +1,8 @@ #! /bin/sh # Make sure we've evaluated scripts we depend on. -test -n "$progpath" || . `echo "$0" |${SED-sed} 's|[^/]*$||'`/funclib.sh -test -n "$usage" || . `echo "$0" |${SED-sed} 's|[^/]*$||'`/options-parser +test -z "$progpath" && . `echo "$0" |${SED-sed} 's|[^/]*$||'`/funclib.sh +test extract-trace = "$progname" && . `echo "$0" |${SED-sed} 's|[^/]*$||'`/options-parser # Set a version string. scriptversion=2012-10-07.10; # UTC