From e9524eacee04f8fe09436329ae0bcf9819389c67 Mon Sep 17 00:00:00 2001 From: Robert Kaiser Date: Tue, 28 Apr 2009 22:07:26 +0200 Subject: [PATCH] refine finding of XULRunner a bit to accept versioned dirs like in Fennec Beta 1 for N810 --- mandelbrot | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/mandelbrot b/mandelbrot index 62bb8d8..7d05df5 100755 --- a/mandelbrot +++ b/mandelbrot @@ -51,12 +51,19 @@ if test -z "$xulrunner" && test -e "/usr/local/xulrunner/xulrunner"; then xulrunner="/usr/local/xulrunner/xulrunner" fi if test -z "$xulrunner"; then - if test -n `which xulrunner`; then - xulrunner=`which xulrunner` - else - echo "XULRunner not found!" - exit 1 - fi + # catch the last one of those in versioned directories + for xrbin in /usr/local/lib/xulrunner-*/xulrunner; do + if test -e "$xrbin"; then + xulrunner="$xrbin" + fi + done +fi +if test -z "$xulrunner"; then + xulrunner=`which xulrunner` +fi +if test -z "$xulrunner"; then + echo "XULRunner not found!" + exit 1 fi # add -jsconsole for debugging -- 2.35.3