如何安装 ncurses 头文件?

如何安装 ncurses 头文件?

我尝试配置内核,但出现以下错误。有人能告诉我该怎么办吗?

root@nitr-desktop:/usr/src/linux# make menuconfig
 *** Unable to find the ncurses libraries or the
 *** required header files.
 *** 'make menuconfig' requires the ncurses libraries.
 *** 
 *** Install ncurses (ncurses-devel) and try again.
 *** 
make[1]: *** [scripts/kconfig/dochecklxdialog] Error 1
make: *** [menuconfig] Error 2

答案1

打开终端并使用以下命令安装 libncurses-dev:

sudo apt-get install libncurses-dev

答案2

以上问题现已解决。我所做的就是:

sudo apt-get update
sudo apt-get install ncurses-dev

答案3

在 Ubuntu 17.04 上测试

你应该安装libncurses5-dev libncursesw5-dev

apt install libncurses5-dev libncursesw5-dev

参考:https://www.cyberciti.biz/faq/linux-install-ncurses-library-headers-on-debian-ubuntu-centos-fedora/

相关内容