I can never remember the exact steps and their order to compile a kernel, so I'm just playing around to make a little script that will stop me needing to

. This is for a 2.4 kernel btw.
The way the it works is that I su and cd to the directory where the new kernel source has unpacked, then run the script. What happens then is pretty self explanatory. Here's what the script looks like at the moment:
Code:
rm /usr/src/linux
ln -sf ./ /usr/src/linux
make mrproper
cp /home/keffin/Important/config ./.config
make menuconfig
cp ./.config /home/keffin/Important/config-NEW
make dep clean
make bzImage
make modules
make modules_install
cp arch/i386/boot/bzImage /boot/kernel-NEW
cp System.map /boot/System.map-NEW
cd /boot
ls
gedit /boot/grub/grub.conf
The second line (
ln -sf ./ /usr/src/linux) is intended to create a symlink /usr/src/linux which points to the current directory, but looking at the output of
ls -l /usr/src it shows the symlink literally pointing to "./". Is there a way I can make it replace this with the actual path to the current directory?
Also, if there's an easy way to place the actual version number of the new kernel in the place of "NEW" in kernel-NEW etc. then that would be brilliant. In fact if there's a hard way it would be cool too

.
Any help much appreciated.