fail to compile esp-idf-v2.0 release on ubuntu linux env

taxi_dong
Posts: 7
Joined: Mon Feb 06, 2017 3:29 am

fail to compile esp-idf-v2.0 release on ubuntu linux env

Postby taxi_dong » Thu Apr 20, 2017 2:48 am

hi
Yesterday I start to download new v2.0 release
=================================================================
git clone https://github.com/espressif/esp-idf.git esp-idf-v2.0
cd esp-idf-v2.0/
git checkout v2.0
git submodule update --init
=================================================================

When I run "make menuconfig", the output is follow

==========================================================================================================
rock@rock-virtual-machine:~$ cd newworkspace/hello_world/
rock@rock-virtual-machine:~/newworkspace/hello_world$ export IDF_PATH=~/newworkspace/esp-idf/
rock@rock-virtual-machine:~/newworkspace/hello_world$ echo $IDF_PATH
/home/rock/newworkspace/esp-idf/
rock@rock-virtual-machine:~/newworkspace/hello_world$ make menuconfig
/home/rock/newworkspace/esp-idf/make/common.mk:10: /home/rock/newworkspace/hello_world/build/include/config/auto.conf: 没有那个文件或目录
make[1]: Entering directory '/home/rock/newworkspace/esp-idf/tools/kconfig'
make[1]: lxdialog/check-lxdialog.sh:命令未找到 command not found
cc -DLOCALE -c -o mconf.o mconf.c
In file included from mconf.c:23:0:
lxdialog/dialog.h:38:10: error: #include expects "FILENAME" or <FILENAME>
#include CURSES_LOC
^
lxdialog/dialog.h:103:2: error: unknown type name ‘chtype’
chtype atr; /* Color attribute */
^
lxdialog/dialog.h:200:16: error: unknown type name ‘WINDOW’
int on_key_esc(WINDOW *win);
^
lxdialog/dialog.h:221:17: error: unknown type name ‘WINDOW’
void attr_clear(WINDOW * win, int height, int width, chtype attr);
^
lxdialog/dialog.h:221:54: error: unknown type name ‘chtype’
void attr_clear(WINDOW * win, int height, int width, chtype attr);
^
lxdialog/dialog.h:223:21: error: unknown type name ‘WINDOW’
void print_autowrap(WINDOW * win, const char *prompt, int width, int y, int x);
^
lxdialog/dialog.h:224:19: error: unknown type name ‘WINDOW’
void print_button(WINDOW * win, const char *label, int y, int x, int selected);
^
lxdialog/dialog.h:225:18: error: unknown type name ‘WINDOW’
void print_title(WINDOW *dialog, const char *title, int width);
^
lxdialog/dialog.h:226:15: error: unknown type name ‘WINDOW’
void draw_box(WINDOW * win, int y, int x, int height, int width, chtype box,
^
lxdialog/dialog.h:226:66: error: unknown type name ‘chtype’
void draw_box(WINDOW * win, int y, int x, int height, int width, chtype box,
^
lxdialog/dialog.h:227:8: error: unknown type name ‘chtype’
chtype border);
^
lxdialog/dialog.h:228:18: error: unknown type name ‘WINDOW’
void draw_shadow(WINDOW * win, int y, int x, int height, int width);
^
mconf.c: In function ‘conf’:
lxdialog/dialog.h:97:29: error: ‘KEY_MAX’ undeclared (first use in this function)
#define ERRDISPLAYTOOSMALL (KEY_MAX + 1)
^
mconf.c:671:45: note: in expansion of macro ‘ERRDISPLAYTOOSMALL’
if (res == 1 || res == KEY_ESC || res == -ERRDISPLAYTOOSMALL)
^
lxdialog/dialog.h:97:29: note: each undeclared identifier is reported only once for each function it appears in
#define ERRDISPLAYTOOSMALL (KEY_MAX + 1)
^
mconf.c:671:45: note: in expansion of macro ‘ERRDISPLAYTOOSMALL’
if (res == 1 || res == KEY_ESC || res == -ERRDISPLAYTOOSMALL)
^
mconf.c: In function ‘show_help’:
mconf.c:793:19: warning: implicit declaration of function ‘getmaxx’ [-Wimplicit-function-declaration]
help.max_width = getmaxx(stdscr) - 10;
^
mconf.c:793:27: error: ‘stdscr’ undeclared (first use in this function)
help.max_width = getmaxx(stdscr) - 10;
^
In file included from mconf.c:23:0:
mconf.c: In function ‘conf_choice’:
lxdialog/dialog.h:97:29: error: ‘KEY_MAX’ undeclared (first use in this function)
#define ERRDISPLAYTOOSMALL (KEY_MAX + 1)
^
mconf.c:855:9: note: in expansion of macro ‘ERRDISPLAYTOOSMALL’
case -ERRDISPLAYTOOSMALL:
^
<builtin>: recipe for target 'mconf.o' failed
make[1]: *** [mconf.o] Error 1
make[1]: Leaving directory '/home/rock/newworkspace/esp-idf/tools/kconfig'
/home/rock/newworkspace/esp-idf/make/project_config.mk:20: recipe for target '/home/rock/newworkspace/esp-idf/tools/kconfig/conf' failed
make: *** [/home/rock/newworkspace/esp-idf/tools/kconfig/conf] Error 2
rock@rock-virtual-machine:~/newworkspace/hello_world$
========================================================================================================

I check the Makefile file and folder, the check-lxdialog.sh file exists

=====================================================================================
rock@rock-virtual-machine:~/newworkspace/hello_world$ cd ..
rock@rock-virtual-machine:~/newworkspace$ cd esp-idf/tools/kconfig/
rock@rock-virtual-machine:~/newworkspace/esp-idf/tools/kconfig$ ls
check.sh Kconfig mconf.c qconf.h
conf.c kconfig-language.txt menu.c streamline_config.pl
confdata.c kxgettext.c merge_config.sh symbol.c
expr.c list.h nconf.c util.c
expr.h lkc.h nconf.gui.c zconf.gperf
gconf.c lkc_proto.h nconf.h zconf.l
gconf.glade lxdialog POTFILES.in zconf.y
images.c Makefile qconf.cc
rock@rock-virtual-machine:~/newworkspace/esp-idf/tools/kconfig$ cd lxdialog/
rock@rock-virtual-machine:~/newworkspace/esp-idf/tools/kconfig/lxdialog$ ls
BIG.FAT.WARNING check-lxdialog.sh inputbox.c textbox.c yesno.c
checklist.c dialog.h menubox.c util.c
rock@rock-virtual-machine:~/newworkspace/esp-idf/tools/kconfig/lxdialog$
=========================================================================

Actually I never met such issue on esp-idf-v2.0-rc1 version.
Thanks

taxi_dong
Posts: 7
Joined: Mon Feb 06, 2017 3:29 am

Re: fail to compile esp-idf-v2.0 release on ubuntu linux env

Postby taxi_dong » Thu Apr 20, 2017 2:59 am

Just try to download the v2.0 version by zip file download directly, the compile error is gone. So the code base download by my git command may be corrupted, or my git command is not right one.

ESP_igrr
Posts: 2071
Joined: Tue Dec 01, 2015 8:37 am

Re: fail to compile esp-idf-v2.0 release on ubuntu linux env

Postby ESP_igrr » Thu Apr 20, 2017 3:11 am

Yes, the log indicates that " lxdialog/check-lxdialog.sh:命令未找到 command not found", so either lxdialog/check-lxdialog.sh is not present under tools/kconfig directory, or it doesn't have executable permission for the current user.

cloud2020
Posts: 2
Joined: Thu Jun 22, 2017 7:09 am

Re: fail to compile esp-idf-v2.0 release on ubuntu linux env

Postby cloud2020 » Fri Jul 07, 2017 9:44 am

you should specify the path first, "export IDF_PATH=******", "******"means the path of "esp-idf".

Who is online

Users browsing this forum: AndreaS73, Baidu [Spider] and 69 guests