summaryrefslogtreecommitdiffstats
path: root/stap-find-or-start-server
diff options
context:
space:
mode:
authorDave Brolley <brolley@redhat.com>2009-01-30 15:43:34 -0500
committerDave Brolley <brolley@redhat.com>2009-01-30 15:43:34 -0500
commit552276c8666dec5373d8312bc3498b1887ddb0a8 (patch)
tree55744f20b131641d506d0faf5462120deee2dc50 /stap-find-or-start-server
parentdf79aa4b87b39a64867c343f1bcd22c7e675aa43 (diff)
downloadsystemtap-steved-552276c8666dec5373d8312bc3498b1887ddb0a8.tar.gz
systemtap-steved-552276c8666dec5373d8312bc3498b1887ddb0a8.tar.xz
systemtap-steved-552276c8666dec5373d8312bc3498b1887ddb0a8.zip
More security checking for client/server. Set exec_prefix and sysconfdir at install time.
Diffstat (limited to 'stap-find-or-start-server')
-rwxr-xr-xstap-find-or-start-server11
1 files changed, 6 insertions, 5 deletions
diff --git a/stap-find-or-start-server b/stap-find-or-start-server
index efe23558..97e7caca 100755
--- a/stap-find-or-start-server
+++ b/stap-find-or-start-server
@@ -17,15 +17,16 @@
#
# Otherwise, it echoes -1 and exits with 1
-# Where are we installed?
-exec_prefix=`dirname $0`
-exec_prefix=`cd $exec_prefix && pwd`
+# INSTALL-HOOK These settings work for running the client from the source tree
+# INSTALL-HOOK using the dejagnu test harness and will be overridden at install
+# INSTALL-HOOK time.
+exec_prefix=
# Is there a server available?
-$exec_prefix/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=`$exec_prefix/stap-start-server "$@"`
+pid=`${exec_prefix}stap-start-server "$@"`
if test $? = 0; then
echo $pid
exit 0