lil livecd fixups
authorDaniel Robbins <drobbins@gentoo.org>
Fri, 9 Jan 2004 22:39:53 +0000 (22:39 +0000)
committerDaniel Robbins <drobbins@gentoo.org>
Fri, 9 Jan 2004 22:39:53 +0000 (22:39 +0000)
git-svn-id: svn+ssh://svn.gentoo.org/var/svnroot/catalyst/trunk@122 d1e1f19c-881f-0410-ab34-b69fee027534

modules/targets.py

index 14dffbd342bc8f3a84490f997816b84eb18f9804..983defd633ebda8c7f90bb31d5a48378b075a9e4 100644 (file)
@@ -426,8 +426,15 @@ class livecd_stage3_target(generic_stage_target):
        def __init__(self,spec,addlargs):
                self.required_values=["boot/kernel","livecd-stage3/runscript"]
                self.valid_values=self.required_values[:]
-               self.valid_values.append("livecd-stage3/cdtar","livecd-stage3/clean")
+               self.valid_values.extend(["livecd-stage3/cdtar","livecd-stage3/clean"])
                generic_stage_target.__init__(self,spec,addlargs)
+               if self.settings.has_key("livecd-stage3/cdtar"):
+                       if not os.path.exists(self.settings["livecd-stage3/cdtar"]):
+                               raise CatalystError, "Cannot locate specified livecd-stage3/cdtar: "+self.settings["livecd-stage3/cdtar"]
+               if not os.path.exists(self.settings["livecd-stage3/runscript"]):
+                               raise CatalystError, "Cannot locate specified livecd-stage3/runscript: "+self.settings["livecd-stage3/runscript"]
+
+
 
        def run_local(self):
                try: