[Solved] error Unable to find the ncurses libraries

When you enter the kernel directory, compile the kernel, and execute make menuconfig, you are prompted as follows:

*** Unable to find the ncurses libraries or the
 *** required header files.
 *** 'make menuconfig' requires the ncurses libraries.
 ***
 *** Install ncurses (ncurses-devel) and try again.
 ***
scripts/kconfig/Makefile:202: recipe for target 'scripts/kconfig/dochecklxdialog' failed
make[1]: *** [scripts/kconfig/dochecklxdialog] Error 1
Makefile:520: recipe for target 'menuconfig' failed
make: *** [menuconfig] Error 2

 

How to Solve:

1. Check out .bashrc

2… Solve according to the error: apt-get install ncurses-devel , again with the error.

E: Unable to locate package ncurses-devel

3. The above reason is because the system lacks libncurses library, so install it: sudo apt-get install libncurses-dev

4. Make menuconfig again, successfully: sudo apt-get install libncurses-dev

Read More: