#! /bin/sh

PREREQ=""

prereqs()
{
	echo "$PREREQ"
}

case $1 in
prereqs)
	prereqs
	exit 0
	;;
esac

. /scripts/functions
. /scripts/functions-uniklu

chvt 1

if [ "${BOOT}" = "installimage" ]; then
  [ "$quiet" != "y" ] && log_begin_msg "Initializing local disks"
#  # prepare local partitions for grub installation:
#  mkdir -p /target
#  ${MOUNT} -t ext4 LABEL=UNIKLU /target || MOUNTFAILED="yes"
#  if [ "$MOUNTFAILED" = "yes" ]; then
#    panic "mounting /target failed!"
#  fi
#
#  # possible fix afs partition sizze:
#
#  if [ -n "$BOOTSIZE" ]; then  
#    BOOTSIZE=$(echo $BOOTSIZE \* 1024 \*1024 | bc -l)
#    BOOTSIZE=${BOOTSIZE%%.*}
#  fi
#
#  cp -p /target/etc/fstab.template /target/etc/fstab
#  FOUNDLOCAL=""
#  mkdir -p /local
#  ${MOUNT} -t ext3 -o nosuid LABEL=LOCAL /local && FOUNDLOCAL="yes"
#  if [ "${FOUNDLOCAL}" = "yes" ]; then
#    [ "$quiet" != "y" ] && _log_msg "adding local partition to fstab"
#    cat >> /target/etc/fstab <<EOT
#LABEL=LOCAL /local ext3 defaults,nosuid 0 2
#EOT
#    mkdir -p /target/local
#    /bin/umount /local
#  else
#    rmdir /local
#  fi
fi

[ "$quiet" != "y" ] && log_end_msg

