summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGunnar Wrobel <wrobel@gentoo.org>2005-10-13 17:52:47 +0000
committerGunnar Wrobel <wrobel@gentoo.org>2005-10-13 17:52:47 +0000
commitdaed997e311496d11c083db73d292206a92c1545 (patch)
tree67fdf3271040218892591e47de861c6f5c74b2af
parentkernel recompile not yet fully functional (diff)
downloadmisc-daed997e311496d11c083db73d292206a92c1545.tar.gz
misc-daed997e311496d11c083db73d292206a92c1545.tar.bz2
misc-daed997e311496d11c083db73d292206a92c1545.zip
Minor fixes on the kernel recompile script
svn path=/local/; revision=443
-rwxr-xr-xz-distfiles/scripts-gw/kernel-recompile11
1 files changed, 4 insertions, 7 deletions
diff --git a/z-distfiles/scripts-gw/kernel-recompile b/z-distfiles/scripts-gw/kernel-recompile
index da1221f..fe457b6 100755
--- a/z-distfiles/scripts-gw/kernel-recompile
+++ b/z-distfiles/scripts-gw/kernel-recompile
@@ -58,11 +58,13 @@ os.chdir(boot_d)
if os.path.exists(norm_kernel):
norm_kernel_d = os.path.basename(os.path.realpath(norm_kernel))
+ os.unlink(norm_kernel)
else:
norm_kernel_d = 'kernel-unknown'
if os.path.exists(norm_sysmap):
norm_sysmap_d = os.path.basename(os.path.realpath(norm_sysmap))
+ os.unlink(norm_sysmap)
else:
norm_sysmap_d = 'System.map-unknown'
@@ -88,11 +90,6 @@ else:
if os.path.exists(norm_sysmap_d):
os.unlink(norm_sysmap_d)
-if os.path.exists(norm_kernel):
- os.unlink(norm_kernel)
-if os.path.exists(norm_kernel):
- os.unlink(norm_sysmap)
-
new_kernel_d = norm_kernel + '-' + suffix
new_sysmap_d = norm_sysmap + '-' + suffix
@@ -101,8 +98,8 @@ if options.suffix:
new_sysmap_d = new_sysmap_d + '-' + options.suffix
if norm_kernel_d == new_kernel_d:
- new_kernel_d = new_kernel_d + time.strftime('%Y%m%d')
- new_sysmap_d = new_sysmap_d + time.strftime('%Y%m%d')
+ new_kernel_d = new_kernel_d + '-' + time.strftime('%Y%m%d')
+ new_sysmap_d = new_sysmap_d + '-' + time.strftime('%Y%m%d')
shutil.copyfile(src_d + '/arch/i386/boot/bzImage', new_kernel_d)
shutil.copyfile(src_d + '/System.map', new_sysmap_d)