freebsd-ports/www/opera/files/operapluginwrapper

25 lines
338 B
Text
Raw Normal View History

#!/bin/sh
if [ -n "$5" ]; then
ELFTYPE=`brandelf $5`
elif [ -n "$4" ]; then
ELFTYPE=`brandelf $4`
elif [ -n "$3" ]; then
ELFTYPE=`brandelf $3`
fi
WRAPPER="freebsd"
case "${ELFTYPE}" in
*SVR4*|*Linux*)
if [ -x "$0.linux" ]; then
LD_LIBRARY_PATH=
export LD_LIBRARY_PATH
WRAPPER="linux"
fi
;;
esac
exec $0.$WRAPPER $@