summaryrefslogtreecommitdiff
path: root/demo/custom/scripts/kernel-handset.post
blob: cb07f6cfc7fb4e92243e23510d9b1e0108a3099a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
echo "Checking for kernel......."
Kernel_Name=`ls /boot | grep vmlinuz`
if [ -f /boot/$Kernel_Name ]; then
        Kernel_Ver=`echo $Kernel_Name | sed s/vmlinuz-//`
        if [ -f /boot/initrd* ]; then
                echo "Initrd exists" > /dev/null
        else
                /usr/libexec/mkmrstinitrd /boot/initrd-$Kernel_Ver.img $Kernel_Ver
        fi
        #Create Symlinks
        cd /boot
        ln -s $Kernel_Name bzImage
        ln -s initrd-$Kernel_Ver.img initrd
        ln -s kboot.cmdline cmdline
else
        echo "No Kernels were found"
fi