kernel源码安装过程在上一篇文章中Fedora32 kernel源码包安装升级 从linux-5.6.6升到linux-5.8.7
问题不是按kernel的安装顺序写的,所有问题都是从操作记录中摘抄出来的,请针对问题内容查看解决处理方法
问题一:
Unable to find the ncurses package.
* Install ncurses (ncurses-devel or libncurses-dev
* You may also need to install pkg-config to find the
* ncurses installed in a non-default location.
[root@Fedora32 linux-5.8.7]# make O=/home/demo_accout/build/kernel/ menuconfig
make[1]: Entering directory '/home/demo_accout/build/kernel'
GEN Makefile
HOSTCC scripts/basic/fixdep
*
* Unable to find the ncurses package.
* Install ncurses (ncurses-devel or libncurses-dev
* depending on your distribution).
*
* You may also need to install pkg-config to find the
* ncurses installed in a non-default location.
*
make[2]: *** [/home/demo_accout/linux-5.8.7/scripts/kconfig/Makefile:214: scripts/kconfig/mconf-cfg] Error 1
make[1]: *** [/home/demo_accout/linux-5.8.7/Makefile:606: menuconfig] Error 2
make[1]: Leaving directory '/home/demo_accout/build/kernel'
make: *** [Makefile:185: __sub-make] Error 2
解决:
这里提示了缺少ncurses库文件,我们只要安装一个就可以了。问题和答案都写出来的,这样是很容易的。
[root@Fedora32 linux-5.8.7]# dnf install ncurses-devel

本文详细记录了在Fedora32系统中升级kernel源码到5.8.7过程中遇到的问题,包括ncurses、openssl、libelf-dev等库文件缺失的问题,以及BTF配置错误。通过安装缺失的库文件和修正配置,成功解决了编译问题。此外,探讨了删除kernel源码和编译文件夹后系统仍能正常启动的原因,关键在于/vmlinuz、/initramfs和/System.map文件的完整性。
最低0.47元/天 解锁文章
7719





