After idf.py menuconfig is run, ESP8266_RTOS_SDK/tools/kconfig/lxdialog/check-lxdialog.sh reports an error
*** Unable to find the ncurses libraries or the
*** required header files.
*** 'make menuconfig' requires the ncurses libraries.
***
*** Install ncurses (ncurses-devel) and try again.
***
Althought, both ncurses and ncurses-devel is preset on the system.
After a bit of digging, I realized that error is actually not related to ncurses at all. The way script checks for ncurses presence is kida lame not so good, furthermore it relies on non-standard C (ommiting type before the main function), so compiler generates a warning which makes the check fail.
Expected Behavior
Menuconfig builds out of the box.
Actual Behavior
To build menuconfig, tinkering with idf scripts is required.
Steps to repropduce
May be kind of tricky, as it depends on compiler options and the compiler itself. I personaly add -std=c11 at the project-level CMakeLists, but not sure if it matters.
Fix
Adding int before this test main function fixes the problem.
Similar issue do exist, but is closed and not very relevant as about an arch package.
Environment
Problem Description
After
idf.py menuconfig
is run,ESP8266_RTOS_SDK/tools/kconfig/lxdialog/check-lxdialog.sh
reports an errorAlthought, both
ncurses
andncurses-devel
is preset on the system. After a bit of digging, I realized that error is actually not related to ncurses at all. The way script checks for ncurses presence iskida lamenot so good, furthermore it relies on non-standard C (ommiting type before themain
function), so compiler generates a warning which makes the check fail.Expected Behavior
Menuconfig builds out of the box.
Actual Behavior
To build menuconfig, tinkering with idf scripts is required.
Steps to repropduce
May be kind of tricky, as it depends on compiler options and the compiler itself. I personaly add
-std=c11
at the project-level CMakeLists, but not sure if it matters.Fix
Adding
int
before this testmain
function fixes the problem.