#!/bin/sh
# vliloconf
# This is a rewrite of liloconf, from Slackware 9.1 by Patrick V.
# Only the SIMPLE method was taken
# The following has been added:
# - add Xdialog
# - suggest MBR 
# - make boot-message.txt ONLY if not exist 
# - change menu-scheme to blue
# - add graphics mode if /boot/boot.bmp exist
# - Fix autodetect bootable DOS partition
# - Fix autodetect root device 
# - Autodetect other Linux partitions
# - Add menu to add partitions
# - Can include initrd
# - Always run from root directory !
# - Detects ide-scsi for APPEND parameters
# - Detect multiple vmlinuz
# - Can use /boot/lilo.label in other partition
# 
# By Eko M. Budi, 2005
# License: GNU GPL
#
# Several fixes and spell checking by uelsk8s and Joe1962 for SOHO 5.1
#
#


vdir=$(dirname $0)
. $vdir/vasm-functions

check_root


menu()
{
$DCMD --backtitle "$BACKTITLE" --title "LILO INSTALL" --menu "\n
LILO (Linux Loader) allows you to boot various operating systems on
multiple partitions.\n
Choose this if you want to install lilo\n
MS-SYS This is a Linux program for writing Microsoft compatible boot records.\n
Choose this if you still have GRUB in your MBR after a lilo install
Which option would you like?" \
0 0 4 \
"LILO" "install LILO" \
"MS-SYS" "rewrite your MBR" \
"SKIP" "EXIT" \
2> $freply

 result=$?
 [ $result != 0 ] && return $result

reply="`cat $freply`"
case "$reply" in
  LILO)
   vliloconf
  ;;
 MS-SYS)
   vfixmbr
  ;;
 *)
  clean_exit
  ;;
esac 
return 0
}

############################
# MAIN MENU
wizard menu


