freebsd-ports/astro/google-earth/files/browserwrapper
Juergen Lock 2e40e8ae1e - Chase updated distfile, at 5.1.3535.3218 now. [1]
- Add browser wrapper hack that restores LD_LIBRARY_PATH so a native
  BROWSER=firefox3 doesn't pick up Linux libs and fails to start.

Submitted by:	pointyhat via erwin [1]
2010-05-17 17:37:08 +00:00

18 lines
422 B
Bash

#! /bin/sh
# browser wrapper script to restore original LD_LIBRARY_PATH so a native
# browser won't pick up linux libs from google earth and fail to start
if [ -n "${REAL_LD_LIBRARY_PATH}" ]
then
export LD_LIBRARY_PATH="${REAL_LD_LIBRARY_PATH}"
else
unset LD_LIBRARY_PATH
fi
BROWSER="$(/usr/bin/which ${REAL_BROWSER})"
if [ -x "${BROWSER}" ]
then
exec "${BROWSER}" "$@"
else
echo browser not found: $REAL_BROWSER
fi