X-Git-Url: http://git.annexia.org/?p=libguestfs.git;a=blobdiff_plain;f=run;h=7e18edcac69944abf36965697a9c1dd35fe15ee3;hp=04152b1b524416d38833a447780e82617e70606e;hb=3b9d52b2a82bd6cdb10aa267b514805ad3f5e552;hpb=5790f5bfafb12cc2ed9365461bf66e0fdfde7150 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 "$@"