#!/bin/sh
#
# @(#)start.sh	6.6 00/01/14
# Startup wrapper script for xmcd, cda and related programs.
# This script is used to setup the basic startup environment,
# and allows network sharing of xmcd files under different
# platforms and architectures.
#
#    xmcd  - Motif(tm) CD Audio Player
#    cda   - Command-line CD Audio Player
#
#    Copyright (C) 1993-2000  Ti Kan
#    E-mail: ti@amb.org
#
#    This program is free software; you can redistribute it and/or modify
#    it under the terms of the GNU General Public License as published by
#    the Free Software Foundation; either version 2 of the License, or
#    (at your option) any later version.
#
#    This program is distributed in the hope that it will be useful,
#    but WITHOUT ANY WARRANTY; without even the implied warranty of
#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
#    GNU General Public License for more details.
#
#    You should have received a copy of the GNU General Public License
#    along with this program; if not, write to the Free Software
#    Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
#
PATH=${PATH}:/sbin:/usr/sbin:/bin:/usr/bin
export PATH

if [ -z "$XMCD_LIBDIR" ]
then
	XMCD_LIBDIR=/usr/local/share/xmcd
	export XMCD_LIBDIR
fi

XFILESEARCHPATH=/usr/local/lib/X11/%T/%N%S:$XFILESEARCHPATH
XUSERFILESEARCHPATH=$HOME/.xmcdcfg/%N%S:$XUSERFILESEARCHPATH
XKEYSYMDB=/usr/X11R6/lib/X11/XKeysymDB

PROG=`basename $0 2>/dev/null`

export XFILESEARCHPATH XUSERFILESEARCHPATH XKEYSYMDB

exec /usr/local/libexec/xmcd/$PROG ${1+"$@"}
