|
From: <cod...@go...> - 2008-11-14 21:41:40
|
Author: M0...@gm...
Date: Fri Nov 14 13:31:48 2008
New Revision: 295
Modified:
branches/iVL/.lang/#project.pot
branches/iVL/.lang/ClsGlobal.pot
branches/iVL/.lang/ClsPartSel.pot
branches/iVL/.lang/ClsWinDrives.pot
branches/iVL/.lang/FMain.pot
branches/iVL/.lang/FrmDiskPart.pot
branches/iVL/.lang/FrmPartScheme.pot
branches/iVL/.lang/FrmPartSel.pot
branches/iVL/.lang/FrmPkgSel.pot
branches/iVL/.lang/FrmSelISO.pot
branches/iVL/.lang/FrmSummary.pot
branches/iVL/.lang/FrmWinDrives.pot
branches/iVL/.lang/MdlCore.pot
branches/iVL/.lang/MdlDiskPart.pot
branches/iVL/.lang/MdlObjSizer.pot
branches/iVL/.lang/MdlPartSel.pot
branches/iVL/.lang/MdlPkgSel.pot
branches/iVL/.lang/MdlSetup.pot
branches/iVL/.lang/MdlSummarize.pot
branches/iVL/.lang/MdlWinDrives.pot
branches/iVL/.project
branches/iVL/FMain.class
branches/iVL/FrmLiloSetup.class
branches/iVL/FrmLiloSetup.form
branches/iVL/MdlConfLilo.module
branches/iVL/MdlLilo.module
branches/iVL/installer.gambas
Log:
Completed coding section for LiloSetup stup. Ready for testing
Updated Binary
Modified: branches/iVL/.lang/#project.pot
==============================================================================
--- branches/iVL/.lang/#project.pot (original)
+++ branches/iVL/.lang/#project.pot Fri Nov 14 13:31:48 2008
@@ -1,4 +1,4 @@
-# /home/vluser/devel/installer/.project
+# /home/moe/projects/installer/.project
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
Modified: branches/iVL/.lang/ClsGlobal.pot
==============================================================================
--- branches/iVL/.lang/ClsGlobal.pot (original)
+++ branches/iVL/.lang/ClsGlobal.pot Fri Nov 14 13:31:48 2008
@@ -1,4 +1,4 @@
-# /home/vluser/devel/installer/ClsGlobal.class
+# /home/moe/projects/installer/ClsGlobal.class
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
Modified: branches/iVL/.lang/ClsPartSel.pot
==============================================================================
--- branches/iVL/.lang/ClsPartSel.pot (original)
+++ branches/iVL/.lang/ClsPartSel.pot Fri Nov 14 13:31:48 2008
@@ -1,4 +1,4 @@
-# /root/gui-installer2/ClsPartSel.class
+# /home/moe/projects/installer/ClsPartSel.class
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
Modified: branches/iVL/.lang/ClsWinDrives.pot
==============================================================================
--- branches/iVL/.lang/ClsWinDrives.pot (original)
+++ branches/iVL/.lang/ClsWinDrives.pot Fri Nov 14 13:31:48 2008
@@ -1,4 +1,4 @@
-# /root/gui-installer2/ClsWinDrives.class
+# /home/moe/projects/installer/ClsWinDrives.class
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
Modified: branches/iVL/.lang/FMain.pot
==============================================================================
--- branches/iVL/.lang/FMain.pot (original)
+++ branches/iVL/.lang/FMain.pot Fri Nov 14 13:31:48 2008
@@ -1,4 +1,4 @@
-# /root/gui-installer2/FMain.class
+# /home/moe/projects/installer/FMain.class
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
@@ -34,71 +34,75 @@
msgid "You must select a \"/\" partition. This is the target where the
system will install to"
msgstr ""
-#: FMain.class:313
+#: FMain.class:311
msgid "Please select a default operating system to boot before proceeding"
msgstr ""
-#: FMain.class:314
+#: FMain.class:312
msgid "Select an entry from this list"
msgstr ""
-#: FMain.class:325
+#: FMain.class:319
+msgid "Skipping boot loaded setup"
+msgstr ""
+
+#: FMain.class:342
msgid "Skipping lilo setup"
msgstr ""
-#: FMain.class:339
+#: FMain.class:356
msgid "Passwords do not match. Please enter the same password twice"
msgstr ""
-#: FMain.class:354
+#: FMain.class:371
msgid "You have not created any user accounts for this system yet. There
is not enough information"
msgstr ""
-#: FMain.class:354
+#: FMain.class:371
msgid "to create an account here. It is recommended that you create at
least one."
msgstr ""
-#: FMain.class:354
+#: FMain.class:371
msgid "Would you like to continue anyway?"
msgstr ""
-#: FMain.class:354
+#: FMain.class:371
msgid "Yes"
msgstr ""
-#: FMain.class:354
+#: FMain.class:371
msgid "No"
msgstr ""
-#: FMain.class:372
+#: FMain.class:389
msgid "Please specify a hostname for this computer"
msgstr ""
-#: FMain.class:376
+#: FMain.class:393
msgid "Please specify the domain this computer belongs to"
msgstr ""
-#: FMain.class:389
+#: FMain.class:406
msgid "VectorLinux will now try to detect and configure your graphics
hardware."
msgstr ""
-#: FMain.class:389
+#: FMain.class:406
msgid "Your screen may flicker or go blank for a few seconds during this
process."
msgstr ""
-#: FMain.class:641
+#: FMain.class:658
msgid "Back"
msgstr ""
-#: FMain.class:653
+#: FMain.class:670
msgid "Exit Installation"
msgstr ""
-#: FMain.class:665
+#: FMain.class:682
msgid "Next"
msgstr ""
-#: FMain.class:679
+#: FMain.class:696
msgid "Button1"
msgstr ""
Modified: branches/iVL/.lang/FrmDiskPart.pot
==============================================================================
--- branches/iVL/.lang/FrmDiskPart.pot (original)
+++ branches/iVL/.lang/FrmDiskPart.pot Fri Nov 14 13:31:48 2008
@@ -1,4 +1,4 @@
-# /root/gui-installer2/FrmDiskPart.class
+# /home/moe/projects/installer/FrmDiskPart.class
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
Modified: branches/iVL/.lang/FrmPartScheme.pot
==============================================================================
--- branches/iVL/.lang/FrmPartScheme.pot (original)
+++ branches/iVL/.lang/FrmPartScheme.pot Fri Nov 14 13:31:48 2008
@@ -1,4 +1,4 @@
-# /root/gui-installer2/FrmPartScheme.class
+# /home/moe/projects/installer/FrmPartScheme.class
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
Modified: branches/iVL/.lang/FrmPartSel.pot
==============================================================================
--- branches/iVL/.lang/FrmPartSel.pot (original)
+++ branches/iVL/.lang/FrmPartSel.pot Fri Nov 14 13:31:48 2008
@@ -1,4 +1,4 @@
-# /root/gui-installer2/FrmPartSel.class
+# /home/moe/projects/installer/FrmPartSel.class
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
Modified: branches/iVL/.lang/FrmPkgSel.pot
==============================================================================
--- branches/iVL/.lang/FrmPkgSel.pot (original)
+++ branches/iVL/.lang/FrmPkgSel.pot Fri Nov 14 13:31:48 2008
@@ -1,4 +1,4 @@
-# /root/gui-installer2/FrmPkgSel.class
+# /home/moe/projects/installer/FrmPkgSel.class
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
Modified: branches/iVL/.lang/FrmSelISO.pot
==============================================================================
--- branches/iVL/.lang/FrmSelISO.pot (original)
+++ branches/iVL/.lang/FrmSelISO.pot Fri Nov 14 13:31:48 2008
@@ -1,4 +1,4 @@
-# /root/gui-installer2/FrmSelISO.class
+# /home/moe/projects/installer/FrmSelISO.class
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
Modified: branches/iVL/.lang/FrmSummary.pot
==============================================================================
--- branches/iVL/.lang/FrmSummary.pot (original)
+++ branches/iVL/.lang/FrmSummary.pot Fri Nov 14 13:31:48 2008
@@ -1,4 +1,4 @@
-# /root/gui-installer2/FrmSummary.class
+# /home/moe/projects/installer/FrmSummary.class
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
Modified: branches/iVL/.lang/FrmWinDrives.pot
==============================================================================
--- branches/iVL/.lang/FrmWinDrives.pot (original)
+++ branches/iVL/.lang/FrmWinDrives.pot Fri Nov 14 13:31:48 2008
@@ -1,4 +1,4 @@
-# /root/gui-installer2/FrmWinDrives.class
+# /home/moe/projects/installer/FrmWinDrives.class
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
Modified: branches/iVL/.lang/MdlCore.pot
==============================================================================
--- branches/iVL/.lang/MdlCore.pot (original)
+++ branches/iVL/.lang/MdlCore.pot Fri Nov 14 13:31:48 2008
@@ -1,4 +1,4 @@
-# /root/gui-installer2/MdlCore.module
+# /home/moe/projects/installer/MdlCore.module
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
Modified: branches/iVL/.lang/MdlDiskPart.pot
==============================================================================
--- branches/iVL/.lang/MdlDiskPart.pot (original)
+++ branches/iVL/.lang/MdlDiskPart.pot Fri Nov 14 13:31:48 2008
@@ -1,4 +1,4 @@
-# /root/gui-installer2/MdlDiskPart.module
+# /home/moe/projects/installer/MdlDiskPart.module
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
Modified: branches/iVL/.lang/MdlObjSizer.pot
==============================================================================
--- branches/iVL/.lang/MdlObjSizer.pot (original)
+++ branches/iVL/.lang/MdlObjSizer.pot Fri Nov 14 13:31:48 2008
@@ -1,4 +1,4 @@
-# /root/gui-installer2/MdlObjSizer.module
+# /home/moe/projects/installer/MdlObjSizer.module
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
Modified: branches/iVL/.lang/MdlPartSel.pot
==============================================================================
--- branches/iVL/.lang/MdlPartSel.pot (original)
+++ branches/iVL/.lang/MdlPartSel.pot Fri Nov 14 13:31:48 2008
@@ -1,4 +1,4 @@
-# /root/gui-installer2/MdlPartSel.module
+# /home/moe/projects/installer/MdlPartSel.module
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
Modified: branches/iVL/.lang/MdlPkgSel.pot
==============================================================================
--- branches/iVL/.lang/MdlPkgSel.pot (original)
+++ branches/iVL/.lang/MdlPkgSel.pot Fri Nov 14 13:31:48 2008
@@ -1,4 +1,4 @@
-# /root/gui-installer2/MdlPkgSel.module
+# /home/moe/projects/installer/MdlPkgSel.module
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
Modified: branches/iVL/.lang/MdlSetup.pot
==============================================================================
--- branches/iVL/.lang/MdlSetup.pot (original)
+++ branches/iVL/.lang/MdlSetup.pot Fri Nov 14 13:31:48 2008
@@ -1,4 +1,4 @@
-# /home/vluser/devel/installer/MdlSetup.module
+# /home/moe/projects/installer/MdlSetup.module
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
Modified: branches/iVL/.lang/MdlSummarize.pot
==============================================================================
--- branches/iVL/.lang/MdlSummarize.pot (original)
+++ branches/iVL/.lang/MdlSummarize.pot Fri Nov 14 13:31:48 2008
@@ -1,4 +1,4 @@
-# /root/gui-installer2/MdlSummarize.module
+# /home/moe/projects/installer/MdlSummarize.module
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
Modified: branches/iVL/.lang/MdlWinDrives.pot
==============================================================================
--- branches/iVL/.lang/MdlWinDrives.pot (original)
+++ branches/iVL/.lang/MdlWinDrives.pot Fri Nov 14 13:31:48 2008
@@ -1,4 +1,4 @@
-# /root/gui-installer2/MdlWinDrives.module
+# /home/moe/projects/installer/MdlWinDrives.module
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
Modified: branches/iVL/.project
==============================================================================
--- branches/iVL/.project (original)
+++ branches/iVL/.project Fri Nov 14 13:31:48 2008
@@ -1,8 +1,8 @@
# Gambas Project File 2.0
# Compiled with Gambas 2.9.0
Title=VectorLinux Installer
-Startup=FrmLiloSetup
-Version=0.0.162
+Startup=MdlCore
+Version=0.0.165
Library=gb.gtk
Library=gb.form
Library=gb.debug
@@ -17,7 +17,6 @@
Language=en_US
ControlPublic=1
ModulePublic=1
-ExecPath=/root/gui-installer2/installer.gambas
Maintainer=M0E-lnx
Vendor=VectorLinux
Add...@gm...
Modified: branches/iVL/FMain.class
==============================================================================
--- branches/iVL/FMain.class (original)
+++ branches/iVL/FMain.class Fri Nov 14 13:31:48 2008
@@ -302,7 +302,24 @@
CASE "FrmInstallSys"
MdlInstallSys.WRITE_NEW_DISTRO_ID()
MdlConfLilo.PERFORM_BINDING()
- frmNext = FrmLilo
+ 'frmNext = FrmLilo
+ frmNext = FrmLiloSetup
+
+ CASE "FrmLiloSetup"
+ IF FrmLiloSetup.cbYNLilo.Value = FALSE THEN
+ IF FrmLiloSetup.cbBootDefault.Text = "" THEN
+ Message.Warning(("Please select a default operating system
to boot before proceeding"))
+ Balloon.Info(("Select an entry from this list"),
FrmLiloSetup.cbBootDefault)
+ STOP EVENT
+ RETURN
+ END IF
+ 'Run the setup
+ MdlLilo.TRIGGER_LILO_SETUP()
+ ELSE
+ FrmLiloSetup.tlBanner.Text = "<b>" & ("Skipping boot loaded setup")
& "</b>"
+ END IF
+ SHELL "mount -o bind /mnt/target/lib /lib && depmod -aq &&
/etc/rc.d/rc.udev restart"
+ frmNext = FrmZoneSet
CASE "FrmLilo"
Modified: branches/iVL/FrmLiloSetup.class
==============================================================================
--- branches/iVL/FrmLiloSetup.class (original)
+++ branches/iVL/FrmLiloSetup.class Fri Nov 14 13:31:48 2008
@@ -19,9 +19,14 @@
PUBLIC SUB Form_Open()
- ' hack just for testing here
- ClsPartSel.sRoot = "/dev/hdb1"
- ClsPartSel.fRoot = "reiserfs"
+
+ '
+ ' ME.tlBanner.Text = "<h3>" & tlBanner.text & "</h3>"
+ ' 'ClsPartSel.sRoot = "/dev/sdb1" '
+ ' FMain.FrmCurr = ME
+ ' FMain.tvPlan["Conf0"].Selected = TRUE
+ ' FMain.tvPlan["Conf0"].Picture = MdlCore.sNowPic
+ ' FMain.tvPlan["Inst1"].Picture = MdlCore.sDonePic
MdlConfLilo.DISPLAY_LILO_TARGET_OPTIONS()
ME.list_video_modes()
@@ -91,3 +96,30 @@
END WITH
END
+
+PUBLIC SUB cbVideoRes_Click()
+
+ DIM tb AS TextBox
+ DIM sText AS String
+
+ IF NOT MdlLilo.arrLinuxAppendtxtBoxes THEN RETURN
+ SELECT CASE Trim(cbVideoRes.text)
+ CASE (("Standard"))
+ FOR EACH tb IN MdlLilo.arrLinuxAppendtxtBoxes
+ tb.Text = Replace(tb.Text, "splash=silent", "") ' Not
available on this mode
+ NEXT
+ CASE ELSE
+ FOR EACH tb IN MdlLilo.arrLinuxAppendtxtBoxes
+ IF InStr(tb.Text, "splash=") = FALSE THEN
+ IF tb.Tag <> "" THEN
+ tb.Text = tb.Text & " splash=silent"
+ ELSE
+ tb.Text = "splash=silent"
+ END IF
+ END IF
+ NEXT
+ END SELECT
+
+
+
+END
Modified: branches/iVL/FrmLiloSetup.form
==============================================================================
--- branches/iVL/FrmLiloSetup.form (original)
+++ branches/iVL/FrmLiloSetup.form Fri Nov 14 13:31:48 2008
@@ -40,8 +40,11 @@
ReadOnly = True
}
}
+ { HBox2 HBox
+ MoveScaled(2,12,82,1)
+ }
{ Panel3 Panel
- MoveScaled(1,12,88,4)
+ MoveScaled(1,13,88,4)
Arrangement = Arrange.Horizontal
{ tlLiloTarget TextLabel
MoveScaled(0,0,7,3)
@@ -69,8 +72,11 @@
ReadOnly = True
}
}
+ { HBox3 HBox
+ MoveScaled(1,17,85,1)
+ }
{ PnlTop Panel
- MoveScaled(1,16,88,3)
+ MoveScaled(1,18,88,3)
Arrangement = Arrange.Horizontal
{ tlTimeOut TextLabel
MoveScaled(0,0,14,3)
@@ -88,14 +94,14 @@
}
}
{ HBox1 HBox
- MoveScaled(1,19,88,2)
+ MoveScaled(1,21,88,2)
{ Separator2 Separator
MoveScaled(0,1,83,1)
Expand = True
}
}
{ tsLIloTabs TabStrip
- MoveScaled(2,23,84,30)
+ MoveScaled(1,26,84,30)
Expand = True
Index = 0
Text = ("Tab 0")
Modified: branches/iVL/MdlConfLilo.module
==============================================================================
--- branches/iVL/MdlConfLilo.module (original)
+++ branches/iVL/MdlConfLilo.module Fri Nov 14 13:31:48 2008
@@ -301,14 +301,20 @@
DIM sOut AS String
-SHELL "mount -o bind /sys " & ClsGlobal.sTargetMnt &/ "sys" WAIT
-SHELL "mount -o bind /proc " & ClsGlobal.sTargetMnt &/ "proc" WAIT
-SHELL "mount -o bind /tmp " & ClsGlobal.sTargetMnt &/ "tmp" WAIT
-SHELL "mount -o bind /dev " & ClsGlobal.sTargetMnt &/ "dev" WAIT
+' SHELL "mount -o bind /sys " & ClsGlobal.sTargetMnt &/ "sys" WAIT
+EXEC ["mount", "-o", "bind", "/sys", ClsGlobal.sTargetMnt &/ "sys"] WAIT
+' SHELL "mount -o bind /proc " & ClsGlobal.sTargetMnt &/ "proc" WAIT
+EXEC ["mount", "-o", "bind", "/proc", ClsGlobal.sTargetMnt &/ "proc"] WAIT
+' SHELL "mount -o bind /tmp " & ClsGlobal.sTargetMnt &/ "tmp" WAIT
+EXEC ["mount", "-o", "bind", "/tmp", ClsGlobal.sTargetMnt &/ "tmp"] WAIT
+' SHELL "mount -o bind /dev " & ClsGlobal.sTargetMnt &/ "dev" WAIT
+EXEC ["mount", "-o", "bind", "/dev", ClsGlobal.sTargetMnt &/ "dev"] WAIT
'We will run the commands neccisary to setup the newly installed system
here
-SHELL "mkdir -p " & ClsGlobal.sTargetMnt &/ "var/log/setup" WAIT
-SHELL "chmod 700 " & ClsGlobal.sTargetMnt &/ "var/log/setup" WAIT
+EXEC ["mkdir", "-p", ClsGlobal.sTargetMnt &/ "var" &/ "log" &/ "setup"]
WAIT
+'SHELL "mkdir -p " & ClsGlobal.sTargetMnt &/ "var/log/setup" WAIT
+'SHELL "chmod 700 " & ClsGlobal.sTargetMnt &/ "var/log/setup" WAIT
+EXEC ["chmod", "700", ClsGlobal.sTargetMnt &/ "var" &/ "log" &/ "setup"]
WAIT
sOut = "#!/bin/bash \n" &
"DISPLAY=" & gb.NewLine &
"chmod +x /etc/rc.d/rc.udev" & gb.NewLine &
Modified: branches/iVL/MdlLilo.module
==============================================================================
--- branches/iVL/MdlLilo.module (original)
+++ branches/iVL/MdlLilo.module Fri Nov 14 13:31:48 2008
@@ -27,6 +27,60 @@
PRIVATE i AS Integer ' used for object key
+PUBLIC SUB TRIGGER_LILO_SETUP()
+
+ ME.GENERATE_LILO_DOT_CONF ' Generates and write lilo.conf
+ MdlConfLilo.PERFORM_BINDING() ' Performs binding mounts for LILO setup
+ MdlConfLilo.EXECUTE_LILO() ' Execute lilo in chroot mode
+
+
+
+END
+
+PUBLIC FUNCTION GENERATE_LILO_DOT_CONF_VIDEOMODES_SECTION() AS String
+
+ DIM sInput AS String = Trim(FrmLiloSetup.cbVideoRes.Text)
+ DIM sVGA AS String
+ DIM sOutput AS String
+ SELECT CASE sInput
+ CASE (("Standard"))
+ svga = "normal"
+ CASE (("Bootsplash Med"))
+ sVga = "788"
+ CASE (("Bootsplash High"))
+ sVga = "791"
+ CASE (("Bootsplash Extra High"))
+ sVga = "794"
+ END SELECT
+
+sOutput = "# VESA framebuffer console @ 1024x768x64k \n" &
+"vga = " & sVga & "<br>" &
+"# Normal VGA console n" &
+"#vga = normal \n" &
+"#VESA framebuffer console @ 1024 x768x64k \n" &
+"#vga = 791 \n" &
+"#VESA framebuffer console @ 1024 x768x32k \n" &
+"#vga = 790 \n" &
+"#VESA framebuffer console @ 1024 x768x256 \n" &
+"#vga = 773 \n" &
+"#VESA framebuffer console @ 800 x600x64k \n" &
+"#vga = 788 \n" &
+"#VESA framebuffer console @ 800 x600x32k \n" &
+"#vga = 787 \n" &
+"#VESA framebuffer console @ 800 x600x256 \n" &
+"#vga = 771 \n" &
+"#VESA framebuffer console @ 640 x480x64k \n" &
+"#vga = 785 \n" &
+"#VESA framebuffer console @ 640 x480x32k \n" &
+"#vga = 784 \n" &
+"#VESA framebuffer console @ 640 x480x256 \n" &
+"#vga = 769"
+
+RETURN sOutput
+
+END
+
+
PUBLIC FUNCTION generate_lilo_dot_conf_header() AS String
DIM sHeader AS String
@@ -66,7 +120,6 @@
"bitmap = /boot/bitmap/boot.bmp \n"
END IF
sHeader = sHeader & "\n" &
- "vga = 791 \n" &
"# Begin listing OS Choices \n"
@@ -81,11 +134,11 @@
DIM tb AS TextBox
DIM cb, chbox AS CheckBox
-DIM sOsEntries AS String
+ DIM sOsEntries AS String
DIM sSection, sClisection, sWinSection AS String
DIM cbox AS ComboBox
DIM sLabel, sKernel, sInitrd, sAppend, sTag AS String
- DIM sBootPath, sHeader, sFile AS String
+ DIM sBootPath, sHeader, sFile, sVidModeSection AS String
@@ -104,7 +157,7 @@
END IF
NEXT
FOR EACH cbox IN arrCbInitrds
- IF cb.Tag = cbox.Tag THEN sInitrd = Trim(cbox.Text) & "-" &
sLabel
+ IF cb.Tag = cbox.Tag THEN sInitrd = Trim(cbox.Text) & "-" &
Right(cbox.Tag, Len(cbox.Tag) - RInStr(cbox.tag, "/"))
NEXT
FOR EACH tb IN arrLinuxAppendtxtBoxes
IF cb.Tag = tb.Tag THEN sAppend = Trim(tb.Text)
@@ -160,8 +213,19 @@
'END IF
'NEXT
sHeader = ME.generate_lilo_dot_conf_header()
- sFile = sHeader & "<br>" & sOsEntries
+ sVidModeSection = ME.GENERATE_LILO_DOT_CONF_VIDEOMODES_SECTION()
+ sFile = sHeader & "<br>" & sVidModeSection & "<br><br>" & sOsEntries
+ 'Message(sFile)
+
+ ' move files to the right place
+ ME.COPY_KERNELS_AND_INITRDS()
+ IF Exist(ClsGlobal.sTargetMnt &/ "etc" &/ "lilo.conf") THEN
+ TRY MOVE ClsGlobal.sTargetMnt &/ "etc" &/ "lilo.conf" TO
ClsGlobal.sTargetMnt &/ "etc" &/ "lilo.conf.dist"
+ END IF
+
+ File.Save(ClsGlobal.sTargetMnt &/ "etc" &/ "lilo.conf", sFile)
+
' write the file to the target
@@ -169,6 +233,72 @@
+PUBLIC SUB COPY_KERNELS_AND_INITRDS()
+
+ DIM tb AS TextBox
+ DIM cbox AS ComboBox
+ DIM cb AS CheckBox
+ DIM sKernelPath, sPart, sShortpart AS String
+ DIM sKernel, sInitrd, sKernelLoc AS String
+
+
+ ' PREPARE HOST PARTITION
+ 'EXEC ["mount", "/dev/sdb8", "/mnt/target"] WAIT
+ EXEC ["mount", ClsPartSel.sRoot, "/mnt/target"] WAIT
+ 'ClsGlobal.sTargetMnt = "/mnt/target"
+
+ 'ClsPartSel.sRoot = "/dev/sdb8"
+ 'ClsPartSel.fRoot = "reiserfs"
+ ' TRY MKDIR ClsGlobal.sTargetMnt &/ "boot"
+ ' TRY MKDIR ClsGlobal.sTargetMnt &/ "boot" &/ "tamu"
+ ' TRY MKDIR ClsGlobal.sTargetMnt &/ "etc"
+
+
+ FOR EACH cb IN MdlLilo.arrLinuxIncCheckboxes
+ IF cb.Value = TRUE THEN
+ sPart = Right(cb.Tag, Len(cb.Tag) - InStr(cb.Tag, "/") + 1)
+ sShortpart = Right(sPart, Len(sPart) - RInStr(sPart, "/"))
+
+ IF sPart = ClsPartSel.sRoot THEN
+ sKernelPath = "boot"
+ ELSE
+ sKernelPath = "boot/tamu"
+ END IF
+
+ ' get the initrd name
+ FOR EACH cbox IN MdlLilo.arrCbInitrds
+ 'Message(cbox.tag)
+ IF cbox.tag = cb.tag THEN
+ 'Message("Found initrd")
+ sInitrd = Trim(cbox.text)
+ 'IF sInitrd = "" THEN sInitrd = "initrd"
+ END IF
+ NEXT
+ 'for each tb in MdlLilo.arr
+
+ EXEC ["sync"] WAIT
+ EXEC ["mount", sPart, "/tmp/lilo_tmp"] WAIT
+ IF MdlLiloOsList.ID_DISTRO("/tmp/lilo_tmp")
LIKE "vector" THEN
+ sKernelLoc = "/tmp/lilo_tmp/boot"
+ ELSE
+ sKernelLoc = "/tmp/lilo_tmp"
+ END IF
+
+ ' EXEC ["mkdir", "-p", ClsGlobal.sTargetMnt
&/ "boot/tamu"] WAIT
+ EXEC ["cp", sKernelLoc &/ sInitrd,
ClsGlobal.sTargetMnt &/ sKernelPath &/ sInitrd & "-" & sShortpart] WAIT
+ EXEC ["cp", sKernelLoc &/ "vmlinuz",
ClsGlobal.sTargetMnt &/ sKernelPath &/ "vmlinuz-" & sShortpart] WAIT
+
+
+ EXEC ["sync"] WAIT
+ EXEC ["umount", "/tmp/lilo_tmp"] WAIT
+ ' END IF
+ 'NEXT
+ 'END IF
+
+END IF
+NEXT
+EXEC ["umount", "/mnt/target"] WAIT
+END
@@ -199,9 +329,13 @@
sPart = Right(sLinuxpart, Len(sLinuxPart) -
RInStr(sLinuxPart, "/"))
EXEC ["mount", "/dev/" & sPart, "/tmp/lilo_tmp"] WAIT
- IF IsDir("/tmp/lilo_tmp/boot") THEN
+ IF IsDir("/tmp/lilo_tmp/boot") THEN
+ IF sPart = ClsPartSel.sRoot THEN
+ sOsDesc = "VectorLinux"
+ ELSE
'FOR EACH vmlinuz IN
Dir("/tmp/lilo_tmp/boot", "vmlinuz*", gb.File)
sOsDesc =
MdlLiloOsList.ID_DISTRO("/tmp/lilo_tmp")
+ END IF
'Message(sOsDesc)
IF sOsDesc LIKE "vector" THEN
sKernelLoc = "/tmp/lilo_tmp/boot"
@@ -416,7 +550,11 @@
.Width = 200
.MaxLength = 15
.Move(x + tl.Width + 8, y)
- .Text = sDesc & "-" &
Right(sHostPart, Len(sHostPart) - RInStr(sHostPart, "/"))
+ IF sHostPart =
ClsPartSel.sRoot THEN
+ .text = "VectorLinux"
+ ELSE
+ .Text = sDesc & "-" &
Right(sHostPart, Len(sHostPart) - RInStr(sHostPart, "/"))
+ END IF
.Tag = i & sHostPart
END WITH
ME.arrLinuxNametxtboxes.Add(tb)
Modified: branches/iVL/installer.gambas
==============================================================================
Binary files. No diff available.
|