#! /usr/bin/sh
#
# file: install.sh
#
# this is the installation script for the ISIP segmentation tool
#

# clean up pre-existing stuff
#
rm -f $ISIP_TRANSCRIBER/bin/$ISIP_BINARY/*
rm -f $ISIP_TRANSCRIBER/lib/$ISIP_BINARY/*

# compile and install the signal plotting utilities
#
echo "Installing signal plotting utilities..."
cd $ISIP_TRANSCRIBER/widgets/signal_plot/
make clean
make install
make clean
echo "Installing energy plotting utilities..."
cd $ISIP_TRANSCRIBER/widgets/energy_plot/
make clean
make install
make clean
echo "Installing spectrogram utilities..."
cd $ISIP_TRANSCRIBER/widgets/spec_plot/
make clean
make install
make clean
echo "Installing fourier transform utilities..."
cd $ISIP_TRANSCRIBER/class/fourier_transform/
make clean
make install
make clean
echo "Installing signal utilities..."
cd $ISIP_TRANSCRIBER/class/signal/
make clean
make install
make clean
cd $ISIP_TRANSCRIBER/util/run_tcl/
make clean
make install
make clean

# compile and install the audio play utilities
#
echo "Installing audio play utilities..."
cd $ISIP_TRANSCRIBER/util/excise_signal/
make clean
make install
make clean

# if you are not going to use a DAT player for audio play, you can
# comment out the following four (4) lines for faster installation
#
cd $ISIP_TRANSCRIBER/util/isip_naplay/
./MAKE
mv $ISIP_TRANSCRIBER/util/isip_naplay/naplay/naplay $ISIP_TRANSCRIBER/bin/$ISIP_BINARY/isip_naplay
./MAKE clean

# the installation is now complete, prompt the user
#
echo "The installation was successful."
echo "You can invoke the tool by typing 'transcriber' at your shell prompt."

# end of file
#
