diff options
author | Steven Bennetts <steve@lindenlab.com> | 2008-02-01 02:23:35 +0000 |
---|---|---|
committer | Steven Bennetts <steve@lindenlab.com> | 2008-02-01 02:23:35 +0000 |
commit | b302f15deea0f4f7f5de75bfd3776c17021b6444 (patch) | |
tree | 7a2842445c8dd6c8537bd9f8d4d171e95b85a845 /indra/newview/linux_tools | |
parent | 6ae0a9e2c1ac51385c341ff4a93384950e2e7e40 (diff) |
EFFECTIVE MERGE: maint-viewer-3 -r 77368:77381 -> release
ACTUAL MERGE: merge maint-viewer-3-merge -r 79051 -> release
Diffstat (limited to 'indra/newview/linux_tools')
-rwxr-xr-x | indra/newview/linux_tools/launch_url.sh | 14 | ||||
-rwxr-xr-x | indra/newview/linux_tools/wrapper.sh | 6 |
2 files changed, 16 insertions, 4 deletions
diff --git a/indra/newview/linux_tools/launch_url.sh b/indra/newview/linux_tools/launch_url.sh index e6450ad5ff..d2c8919d46 100755 --- a/indra/newview/linux_tools/launch_url.sh +++ b/indra/newview/linux_tools/launch_url.sh @@ -17,10 +17,16 @@ URL="$1" if [ -z "$URL" ]; then - echo Usage: $0 URL + echo "Usage: $0 URL" exit fi +# restore LD_LIBRARY_PATH from SAVED_LD_LIBRARY_PATH if it exists +if [ "${SAVED_LD_LIBRARY_PATH+isset}" = "isset" ]; then + export LD_LIBRARY_PATH="${SAVED_LD_LIBRARY_PATH}" + echo "$0: Restored library path to '${SAVED_LD_LIBRARY_PATH}'" +fi + # if $BROWSER is defined, use it. XBROWSER=`echo "$BROWSER" |cut -f1 -d:` if [ ! -z "$XBROWSER" ]; then @@ -37,8 +43,8 @@ if [ ! -z "$XBROWSER" ]; then $XBROWSER "$URL" & exit fi - echo "Couldn't find the browser specified by \$BROWSER ($BROWSER)" - echo "Trying some others..." + echo "$0: Couldn't find the browser specified by \$BROWSER ($BROWSER)" + echo "$0: Trying some others..." fi # else kfmclient @@ -81,6 +87,6 @@ if which netscape >/dev/null; then exit fi -echo 'Failed to find a known browser. Please consider setting the $BROWSER environment variable.' +echo '$0: Failed to find a known browser. Please consider setting the $BROWSER environment variable.' # end. diff --git a/indra/newview/linux_tools/wrapper.sh b/indra/newview/linux_tools/wrapper.sh index 4ed06099fc..a5cb6ae8a7 100755 --- a/indra/newview/linux_tools/wrapper.sh +++ b/indra/newview/linux_tools/wrapper.sh @@ -61,10 +61,16 @@ fi SCRIPTSRC=`readlink -f "$0" || echo "$0"` RUN_PATH=`dirname "${SCRIPTSRC}" || echo .` +echo "Running from ${RUN_PATH}" cd "${RUN_PATH}" # Re-register the secondlife:// protocol handler every launch, for now. ./register_secondlifeprotocol.sh +## Before we mess with LD_LIBRARY_PATH, save the old one to restore for +## subprocesses that care. +if [ "${LD_LIBRARY_PATH+isset}" = "isset" ]; then + export SAVED_LD_LIBRARY_PATH="${LD_LIBRARY_PATH}" +fi if [ -n "$LL_TCMALLOC" ]; then tcmalloc_libs='/usr/lib/libtcmalloc.so.0 /usr/lib/libstacktrace.so.0 /lib/libpthread.so.0' |