linux: Update to 3.0.1 and fix compat symlinks (kernel26 upgrade path)

This commit is contained in:
Thomas Bächler
2011-08-06 14:50:29 +00:00
parent 90e0981b69
commit a72ea1d905
2 changed files with 17 additions and 10 deletions

View File

@@ -11,10 +11,18 @@ post_install () {
echo ">>> Generating initial ramdisk, using mkinitcpio. Please wait..."
mkinitcpio -p linux${KERNEL_NAME}
# add compat symlinks for the initramfs images
ln -sf initramfs-linux${KERNEL_NAME}.img boot/kernel26${KERNEL_NAME}.img
ln -sf initramfs-linux${KERNEL_NAME}-fallback.img \
boot/kernel26${KERNEL_NAME}-fallback.img
# compat symlinks for the official kernels only
if [ -z "${KERNEL_NAME}" -o "${KERNEL_NAME}" = "-lts" ]; then
loaders="$(find /boot -name syslinux.cfg -or -name extlinux.conf -or -name grub.cfg -or -name menu.lst)"
[ -f /etc/lilo.conf ] && loaders="$loaders /etc/lilo.conf"
if [ -n "${loaders}" ] && grep -q -e vmlinuz26 -e kernel26.img -e kernel26-fallback.img $loaders; then
# add compat symlinks for the initramfs images
ln -sf initramfs-linux${KERNEL_NAME}.img boot/kernel26${KERNEL_NAME}.img
ln -sf initramfs-linux${KERNEL_NAME}-fallback.img \
boot/kernel26${KERNEL_NAME}-fallback.img
ln -sf vmlinuz-linux${KERNEL_NAME} /boot/vmlinuz26${KERNEL_NAME}
fi
fi
}
post_upgrade() {