Build tools for 32-bit Linux

User avatar
luca.gamma
Posts: 15
Joined: Tue Apr 19, 2016 8:40 pm
Location: Switzerland

Build tools for 32-bit Linux

Postby luca.gamma » Mon Jan 16, 2017 6:21 pm

Following instructions in the ESP-IDF documentation about Linux setup it is not possible to download the 32-bit version of the Linux build tools 1.22.0-61 (nice to have because I'm also running Xubuntu on a netbook). Currently I installed 1.22.0-59 (GCC 4.8.5) but with the latest Git update the compilation fails when linking the app image:

Code: Select all

WARNING: Toolchain version is not supported: crosstool-NG crosstool-ng-1.22.0-59-g8d95cad
Expected to see version: crosstool-NG crosstool-ng-1.22.0-61-gab8375a
Please check ESP-IDF setup instructions and update the toolchain, or proceed at your own risk.
WARNING: Compiler version is not supported: 4.8.5
Expected to see version(s): 5.2.0
Please check ESP-IDF setup instructions and update the toolchain, or proceed at your own risk.
WARNING: Toolchain version is not supported: crosstool-NG crosstool-ng-1.22.0-59-g8d95cad
Expected to see version: crosstool-NG crosstool-ng-1.22.0-61-gab8375a
Please check ESP-IDF setup instructions and update the toolchain, or proceed at your own risk.
WARNING: Compiler version is not supported: 4.8.5
Expected to see version(s): 5.2.0
Please check ESP-IDF setup instructions and update the toolchain, or proceed at your own risk.
...
CC main.o
AR libmain.a
LD demo.elf
/home/luca/Playground/projects/espressif/esp32.works/demo/build/esp32/libesp32.a(system_api.o):(.iram1.literal+0x34): undefined reference to `esp_wifi_stop'
/home/luca/Playground/projects/espressif/esp32.works/demo/build/esp32/libesp32.a(system_api.o): In function `esp_restart_noos':
/home/luca/Playground/projects/espressif/esp-idf/components/esp32/./system_api.c:38: undefined reference to `esp_wifi_stop'
collect2: error: ld returned 1 exit status
/home/luca/Playground/projects/espressif/esp-idf/make/project.mk:313: recipe for target '/home/luca/Playground/projects/espressif/esp32.works/demo/build/demo.elf' failed
make: *** [/home/luca/Playground/projects/espressif/esp32.works/demo/build/demo.elf] Error 1
May the 1.22.0-59 break the SDK? Thanks!

ESP_Sprite
Posts: 9764
Joined: Thu Nov 26, 2015 4:08 am

Re: Build tools for 32-bit Linux

Postby ESP_Sprite » Tue Jan 17, 2017 1:48 am

That may be a bug in the SDK instead; have you confirmed that it *does* work on a 64-bit system? Either way, we'll investigate.

User avatar
ESP_krzychb
Posts: 400
Joined: Sat Oct 01, 2016 9:05 am
Contact:

Re: Build tools for 32-bit Linux

Postby ESP_krzychb » Tue Jan 17, 2017 7:15 am


User avatar
luca.gamma
Posts: 15
Joined: Tue Apr 19, 2016 8:40 pm
Location: Switzerland

Re: Build tools for 32-bit Linux

Postby luca.gamma » Tue Jan 17, 2017 7:19 am

Yes, the same code compiles on Linux 64 with xtensa-esp32-elf-linux64-1.22.0-61 but NON on Linux 32 with xtensa-esp32-elf-linux32-1.22.0-59. The main topic is that I would like to update the toolchain on Linux 32 too with xtensa-esp32-elf-linux32-1.22.0-61 BUT the link is broken:

Code: Select all

https://dl.espressif.com/dl/xtensa-esp32-elf-linux32-1.22.0-61-gab8375a-5.2.0.tar.gz -> 404 Not Found

matiasjara
Posts: 2
Joined: Fri Dec 16, 2016 2:09 pm

Re: Build tools for 32-bit Linux

Postby matiasjara » Tue Jan 17, 2017 12:57 pm

Hello,

I have the same problem on Windows 32.

Code: Select all

$ make app
WARNING: Toolchain version is not supported: crosstool-NG 8d95cad
Expected to see version: crosstool-NG crosstool-ng-1.22.0-61-gab8375a
Please check ESP-IDF setup instructions and update the toolchain, or proceed at your own risk.
WARNING: Compiler version is not supported: 4.8.5
Expected to see version(s): 5.2.0
Please check ESP-IDF setup instructions and update the toolchain, or proceed at your own risk.
LD app-template.elf
C:/Users/mjara/Documents/esp32/esp-idf-template/build/esp32\libesp32.a(system_api.o):(.iram1.literal+0x38): undefined reference to `esp_wifi_stop'
C:/Users/mjara/Documents/esp32/esp-idf-template/build/esp32\libesp32.a(system_api.o): In function `esp_restart_noos':
C:/Users/mjara/Documents/esp32/esp-idf/components/esp32/system_api.c:38: undefined reference to `esp_wifi_stop'
c:/msys32/opt/xtensa-esp32-elf/bin/../lib/gcc/xtensa-esp32-elf/4.8.5/../../../../xtensa-esp32-elf/lib\libstdc++.a(vterminate.o):(.literal._ZN9__gnu_cxx27__verbose_terminate_handlerEv+0x8): undefined reference to `_impure_ptr'
collect2.exe: error: ld returned 1 exit status
make: *** [/c/Users/mjara/Documents/esp32/esp-idf/make/project.mk:314: /c/Users/mjara/Documents/esp32/esp-idf-template/build/app-template.elf] Error 1
Any help?
Thank you!

User avatar
luca.gamma
Posts: 15
Joined: Tue Apr 19, 2016 8:40 pm
Location: Switzerland

Re: Build tools for 32-bit Linux

Postby luca.gamma » Tue Jan 17, 2017 3:21 pm

luca.gamma wrote:

Code: Select all

WARNING: Toolchain version is not supported: crosstool-NG crosstool-ng-1.22.0-59-g8d95cad
Expected to see version: crosstool-NG crosstool-ng-1.22.0-61-gab8375a
Please check ESP-IDF setup instructions and update the toolchain, or proceed at your own risk.
WARNING: Compiler version is not supported: 4.8.5
Expected to see version(s): 5.2.0
Please check ESP-IDF setup instructions and update the toolchain, or proceed at your own risk.
WARNING: Toolchain version is not supported: crosstool-NG crosstool-ng-1.22.0-59-g8d95cad
Expected to see version: crosstool-NG crosstool-ng-1.22.0-61-gab8375a
Please check ESP-IDF setup instructions and update the toolchain, or proceed at your own risk.
WARNING: Compiler version is not supported: 4.8.5
Expected to see version(s): 5.2.0
Please check ESP-IDF setup instructions and update the toolchain, or proceed at your own risk.
...
CC main.o
AR libmain.a
LD demo.elf
/home/luca/Playground/projects/espressif/esp32.works/demo/build/esp32/libesp32.a(system_api.o):(.iram1.literal+0x34): undefined reference to `esp_wifi_stop'
/home/luca/Playground/projects/espressif/esp32.works/demo/build/esp32/libesp32.a(system_api.o): In function `esp_restart_noos':
/home/luca/Playground/projects/espressif/esp-idf/components/esp32/./system_api.c:38: undefined reference to `esp_wifi_stop'
collect2: error: ld returned 1 exit status
/home/luca/Playground/projects/espressif/esp-idf/make/project.mk:313: recipe for target '/home/luca/Playground/projects/espressif/esp32.works/demo/build/demo.elf' failed
make: *** [/home/luca/Playground/projects/espressif/esp32.works/demo/build/demo.elf] Error 1
After last IDF commit (a14bef8) the compilation issue on 32-bit Linux seems to be resolved, now compiling even with 1.22.0-59 (GCC 4.8.5). Tested with idf-template, a slightly modified blink and spi_master examples.

User avatar
luca.gamma
Posts: 15
Joined: Tue Apr 19, 2016 8:40 pm
Location: Switzerland

Re: Build tools for 32-bit Linux

Postby luca.gamma » Wed Jan 18, 2017 6:35 am

matiasjara wrote: Any help?
Thank you!
Updating the IDF seems to resolve this issue:

Code: Select all

$ cd esp-idf
$ git pull
$ git submodule update
$ cd $PROJECT
$ make clean; make defconfig; make all

User avatar
ESP_krzychb
Posts: 400
Joined: Sat Oct 01, 2016 9:05 am
Contact:

Re: Build tools for 32-bit Linux

Postby ESP_krzychb » Thu Jan 19, 2017 8:47 pm

../esp-idf/components/esp32/./system_api.c:38: undefined reference to `esp_wifi_stop'
I have noticed exactly the same error when compiling sd_card example.

This example is not using Wi-Fi at all.
To resolve this error I have disabled Wi-Fi in menuconfig.

Ritesh
Posts: 1383
Joined: Tue Sep 06, 2016 9:37 am
Location: India
Contact:

Re: Build tools for 32-bit Linux

Postby Ritesh » Thu Feb 02, 2017 6:51 am

Hi All,

Is there any other location from where I can get both 32 and 64 bit toolchain in compressed package as I am also getting same error like "404 page not found" while opening this below link.
I have tried manual steps to cross compile toolchain source but getting some problem as I am using older Ubuntu 12.04 Linux system in which some packages are older which causes to stop to compile the toolchain from source using crosstool-NG

Please provide me link from where I can get both updated 5.2.0 toolchain for 32 bit and 64 bit machines as I need to compile my application using latest ESP32-IDF SDK in which they have mentioned that you need higher version of toolchain for that as per below logs.
Unknown option: -C
usage: git [--version] [--exec-path[=<path>]] [--html-path] [--man-path] [--info-path]
[-p|--paginate|--no-pager] [--no-replace-objects] [--bare]
[--git-dir=<path>] [--work-tree=<path>] [--namespace=<name>]
[-c name=value] [--help]
<command> [<args>]
WARNING: Toolchain version is not supported: crosstool-NG crosstool-ng-1.22.0-59-g8d95cad
Expected to see version: crosstool-NG crosstool-ng-1.22.0-61-gab8375a
Please check ESP-IDF setup instructions and update the toolchain, or proceed at your own risk.
WARNING: Compiler version is not supported: 4.8.5
Expected to see version(s): 5.2.0
Please check ESP-IDF setup instructions and update the toolchain, or proceed at your own risk.
Unknown option: -C
usage: git [--version] [--exec-path[=<path>]] [--html-path] [--man-path] [--info-path]
[-p|--paginate|--no-pager] [--no-replace-objects] [--bare]
[--git-dir=<path>] [--work-tree=<path>] [--namespace=<name>]
[-c name=value] [--help]
<command> [<args>]
WARNING: Toolchain version is not supported: crosstool-NG crosstool-ng-1.22.0-59-g8d95cad
Expected to see version: crosstool-NG crosstool-ng-1.22.0-61-gab8375a
Please check ESP-IDF setup instructions and update the toolchain, or proceed at your own risk.
WARNING: Compiler version is not supported: 4.8.5
Expected to see version(s): 5.2.0
Please check ESP-IDF setup instructions and update the toolchain, or proceed at your own risk.
Regards,
Ritesh Prajapati

User avatar
kolban
Posts: 1683
Joined: Mon Nov 16, 2015 4:43 pm
Location: Texas, USA

Re: Build tools for 32-bit Linux

Postby kolban » Thu Feb 02, 2017 2:57 pm

You can download the Linux 64 bit compiled toolchain from here:

https://dl.espressif.com/dl/xtensa-esp3 ... 2.0.tar.gz

See the following docs:

http://esp-idf.readthedocs.io/en/latest ... -the-esp32

However, the link for the 32 bit compiled toolchain is not working as of the date of this post and there is an open issue to resolve that .. see:

https://github.com/espressif/esp-idf/issues/279
Free book on ESP32 available here: https://leanpub.com/kolban-ESP32

Who is online

Users browsing this forum: No registered users and 6 guests