Magellan Linux

Diff of /trunk/installer-simple/bin/installer.sh.in

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2474 by niro, Wed Jan 8 08:55:40 2014 UTC revision 2476 by niro, Wed Jan 8 09:15:14 2014 UTC
# Line 110  dialog_warning() Line 110  dialog_warning()
110   fi   fi
111  }  }
112    
113  dialog_setup_system_menu()  task_setup_system_menu()
114  {  {
115   local mode   local mode
116   local retval   local retval
117    
118   mode=$(menubox -h $"[ Harddrive partitioning ]" $"\nSelect an installation mode" \   mode="$(dialog_setup_system_menu)"
  $"1:Automatic setup (recommended)" \  
  ":" \  
  $":\Z1Expert modes:\Zn" \  
  $"2:Common IDE-disk (manual setup)")  
119   retval=$?   retval=$?
120   [[ ${retval} -eq 1 ]] && return 1   [[ ${retval} -eq 1 ]] && return 1
121   if [[ ${retval} -eq 0 ]]   if [[ ${retval} -eq 0 ]]
# Line 127  dialog_setup_system_menu() Line 123  dialog_setup_system_menu()
123   case "${mode}" in   case "${mode}" in
124   "1") run_install_auto ;;   "1") run_install_auto ;;
125   "2") run_install_normal ;;   "2") run_install_normal ;;
126   "") dialog_setup_system_menu;;   "") task_setup_system_menu;;
127   esac   esac
128   fi   fi
129  }  }
# Line 249  dialog_main() Line 245  dialog_main()
245   if [[ ${retval} -eq 0 ]]   if [[ ${retval} -eq 0 ]]
246   then   then
247   case ${method} in   case ${method} in
248   "1") dialog_setup_system_menu ;;   "1") task_setup_system_menu ;;
249   "2") dialog_hardware_detection ;;   "2") dialog_hardware_detection ;;
250   "3") install_do_reboot ;;   "3") install_do_reboot ;;
251   "4") /bin/bash --login -i ;;   "4") /bin/bash --login -i ;;
# Line 334  run_hardware_detection_disks() Line 330  run_hardware_detection_disks()
330   export ALL_CDROMS="$(get_hwinfo cdrom)"   export ALL_CDROMS="$(get_hwinfo cdrom)"
331  }  }
332    
 hdd_size_below_256mb()  
 {  
  local hdd="$1"  
  local size  
  local retval  
  [[ -z ${hdd} ]] && dialog_die "Error: get_hdd_size() no \$hdd given!"  
   
  size=$(fdisk -l ${hdd} | grep "Disk.*${hdd}" | sed 's:.*,\ \(.*\)\ byte.*:\1:')  
  if [[ ${size} -le 257000000 ]]  
  then  
  retval="0"  
  else  
  retval="1"  
  fi  
   
  return "${retval}"  
 }  
   
333  setup_hdd_partitions_auto()  setup_hdd_partitions_auto()
334  {  {
335   ROOTHDD="${HDD}1"   ROOTHDD="${HDD}1"

Legend:
Removed from v.2474  
changed lines
  Added in v.2476