filter kname so - and . work
authorEric Edgar <rocket@gentoo.org>
Tue, 10 Jan 2006 15:42:01 +0000 (15:42 +0000)
committerEric Edgar <rocket@gentoo.org>
Tue, 10 Jan 2006 15:42:01 +0000 (15:42 +0000)
git-svn-id: svn+ssh://svn.gentoo.org/var/svnroot/catalyst/trunk@1013 d1e1f19c-881f-0410-ab34-b69fee027534

modules/generic_stage_target.py
targets/support/kmerge.sh

index 9662ef187f2fc7cea8950f59e26d53b82b39fc40..873d71d88f3980f220bf94a7566723e08606bccb 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.112 2006/01/05 19:23:07 rocket Exp $
+# $Header: /var/cvsroot/gentoo/src/catalyst/modules/generic_stage_target.py,v 1.113 2006/01/10 15:42:01 rocket Exp $
 
 """
 This class does all of the chroot setup, copying of files, etc. It is
@@ -994,9 +994,10 @@ class generic_stage_target(generic_target):
                # modify the current environment. This is an ugly hack that should be fixed. We need this
                # to use the os.system() call since we can't specify our own environ:
                for x in self.settings.keys():
-                       # "/" is replaced with "_", "-" is also replaced with "_"
+                       # "/" is replaced with "_", "-" is also replaced with "_", "." is also replace with "_"
                        varname="clst_"+string.replace(x,"/","_")
                        varname=string.replace(varname,"-","_")
+                       varname=string.replace(varname,".","_")
                        if type(self.settings[x])==types.StringType:
                                # prefix to prevent namespace clashes:
                                #os.environ[varname]=self.settings[x]
index 38c2b5bfc2e129855046a0673b77ef0f7b114f25..ee35b6826c13ed3080d01bc9889411fc7a83b4ca 100755 (executable)
@@ -51,8 +51,8 @@ setup_gk_args() {
 }
 
 genkernel_compile(){
-       eval "clst_initramfs_overlay=\$clst_boot_kernel_${clst_kname}_initramfs_overlay"
-       eval "clst_kernel_merge=\$clst_boot_kernel_${clst_kname}_packages"
+       eval "clst_initramfs_overlay=\$clst_boot_kernel_${filtered_kname}_initramfs_overlay"
+       eval "clst_kernel_merge=\$clst_boot_kernel_${filtered_kname}_packages"
 
        setup_gk_args
        #echo "The GK_ARGS are"
@@ -105,11 +105,16 @@ export CONFIG_PROTECT="-*"
 rm /etc/localtime
 ln -s /usr/share/zoneinfo/UTC /etc/localtime
 
-eval "clst_kernel_use=\$clst_boot_kernel_${clst_kname}_use"
+
+filtered_kname=${clst_kname/-/_}
+filtered_kname=${clst_kname/\//_}
+filtered_kname=${filtered_kname/\./_}
+
+eval "clst_kernel_use=\$clst_boot_kernel_${filtered_kname}_use"
 export USE=$clst_kernel_use
 
-eval "clst_kernel_gk_kernargs=\$clst_boot_kernel_${clst_kname}_gk_kernargs"
-eval "clst_ksource=\$clst_boot_kernel_${clst_kname}_sources"
+eval "clst_kernel_gk_kernargs=\$clst_boot_kernel_${filtered_kname}_gk_kernargs"
+eval "clst_ksource=\$clst_boot_kernel_${filtered_kname}_sources"
 
 # Don't use pkgcache here, as the kernel source may get emerged with different
 # USE variables (and thus different patches enabled/disabled.) Also, there's no