|
From: <cod...@go...> - 2008-07-31 17:53:56
|
Author: M0...@gm...
Date: Fri Jul 25 09:11:00 2008
New Revision: 77
Modified:
branches/iVL/.lang/MdlSetup.pot
branches/iVL/FrmInstallSys.class
branches/iVL/MdlInstallSys.module
branches/iVL/MdlPartFrmt.module
branches/iVL/MdlPartSel.module
branches/iVL/MdlSetup.module
branches/iVL/Order
Log:
Disabled selecting the partition that hosts the ISO. this is for
security. more work on the package install function.
Modified: branches/iVL/.lang/MdlSetup.pot
==============================================================================
--- branches/iVL/.lang/MdlSetup.pot (original)
+++ branches/iVL/.lang/MdlSetup.pot Fri Jul 25 09:11:00 2008
@@ -1,4 +1,4 @@
-# /root/gui-installer/MdlSetup.module
+# /home/moises/area-51/projects/installer/MdlSetup.module
# Generated by Gambas compiler
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
Modified: branches/iVL/FrmInstallSys.class
==============================================================================
--- branches/iVL/FrmInstallSys.class (original)
+++ branches/iVL/FrmInstallSys.class Fri Jul 25 09:11:00 2008
@@ -35,8 +35,9 @@
PUBLIC SUB Form_Open()
' prepare the system
- ME.FrmProg.Text = " Preparing system for installation "
+ ME.FrmProg.Text = " Preparing system for installation "
+ ME.tlCurrStepLbl.Text = "Current Step"
ME.HIDE_PROGRES_CONTROLS()
@@ -84,14 +85,5 @@
END
-PUBLIC SUB SHOW_PROGRESS_CONTROLS()
-
- WITH ME
- .tlCurrStepLbl.Visible = TRUE
- .pbInstallProg.Visible = TRUE
- .tlCurrPkg2.Visible = TRUE
- .pbInstallProg2.Visible = TRUE
- END WITH
-
-END
+
Modified: branches/iVL/MdlInstallSys.module
==============================================================================
--- branches/iVL/MdlInstallSys.module (original)
+++ branches/iVL/MdlInstallSys.module Fri Jul 25 09:11:00 2008
@@ -66,6 +66,8 @@
'WRITE THE NEW FSTAB NOW, RIGHT BEFORE INSTALLING PACKAGES.
ME.WRITE_NEW_FSTAB() ' do this from the install form
+ 'redirect to packages install
+ 'ME.INSTALL_PACKAGES()
@@ -190,6 +192,8 @@
' perform custom install
ELSE
ME.PERFORM_FULL_INSTALL()
+ 're-direct to packages for now
+ 'ME.INSTALL_PACKAGES()
END IF
END
@@ -249,12 +253,13 @@
.Resize(FMain.pnlWinHost.Width, FMain.pnlWinHost.Height)
END WITH
-
+ MdlSetup.SHOW_PROGRESS_CONTROLS()
ClsGlobal.sTargetMnt = "/mnt/target"
sFile = Split(File.Load(Temp$("SETUP.CONF")), "\n")
FOR i = 0 TO sFile.count - 1
sLine = Trim(sFile[i])
+
IF Left(sLine, Len("BULK") + 1) LIKE "BULK" & "*[0-9]*" THEN
'sLine = Right(sLine, Len(sLine) - InStr(sLine, "\'"))
'sLine = Left(sLine, Len(sLine) - 1)
@@ -264,13 +269,13 @@
sPakPath = sEntry[0]
sPakSize = sEntry[1]
sPakDesc = sEntry[2]
- 'PRINT sBasePath &/ sPakPath & " = " & sPakDesc & "
size= " & CStr(sPakSize)
+ 'PRINT sBasePath &/ sPakPath & " = " & sPakDesc & "
size= " & CStr(sPakSize)
' figure out the sizing and the progrss meter
SHELL "export gsize=$(df| grep " &
ClsPartSel.sRoot & " ) && echo $gsize | cut -f3 -d \' \'" TO sTargetSize
'Message(CStr(sTargetSize))
sTargetSize = Trim(CStr(sTargetSize))
sPakSize = Trim(CStr(sPakSize))
-' iTotalSize = CFloat(CInt(sTargetSize) + CInt(sPakSize))
+'
'RETURN
FrmInstallSys.tlCurrPkg.Text = "Installing " &
sPakDesc & " ..."
@@ -332,38 +337,25 @@
END
-
-
-
-
-
-PUBLIC FUNCTION INSTALL_BULK_PACKAGES() AS Integer
- DIM sPkg AS String
- DIM sShell AS String
- DIM hBulkInst AS Process
- DIM sExt AS String
- DIM sCMD AS String
-
- ClsGlobal.sTargetMnt = "/mnt/target"
-
- PRINT "Installing bulk packages ... "
- FOR EACH sPkg IN RDir(ClsGlobal.sSourceMnt &/ "veclinux" &/ "required")
- sExt = Trim(File.Ext(ClsGlobal.sSourceMnt &/ "veclinux"
&/ "required" &/ sPkg))
- SELECT CASE sExt
- CASE "tlz", "lzm", "lzma"
- sCMD = "lzmadec <" & ClsGlobal.sSourceMnt &/ "veclinux"
&/ "required" &/ sPkg & " | tar -xp -C " & ClsGlobal.sTargetMnt
- END SELECT
- PRINT "Installing " & sPkg
- hBulkInst = SHELL sCMD WAIT
-
- NEXT
+PUBLIC SUB UPDATE_STEP_PROGRESS(iCurrSize AS Float, iProjectedSize AS Float)
+ DIM iMBProgress AS Float
+ DIM ipct AS Float
+ DIM iMinpct AS Float = ".01"
+ DIM iMaxpct AS Float = ".99"
+ DIM iVal AS Float
+ DIM iProgress AS Float
+ DIM sPakSize AS Variant
+ DIM sTargetSize AS Variant
+ DIM iTotalSize AS Integer
+ 'DIM iCurrSize AS Variant
END
+
PUBLIC FUNCTION INSTALL_PACKAGES() AS Integer
DIM i AS Integer
@@ -384,19 +376,24 @@
sTlzName = Trim(Right(sLine, Len(sLine) - InStr(sLine, ":")))
sTlzPath = Trim(Right(sFile[i + 1], Len(sFile[i + 1]) -
InStr(sFile[i + 1], ":")))
sTlzPath = Right(sTlzPath, Len(sTlzPath) - 2) ' remove
the ./ from the location line
- END IF
+ PRINT " Install " & sTlzBasePath &/ sTlzPath &/ sTlzName
+ ' install each package
+
+
' now install the package with the information we already have
- sDump = ""
- sErr = ""
- hproc = SHELL "install-pkg " & sTlzBasePath &/ sTlzPath
&/ sTlzName & Space(1) & ClsGlobal.sTargetMnt & " || echo \'FAILED\'"
FOR READ
- WAIT 1
- IF hproc.State = Process.Running THEN
- REPEAT
- WAIT 2
- ' figure out the progress again
- UNTIL
- hproc.State = Process.Stopped
- END IF
+
+ ' sDump = ""
+ ' sErr = ""
+ ' hproc = SHELL "install-pkg " & sTlzBasePath &/
sTlzPath &/ sTlzName & Space(1) & ClsGlobal.sTargetMnt & " || echo
\'FAILED\'" FOR READ
+ ' WAIT 1
+ ' IF hproc.State = Process.Running THEN
+ ' REPEAT
+ ' WAIT 2
+ ' ' figure out the progress again
+ ' UNTIL
+ ' hproc.State = Process.Stopped
+ ' END IF
+ END IF
NEXT
Modified: branches/iVL/MdlPartFrmt.module
==============================================================================
--- branches/iVL/MdlPartFrmt.module (original)
+++ branches/iVL/MdlPartFrmt.module Fri Jul 25 09:11:00 2008
@@ -79,6 +79,7 @@
MdlInstallSys.MOUNT_DEFINED_PARTITIONS() ' let the game begin
END IF
+ 'MdlInstallSys.MOUNT_DEFINED_PARTITIONS
END
Modified: branches/iVL/MdlPartSel.module
==============================================================================
--- branches/iVL/MdlPartSel.module (original)
+++ branches/iVL/MdlPartSel.module Fri Jul 25 09:11:00 2008
@@ -136,6 +136,11 @@
.Add("/usr")
.Add("/var")
.Add("/tmp")
+ IF InStr(FrmSelISO.lstInstallableImg.Text, .tag) THEN
+ .Enabled = FALSE
+ ELSE
+ .Enabled = TRUE
+ END IF
END WITH
oMountPoints.Add(cb)
i3drdrowX = cb.x + cb.Width + 8
Modified: branches/iVL/MdlSetup.module
==============================================================================
--- branches/iVL/MdlSetup.module (original)
+++ branches/iVL/MdlSetup.module Fri Jul 25 09:11:00 2008
@@ -134,6 +134,17 @@
+PUBLIC SUB SHOW_PROGRESS_CONTROLS()
+
+ WITH FrmInstallSys
+ .tlCurrStepLbl.Visible = TRUE
+ .pbInstallProg.Visible = TRUE
+ .tlCurrPkg2.Visible = TRUE
+ .pbInstallProg2.Visible = TRUE
+ END WITH
+
+END
+
Modified: branches/iVL/Order
==============================================================================
--- branches/iVL/Order (original)
+++ branches/iVL/Order Fri Jul 25 09:11:00 2008
@@ -7,4 +7,10 @@
(09:56:13 AM) uelsk8s: they have to be installed or the install will break
-(07:38:13 AM) uelsk8s: for i in $(ls packages/*/*.tlz|grep -v
required);do install-pkg $i $ROOT || echo FAILED;done
\ No newline at end of file
+(07:38:13 AM) uelsk8s: for i in $(ls packages/*/*.tlz|grep -v
required);do install-pkg $i $ROOT || echo FAILED;done
+
+TODO:
+ + Add option to format partition to swap
+ + Modify partition listing so that it hides (or disables) selecting
the partition which hosts the ISO to be used for the new install
+ + Add option to mount (but not format) linux partitions. (add
/mnt/<partition_addr> to the combobox list)
+
\ No newline at end of file
|