跳转至

Linux 内核编译尝试

资源

尝试

Bash
 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
# 在<https://www.kernel.org>找到最新的稳定版链接,复制
# 使用wget下载.tar包
wget https://cdn.kernel.org/pub/linux/kernel/v5.x/linux-5.17.2.tar.xz
# 解压
tar xvf linux-5.17.2.tar.xz
# 进入之后退出生成默认配置.config
(apt install libncurses-dev &&) make menuconfig
# 编译
(apt install libssl-dev libelf-dev &&) make
# 安装模块
make modules_install
# 安装在本机
make install

遇到的问题

Text Only
1
make[1]: *** No rule to make target 'debian/canonical-certs.pem', needed by 'certs/x509_certificate_list'.  Stop.

参考https://askubuntu.com/questions/1329538/compiling-the-kernel-5-11-11

Text Only
1
2
scripts/config --disable SYSTEM_TRUSTED_KEYS
scripts/config --disable SYSTEM_REVOCATION_KEYS

References