idf更新后,导致编译不过

karlno
Posts: 6
Joined: Sat Dec 08, 2018 5:54 am

idf更新后,导致编译不过

Postby karlno » Sat Dec 08, 2018 5:57 am

idf更新到了release 3.2
然后make menuconfig报错,如下:
kaka@kaka-VBox:/mnt/share/esp32/projects/hello_world$ make menuconfig
Toolchain path: /home/kaka/esp/xtensa-esp32-elf/bin/xtensa-esp32-elf-gcc
Toolchain version: crosstool-ng-1.22.0-80-g6c4433a
Compiler version: 5.2.0
make[1]: Entering directory '/mnt/share/esp32/esp-idf/tools/kconfig'
make[1]: /mnt/share/esp32/esp-idf/tools/kconfig/lxdialog/check-lxdialog.sh:命令未找到
cc -c -DLOCALE -MMD /mnt/share/esp32/esp-idf/tools/kconfig/mconf.c -o mconf.o
In file included from /mnt/share/esp32/esp-idf/tools/kconfig/mconf.c:23:0:
/mnt/share/esp32/esp-idf/tools/kconfig/lxdialog/dialog.h:38:10: error: #include expects "FILENAME" or <FILENAME>
#include CURSES_LOC
^
/mnt/share/esp32/esp-idf/tools/kconfig/lxdialog/dialog.h:103:2: error: unknown type name ‘chtype’
chtype atr; /* Color attribute */
^
/mnt/share/esp32/esp-idf/tools/kconfig/lxdialog/dialog.h:200:16: error: unknown type name ‘WINDOW’
int on_key_esc(WINDOW *win);
^
/mnt/share/esp32/esp-idf/tools/kconfig/lxdialog/dialog.h:221:17: error: unknown type name ‘WINDOW’
void attr_clear(WINDOW * win, int height, int width, chtype attr);
^
/mnt/share/esp32/esp-idf/tools/kconfig/lxdialog/dialog.h:221:54: error: unknown type name ‘chtype’
void attr_clear(WINDOW * win, int height, int width, chtype attr);
^
/mnt/share/esp32/esp-idf/tools/kconfig/lxdialog/dialog.h:223:21: error: unknown type name ‘WINDOW’
void print_autowrap(WINDOW * win, const char *prompt, int width, int y, int x);
^
/mnt/share/esp32/esp-idf/tools/kconfig/lxdialog/dialog.h:224:19: error: unknown type name ‘WINDOW’
void print_button(WINDOW * win, const char *label, int y, int x, int selected);
^
/mnt/share/esp32/esp-idf/tools/kconfig/lxdialog/dialog.h:225:18: error: unknown type name ‘WINDOW’
void print_title(WINDOW *dialog, const char *title, int width);
^
/mnt/share/esp32/esp-idf/tools/kconfig/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,
^
/mnt/share/esp32/esp-idf/tools/kconfig/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,
^
/mnt/share/esp32/esp-idf/tools/kconfig/lxdialog/dialog.h:227:8: error: unknown type name ‘chtype’
chtype border);
^
/mnt/share/esp32/esp-idf/tools/kconfig/lxdialog/dialog.h:228:18: error: unknown type name ‘WINDOW’
void draw_shadow(WINDOW * win, int y, int x, int height, int width);
^
/mnt/share/esp32/esp-idf/tools/kconfig/mconf.c: In function ‘conf’:
/mnt/share/esp32/esp-idf/tools/kconfig/lxdialog/dialog.h:97:29: error: ‘KEY_MAX’ undeclared (first use in this function)
#define ERRDISPLAYTOOSMALL (KEY_MAX + 1)
^
/mnt/share/esp32/esp-idf/tools/kconfig/mconf.c:671:45: note: in expansion of macro ‘ERRDISPLAYTOOSMALL’
if (res == 1 || res == KEY_ESC || res == -ERRDISPLAYTOOSMALL)
^
/mnt/share/esp32/esp-idf/tools/kconfig/lxdialog/dialog.h:97:29: note: each undeclared identifier is reported only once for each function it appears in
#define ERRDISPLAYTOOSMALL (KEY_MAX + 1)
^
/mnt/share/esp32/esp-idf/tools/kconfig/mconf.c:671:45: note: in expansion of macro ‘ERRDISPLAYTOOSMALL’
if (res == 1 || res == KEY_ESC || res == -ERRDISPLAYTOOSMALL)
^
/mnt/share/esp32/esp-idf/tools/kconfig/mconf.c: In function ‘show_help’:
/mnt/share/esp32/esp-idf/tools/kconfig/mconf.c:793:19: warning: implicit declaration of function ‘getmaxx’ [-Wimplicit-function-declaration]
help.max_width = getmaxx(stdscr) - 10;
^
/mnt/share/esp32/esp-idf/tools/kconfig/mconf.c:793:27: error: ‘stdscr’ undeclared (first use in this function)
help.max_width = getmaxx(stdscr) - 10;
^
In file included from /mnt/share/esp32/esp-idf/tools/kconfig/mconf.c:23:0:
/mnt/share/esp32/esp-idf/tools/kconfig/mconf.c: In function ‘conf_choice’:
/mnt/share/esp32/esp-idf/tools/kconfig/lxdialog/dialog.h:97:29: error: ‘KEY_MAX’ undeclared (first use in this function)
#define ERRDISPLAYTOOSMALL (KEY_MAX + 1)
^
/mnt/share/esp32/esp-idf/tools/kconfig/mconf.c:855:9: note: in expansion of macro ‘ERRDISPLAYTOOSMALL’
case -ERRDISPLAYTOOSMALL:
^
Makefile:171: recipe for target 'mconf.o' failed
make[1]: *** [mconf.o] Error 1
make[1]: Leaving directory '/mnt/share/esp32/esp-idf/tools/kconfig'
make: *** No rule to make target '/mnt/share/esp32/esp-idf/tools/kconfig/conf-idf', needed by '/mnt/share/esp32/esp-idf/tools/kconfig/mconf-idf'。 停止。


如何解决?

q515949148
Posts: 17
Joined: Wed Jul 25, 2018 8:11 am

Re: idf更新后,导致编译不过

Postby q515949148 » Sun Dec 09, 2018 3:20 am

make clean 一下
然后 git submodule update --init
试试?

karlno
Posts: 6
Joined: Sat Dec 08, 2018 5:54 am

Re: idf更新后,导致编译不过

Postby karlno » Sun Dec 09, 2018 5:51 am

一样的,make clean就会报同样的错
搜了下关键字,网上都说没有安装 libncurses5-dev的缘故,但是我ubuntu是安装过了,试了很久崩溃了。。。。
今年年头那个时候工具链版本才61的时候我编译过的,现在工具链是80了,对应的库,工具链都更新过了,不行
git子库的办法也试了,不是这个问题。
应该还是跟libncurses5-dev有关系,但是不知道为什么会有问题

karlno
Posts: 6
Joined: Sat Dec 08, 2018 5:54 am

Re: idf更新后,导致编译不过

Postby karlno » Sun Dec 09, 2018 8:02 am

找到问题了,换行符的问题,window下的换行符导致sh文件在ubuntu下无法被执行。

Who is online

Users browsing this forum: No registered users and 21 guests