summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJosh Gao <jmgao@google.com>2015-10-13 17:11:47 -0700
committerJosh Gao <jmgao@google.com>2015-10-13 17:11:47 -0700
commit2e2faec2a466dd190ddcb4f923a90f57e19ec56a (patch)
treebc0a231ceec8b0fa066718d94ac4a5f3c5a9add8
parentb85a9f3cf37b008417823b92cdf3c960ab7e728e (diff)
downloaddarwin-x86-2e2faec2a466dd190ddcb4f923a90f57e19ec56a.tar.gz
Don't use readlink to find gdb's location.
readlink isn't in POSIX, and the one available in on OS X does not support the -f option. Use $(cd $(dirname $0) && pwd) instead. Bug: http://b/24776250 Change-Id: Ic68d9ea50a06c230cb514909513400534d3f3ee1
-rwxr-xr-xbin/gdb2
1 files changed, 1 insertions, 1 deletions
diff --git a/bin/gdb b/bin/gdb
index 85d1900..d560b97 100755
--- a/bin/gdb
+++ b/bin/gdb
@@ -1,3 +1,3 @@
#!/bin/bash
-GDBDIR=$(dirname $(readlink -f $0))
+GDBDIR=$(cd $(dirname $0) && pwd)
PYTHONHOME="$GDBDIR/.." "$GDBDIR/gdb-orig" "$@"