scripts/build-kernel: remove the vmlinuz symlink if it exists before (re)creating
This commit is contained in:
parent
e0f3835e72
commit
d40976c08c
|
@ -90,6 +90,8 @@ def install_kernel():
|
||||||
# exists). I still do this however.
|
# exists). I still do this however.
|
||||||
for filename in os.listdir('/boot'):
|
for filename in os.listdir('/boot'):
|
||||||
if filename.startswith('vmlinuz-'):
|
if filename.startswith('vmlinuz-'):
|
||||||
|
if os.path.exists('/boot/vmlinuz'):
|
||||||
|
os.unlink('/boot/vmlinuz')
|
||||||
os.symlink(filename, '/boot/vmlinuz')
|
os.symlink(filename, '/boot/vmlinuz')
|
||||||
break
|
break
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Reference in New Issue