#!/bin/sh

libpath="/usr/lib64/dice"
bindir="/usr/lib64/dice"

if test -f "$0.in"; then
    bindir="."
    libpath="./wsclient/.libs"
    export MONO_PATH="../Novell.IceDesktop:$MONO_PATH"
    echo "detected build tree, using local binary: $@"
fi

export LD_LIBRARY_PATH="$libpath:$LD_LIBRARY_PATH"
exec mono --debug "$bindir/diced.exe" "$@"
