diff options
Diffstat (limited to 'bin/retrace.sh')
-rwxr-xr-x | bin/retrace.sh | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/bin/retrace.sh b/bin/retrace.sh index 83a4d5e..2f274de 100755 --- a/bin/retrace.sh +++ b/bin/retrace.sh @@ -7,6 +7,18 @@ # you'll have to add escaped quotes around them, e.g. # "\"/My Directory/My File.txt\"" -PROGUARD_HOME=`dirname "$0"`/.. +# Account for possibly missing/basic readlink. +# POSIX conformant (dash/ksh/zsh/bash). +PROGUARD=`readlink -f "$0" 2>/dev/null` +if test "$PROGUARD" = '' +then + PROGUARD=`readlink "$0" 2>/dev/null` + if test "$PROGUARD" = '' + then + PROGUARD="$0" + fi +fi + +PROGUARD_HOME=`dirname "$PROGUARD"`/.. java -jar "$PROGUARD_HOME/lib/retrace.jar" "$@" |