diff options
author | Mark Wielaard <mjw@redhat.com> | 2009-01-23 14:28:47 +0100 |
---|---|---|
committer | Mark Wielaard <mjw@redhat.com> | 2009-01-23 14:28:47 +0100 |
commit | c3bad3042df505a3470f1e20b09822a9df1d4761 (patch) | |
tree | 6842e8eaa705e406379d34cf07a85431b6d71344 /stap-find-or-start-server | |
parent | 750b1f2f5c84acaf0776de5239dc81e2e95c1dec (diff) | |
parent | f120873cb40cfc16cc94f06fd722abc927b96227 (diff) | |
download | systemtap-steved-c3bad3042df505a3470f1e20b09822a9df1d4761.tar.gz systemtap-steved-c3bad3042df505a3470f1e20b09822a9df1d4761.tar.xz systemtap-steved-c3bad3042df505a3470f1e20b09822a9df1d4761.zip |
Merge branch 'master' into pr6866.
Diffstat (limited to 'stap-find-or-start-server')
-rwxr-xr-x | stap-find-or-start-server | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/stap-find-or-start-server b/stap-find-or-start-server index 32a45052..efe23558 100755 --- a/stap-find-or-start-server +++ b/stap-find-or-start-server @@ -2,7 +2,7 @@ # Find or start a systemtap server # -# Copyright (C) 2008 Red Hat Inc. +# Copyright (C) 2008, 2009 Red Hat Inc. # # This file is part of systemtap, and is free software. You can # redistribute it and/or modify it under the terms of the GNU General @@ -17,16 +17,20 @@ # # Otherwise, it echoes -1 and exits with 1 +# Where are we installed? +exec_prefix=`dirname $0` +exec_prefix=`cd $exec_prefix && pwd` + # Is there a server available? -stap-find-servers >/dev/null 2>&1 && echo 0 && exit 0 +$exec_prefix/stap-find-servers >/dev/null 2>&1 && echo 0 && exit 0 # No server available, try to start one. -pid=`stap-start-server` +pid=`$exec_prefix/stap-start-server "$@"` if test $? = 0; then echo $pid exit 0 fi # Could not find or start a server -echo -1 +echo "-1" exit 1 |