1 # Maintainer: Richard Pöttler, richard dot poettler at gmail dot com
2 # Description: the linux kernel
3 # URL: http://www.kernel.org/
6 if [ -r /usr/src/kernel.release ]
8 . /usr/src/kernel.release
12 version=${version:-2.6.25.9}
14 source=(remove-lilo-calls.patch)
18 ketchup -d linux $version
21 # configure the kernel
22 if [ -r /usr/src/kernel.config ]
24 cp /usr/src/kernel.config .config
31 if [ -d /usr/src/kernel.patches/$version ]
33 for patch in /usr/src/kernel.patches/$version/*
39 # remove the lilo calls
40 patch -p0 < ../remove-lilo-calls.patch
45 # install the kernel image and the System.map
47 make INSTALL_PATH=$PKG/boot install
49 # tasks if modules are enabled
50 if grep '^[:space:]*CONFIG_MODULES=y' .config
53 make INSTALL_MOD_PATH=$PKG modules_install
55 # correct the /lib/modules/$version/{build,source} links to
57 rm $PKG/lib/modules/$version/{build,source}
58 ln -s /usr/src/linux $PKG/lib/modules/$version/build
59 ln -s /usr/src/linux $PKG/lib/modules/$version/source
62 # copy the configuration for later use
63 install .config $PKG/boot/kernel.config
65 # install the kernel sources
66 if [ ${INSTALL_KERNEL_SOURCE:-0} -eq 1 ]