%1,安装软件包:
sudo apt-get install fakeroot dpkg-dev libncurses5-dev kernel-package
%2,创建source directory
mkdir ~/src
cd ~/src
%3,下载内核源码
apt-get source linux-image-$(uname -r)
%4,配置内核
cd linux-3.0.0
make menuconfig
%5,加速构建
export CONCURRENCY_LEVEL=3
一般说来, concurrency level = number of processor cores + 1
%6,清理临时文件
make-kpkg clean
%7,编译内核
time fakeroot make-kpkg –initrd –append-to-version=-tweak kernel-image kernel-headers
你可以将-tweak 换成你希望的
%8,安装内核
cd ~/src
sudo dpkg -i linux-image-3.0.6-tweak_3.0.6-tweak-10.00.Custom_amd64.deb
sudo dpkg -i linux-headers-3.0.6-tweak_3.0.6-tweak-10.00.Custom_amd64.deb
%9,重启计算机