Problems running ESP IDF

janwil
Posts: 3
Joined: Fri May 03, 2019 5:58 am

Problems running ESP IDF

Postby janwil » Fri May 03, 2019 6:11 am

Hello,

I am trying to run ESP-IDF on Arch Linux. I followed all the steps on the Getting Started guide (replacing python with python2.7 where necessary), but when I try to run make menuconfig on Hello World example I get
The following Python requirements are not satisfied:
future>=0.15.2
cryptography>=2.1.4
pyparsing>=2.0.3,<2.4.0
pyelftools>=0.22
At the same time pip2 reports that the versions installed are fine, e.g.
$ pip2 list | grep cryptography
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7.
cryptography 2.6.1
I must say I am quite confused, why can't make menuconfig find these modules?

Then I discovered that Arch AUR also has packages for esp-idf and esp-idf-git. I tried these, too (setting the IDF_PATH variable accordingly) and there I get another error with make menuconfig:
make[1]: Entering directory '/opt/esp-idf-sdk/tools/kconfig'
cc -c -D_GNU_SOURCE -D_DEFAULT_SOURCE -DCURSES_LOC="<ncurses.h>" -DNCURSES_WIDECHAR=1 -DLOCALE -MMD /opt/esp-idf-sdk/tools/kconfig/mconf.c -o mconf.o
/opt/esp-idf-sdk/tools/kconfig/mconf.c:1053:1: fatal error: opening dependency file mconf.d: Permission denied
}
^
compilation terminated.
I tried googling for this, and a similar problem was reported at https://stackoverflow.com/questions/514 ... atal-error, but the solution was "do not run something with sudo" that I am not able to translate to Arch environment -- to install a system package I have to do it with sudo.

So any help with either of these problems will be greatly appreciated.

Thanks in advance,
Jan

ESP_Angus
Posts: 2344
Joined: Sun May 08, 2016 4:11 am

Re: Problems running ESP IDF

Postby ESP_Angus » Fri May 03, 2019 6:42 am

Hi Jan,

The Python errors happen after you exit the menuconfig dialog, right? You should be able to get into the menuconfig dialog without a Python check.

Can you confirm that you've set the Python interpreter version under "SDK tool configuration" in menuconfig to python2 or python2.7? This is the interpreter that the build system will use to run the dependency check.

If you run the command shown here for Python 2, does it say that everything is already installed?
https://docs.espressif.com/projects/esp ... n-packages

BTW, if you're using IDF master branch then it should be possible to use Python 3 as well.

Regarding the AUR packages, they're not something we produce or suppport so I have no idea - sorry. Unless they're being regularly updated I suggest sticking with our install guide.

janwil
Posts: 3
Joined: Fri May 03, 2019 5:58 am

Re: Problems running ESP IDF

Postby janwil » Fri May 03, 2019 8:07 am

ESP_Angus wrote: Hi Jan,

The Python errors happen after you exit the menuconfig dialog, right?
No, the errors happen when I run make menuconfig, so I can not even get to the menu to select "SDK tool configuration" or anything else.
ESP_Angus wrote: If you run the command shown here for Python 2, does it say that everything is already installed?
https://docs.espressif.com/projects/esp ... n-packages
Yes, it shows I have everything installed ("requirements already satisfied").
ESP_Angus wrote: BTW, if you're using IDF master branch then it should be possible to use Python 3 as well.
OK, I can try that. But it would still be good to understand why the mainline installation process fails.

Best,
Jan

janwil
Posts: 3
Joined: Fri May 03, 2019 5:58 am

Re: Problems running ESP IDF

Postby janwil » Fri May 03, 2019 4:36 pm

Hi again,

After having played around with this and that I finally got the toolchain to work with Python3 in a virtualenv. Still no clue why the site-wide approach did not work, but at least I have a working system now.

Best,
Jan

Who is online

Users browsing this forum: Baidu [Spider], Bing [Bot] and 112 guests