make setting of destdir more global and part of generic_stage_target
authorEric Edgar <rocket@gentoo.org>
Wed, 28 Dec 2005 16:58:43 +0000 (16:58 +0000)
committerEric Edgar <rocket@gentoo.org>
Wed, 28 Dec 2005 16:58:43 +0000 (16:58 +0000)
git-svn-id: svn+ssh://svn.gentoo.org/var/svnroot/catalyst/trunk@1005 d1e1f19c-881f-0410-ab34-b69fee027534

ChangeLog
modules/embedded_target.py
modules/generic_stage_target.py
modules/netboot_target.py
modules/stage1_target.py

index e3db2fe56b9d8a31148938e0e7d9e74cb81af7dd..d4fed578889402dbf840d2b09e79cc65d78e2869 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
 # Copyright 2002-2005 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo/src/catalyst/ChangeLog,v 1.492 2005/12/28 16:36:35 rocket Exp $
+# $Header: /var/cvsroot/gentoo/src/catalyst/ChangeLog,v 1.493 2005/12/28 16:58:43 rocket Exp $
+
+  28 Dec 2005; Eric Edgar <rocket@gentoo.org> modules/embedded_target.py,
+  modules/generic_stage_target.py, modules/netboot_target.py,
+  modules/stage1_target.py:
+  make setting of destdir more global and part of generic_stage_target
 
   28 Dec 2005; Eric Edgar <rocket@gentoo.org> modules/netboot_target.py:
   Fix destpath bug in netboot target
index a088aadf1658a5f5c44ecf857ec2b8e00caaa23c..26c510a3bd74638aee19ed5cbb02a5e0ba31784c 100644 (file)
@@ -1,6 +1,6 @@
 # Copyright 1999-2005 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo/src/catalyst/modules/embedded_target.py,v 1.18 2005/12/02 20:09:03 wolf31o2 Exp $
+# $Header: /var/cvsroot/gentoo/src/catalyst/modules/embedded_target.py,v 1.19 2005/12/28 16:58:43 rocket Exp $
 
 """
 This class works like a 'stage3'.  A stage2 tarball is unpacked, but instead
@@ -46,9 +46,6 @@ class embedded_target(generic_stage_target):
         self.settings["root_path"]=normpath("/tmp/mergeroot")
        print "embedded root path is "+self.settings["root_path"]
 
-    def set_dest_path(self):
-       self.settings["destpath"]=normpath(self.settings["chroot_path"]+self.settings["root_path"])
-               
 def register(foo):
        foo.update({"embedded":embedded_target})
        return foo
index 1d8df6fe00bb44a7bcff107f4a290a0e024667ea..a73827f8423d4be27055cb0d03b7d4653955932f 100644 (file)
@@ -1,6 +1,6 @@
 # Copyright 1999-2005 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo/src/catalyst/modules/generic_stage_target.py,v 1.108 2005/12/28 11:56:17 rocket Exp $
+# $Header: /var/cvsroot/gentoo/src/catalyst/modules/generic_stage_target.py,v 1.109 2005/12/28 16:58:43 rocket Exp $
 
 """
 This class does all of the chroot setup, copying of files, etc. It is
@@ -356,7 +356,10 @@ class generic_stage_target(generic_target):
 
        
        def set_dest_path(self):
-               self.settings["destpath"]=normpath(self.settings["chroot_path"])
+               if self.settings.has_key("root_path"):
+                       self.settings["destpath"]=normpath(self.settings["chroot_path"]+self.settings["root_path"])
+               else:
+                       self.settings["destpath"]=normpath(self.settings["chroot_path"])
 
        def set_cleanables(self):
                self.settings["cleanables"]=["/etc/resolv.conf","/var/tmp/*","/tmp/*","/root/*",\
index f64aadb974ccf20f2633b7141e3ef5829c14c696..e98a66418a26529793eafcf1ba9176ed76817a2a 100644 (file)
@@ -1,6 +1,6 @@
 # Copyright 1999-2005 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo/src/catalyst/modules/netboot_target.py,v 1.11 2005/12/28 16:36:35 rocket Exp $
+# $Header: /var/cvsroot/gentoo/src/catalyst/modules/netboot_target.py,v 1.12 2005/12/28 16:58:43 rocket Exp $
 
 """
 Builder class for a netboot build.
@@ -53,13 +53,10 @@ class netboot_target(generic_stage_target):
                                self.settings[envvar] = "-Os -pipe"
        
 
-#      def set_root_path(self):
-#              # ROOT= variable for emerges
-#              self.settings["root_path"]="/tmp/image"
-
-       def set_dest_path(self):
-               #destpath=self.settings["chroot_path"]+self.settings["root_path"]
-               self.settings["destpath"]=normpath(self.settings["chroot_path"]+"/tmp/image")
+       def set_root_path(self):
+               # ROOT= variable for emerges
+               self.settings["root_path"]=normpath("/tmp/image")
+               print "netboot root path is "+self.settings["root_path"]
 
 #      def build_packages(self):
 #              # build packages
index 000cf1fc7a35cf7ba03ec9607d95abc5ba488066..873daf0e0734a8442f165d2f14fa50ecc71b719f 100644 (file)
@@ -1,6 +1,6 @@
 # Copyright 1999-2005 Gentoo Foundation
 # Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo/src/catalyst/modules/stage1_target.py,v 1.21 2005/12/21 17:18:28 wolf31o2 Exp $
+# $Header: /var/cvsroot/gentoo/src/catalyst/modules/stage1_target.py,v 1.22 2005/12/28 16:58:43 rocket Exp $
 
 """
 Builder class for a stage1 installation tarball build.
@@ -18,12 +18,12 @@ class stage1_target(generic_stage_target):
        def set_stage_path(self):
                self.settings["stage_path"]=normpath(self.settings["chroot_path"]+self.settings["root_path"])
                print "stage1 stage path is "+self.settings["stage_path"]
+       
        def set_root_path(self):
               # ROOT= variable for emerges
                self.settings["root_path"]=normpath("/tmp/stage1root")
                print "stage1 root path is "+self.settings["root_path"]
-       def set_dest_path(self):
-                self.settings["destpath"]=normpath(self.settings["chroot_path"]+self.settings["root_path"])
+       
        def set_cleanables(self):
                generic_stage_target.set_cleanables(self)
                self.settings["cleanables"].extend(["/usr/share/gettext",\
@@ -59,14 +59,14 @@ class stage1_target(generic_stage_target):
             if self.settings.has_key("ldflags"):
                 self.settings["LDFLAGS"]=list_to_string(self.settings["ldflags"])
 
+               def set_portage_overlay(self):
+                       generic_stage_target.set_portage_overlay(self)
+                       if self.settings.has_key("portage_overlay"):
+                               print "\nWARNING !!!!!"
+                               print "\tUsing an portage overlay for earlier stages could cause build issues."
+                               print "\tIf you break it, you buy it. Don't complain to us about it."
+                               print "\tDont say we did not warn you\n"
 
-       def set_portage_overlay(self):
-               generic_stage_target.set_portage_overlay(self)
-               if self.settings.has_key("portage_overlay"):
-                       print "\nWARNING !!!!!"
-                       print "\tUsing an portage overlay for earlier stages could cause build issues."
-                       print "\tIf you break it, you buy it. Don't complain to us about it."
-                       print "\tDont say we did not warn you\n"
 def register(foo):
        foo.update({"stage1":stage1_target})
        return foo