From: Benjamin Poirier Date: Mon, 10 Aug 2009 20:38:31 +0000 (-0400) Subject: lttv: Look for executable in run script X-Git-Tag: v0.12.20~54 X-Git-Url: https://git.lttng.org/?p=lttv.git;a=commitdiff_plain;h=011e5097367fb6ca911b128beee969994d4cf5d5 lttv: Look for executable in run script When static link mode is enabled, the main lttv executable does not end up in the same directory. Look for it in the two places where it might be. Signed-off-by: Benjamin Poirier --- diff --git a/runlttv b/runlttv index fd774d30..31728d65 100755 --- a/runlttv +++ b/runlttv @@ -30,9 +30,11 @@ ARGS=\ "-L lttv/modules/gui/interrupts/.libs -m interrupts "\ "-L lttv/modules/gui/histogram/.libs -m guihistogram" -LTTV_EXEC="lttv/lttv/.libs/lttv.real" - -if [ ! -e "$LTTV_EXEC" ]; then +if [ -e "lttv/lttv/.libs/lttv.real" ]; then + LTTV_EXEC="lttv/lttv/.libs/lttv.real" +elif [ -e "lttv/lttv/lttv.real" ]; then + LTTV_EXEC="lttv/lttv/lttv.real" +else echo "error: LTTV should be compiled before running this script." >/dev/stderr exit 1 fi