#! /bin/csh
#
#   This script installs bwe on our encore multimax.  This is not a
#   workstation, but we expect to use the suns as output devices.
#   The setting of NOFONTS disables font compilation (not needed);
#   The arch setting is 'multimax'.  The edt.bind.multimax file is
#   a duplicate of the edt.bind.sun.  Note that X11R3 exists in a
#   different location on this machine.
#

set X11info = (X11LIBS=/pro/x11/multi3/usr/lib/libX11.a \
   X11INCL=/pro/x11/multi3/usr/include \
   X11LIBDIR=/pro/x11/multi3/usr/lib/X11)
set OTHERinfo = (OPTIMIZE=1)
setenv NOFONTS 1

if ($?DISPLAY == 0) then
echo you must run X11 for this script to work.
exit (1)
endif

echo setting PRO and ARCH and path
setenv PRO `(cd ..; pwd)`
setenv ARCH `arch`
set path = ($PRO/bwe/cmd $PRO/bwe/cmd/$ARCH $PRO/cmd $PRO/cmd/$ARCH $path)

if (! -e $PRO/lib) then
echo making lib
(cd $PRO; mkdir lib)
endif

if (! -e $PRO/include) then
echo making include
(cd $PRO; mkdir include)
endif

if (! -e $PRO/cmd) then
echo making cmd
(cd $PRO; mkdir cmd; mkdir cmd/$ARCH)
endif

echo making bwe
make $X11info $OTHERinfo newmachine
make clean

