#!/bin/sh

dist_bin=`dirname $0`
dp_prefix=/opt/local
dp_mozilla=mozilla-1.7.12

MOZILLA_HOME=$dp_prefix/lib/$dp_mozilla

if [ -z "$MOZ_PLUGIN_PATH" ]; then
    MOZ_PLUGIN_PATH=$dp_prefix/lib/$dp_mozilla/plugins
    export MOZ_PLUGIN_PATH
fi

if [ -n "$LD_LIBRARY_PATH" ]; then
  LD_LIBRARY_PATH=$MOZILLA_HOME:$LD_LIBRARY_PATH
else
  LD_LIBRARY_PATH=$MOZILLA_HOME
fi
export DYLD_FALLBACK_LIBRARY_PATH=$DYLD_FALLBACK_LIBRARY_PATH:$dp_prefix/lib/$dp_mozilla/

MOZILLA_FIVE_HOME=$MOZILLA_HOME
export MOZILLA_FIVE_HOME

exec "$dist_bin/galeon-bin" "$@"
