#! /bin/sh
#
# Copyright (c) 1991, by Sun Microsystems, Inc.
#
#

# don't know what any of it means, but it seems to work!- devjani

trap 'exit 3' 15

DO_PCNFSD=0
DO_MSG=0
DO_SLIP=0
NDEVICES=1

#
# determine if PC-NFS server should be installed
#
ans=`ckyorn -d y \
-p "Do you want to install the PC-NFS daemon ?"
` || exit $?
if [ "$ans" = y ]
then
CLASSES="$CLASSES pcpcnfsd pcbin1 pcman"
DO_PCNFSD=1
fi

#
# determine if PC-NFS console messaging server should be installed
#
ans=`ckyorn -d y \
-p "Do you want to install the Console Messaging server ?"
` || exit $?
if [ "$ans" = y ]
then
CLASSES="$CLASSES pcmsg pcbin2"
DO_MSG=1
fi


#
# determine if slip driver and utilities should be installed
#
ans=`ckyorn -d y \
-p "Do you want to install the PC-NFS Slip Driver ?"
` || exit $?
if [ "$ans" = y ]
then
CLASSES="$CLASSES pcslip"
DO_SLIP=1
NDEVICES=`ckrange -l 1 -u 32 -d 1 \
-p "How many slip interfaces do you want to configure ?"
` || exit $?
fi

#
# make parameters available to pkgadd and other scripts
#
cat >$1 <<!
CLASSES='$CLASSES'
DO_PCNFSD='$DO_PCNFSD'
DO_MSG='$DO_MSG'
DO_SLIP='$DO_SLIP'
NDEVICES='$NDEVICES'
!
exit 0
