#!/bin/csh

# ****************************************************************************
#  FILE     : build
#  SHORTNAME: build

#  PURPOSE  : Shell scipt to call make 
#	      1) kernel in the directory kernel/source
#	      2) X user interface in xgui/source
#	      3) compiler in compiler/source

#  AUTHOR   : Tilman Sommer, Niels Mache, Thomas Korb
#  DATE     : 22.05.91 (A. Zell)

#  MODIFICATIONS:
#  22.05.91: cosmetic changes

#             (c) 1990-92 by SNNS-Group
#             Institut fuer parallele und verteilte Hoechstleistungsrechner
#             Universitaet Stuttgart
# ****************************************************************************



echo "************************************************"
echo "*                                              *"
echo "*  SNNS  - Stuttgart Neural Network Simulator  *"
echo "*                                              *"
echo "*         building SNNS version 2.1 ...        *"
echo "*                                              *"
echo "************************************************"
echo ""
set rootdir = `echo $cwd`
if ( $1 == 'all' || $1 == 'kernel' || $1 == 'sim') then
	echo "Building kernel ... "
	cd kernel/sources
	echo "Compiling ..."
	make all
	echo "Installing ..."
	make install
	cd ../.. 
	echo "Done."
	echo ""
else
endif

if ( $1 == 'all' || $1 == 'xgui' || $1 == 'sim') then
	echo "Building XGUI ... "
	cd xgui/sources
	echo "Compiling ..."
	make all
	echo "Installing ..."
	make install
	cd ../.. 
	echo "Done."
	echo ""
else
endif

#if ( $1 == 'all' || $1 == 'compiler') then
#	echo "Building compiler ... "
#	cd compiler/sources 
#	echo "Compiling ..."
#	make all
#	echo "Installing ..."
#	make install
#	cd ../.. 
#	echo "Done."
#	echo ""
#else
#endif
