User Tools

Site Tools


tech:unix:gentoo_kernel_build

(Re)Build a gentoo kernel

Copy .config from old kernel into the new kernel:

cp /usr/src/old-kernel/.config /usr/src/new-kernel

Link the symlink 'linux' to new kernel:

cd /usr/src
rm linux
ln -s ./new-kernel ./linux

Merge the .config into the new kernel:

cd /usr/src/linux
make oldconfig

Give the new kernel a once-over with:

make menuconfig

Build the new kernel:

make && make modules_install

Copy kernel files to boot:

cp System.map /boot/new-kernel.map
cp .config /boot/new-kernel.config
cp arch/i386/boot/bzimage /boot/new-kernel

Modify grub or lilo as needed (no code snippet)

tech/unix/gentoo_kernel_build.txt · Last modified: 2024/06/21 12:04 by 127.0.0.1