From: Richard W.M. Jones Date: Sat, 16 Apr 2011 14:29:58 +0000 (+0100) Subject: run script: Don't depend on libtool being installed. X-Git-Tag: 1.11.2~5 X-Git-Url: http://git.annexia.org/?p=libguestfs.git;a=commitdiff_plain;h=5d139fa8a4a7f9ff65e7b936fd7376f661c72f48 run script: Don't depend on libtool being installed. Also use 'exec' to run the program. --- diff --git a/run b/run index 04152b1..7e18edc 100755 --- a/run +++ b/run @@ -38,5 +38,11 @@ export LD_LIBRARY_PATH="$b/src/.libs" export LIBGUESTFS_PATH="$b/appliance" export PERL5LIB="$b/perl/blib/lib:$b/perl/blib/arch" +# Do we have libtool? If we have it then we can use it to make +# running valgrind simpler. However don't depend on it. +if libtool --help >/dev/null 2>&1; then + libtool="libtool --mode=execute" +fi + # Run the program. -libtool --mode=execute "$@" +exec $libtool "$@"