pfalcon / esp-open-sdk

Free and open (as much as possible) integrated SDK for ESP8266/ESP8285 chips
1.97k stars 624 forks source link

SDK supplied libgcc is masking crosstool-ng built version, which has ".text too big" issue #216

Open davydnorris opened 8 years ago

davydnorris commented 8 years ago

The SDK /lib directory contains its own libgcc.a, which is >200k smaller in size than the one built and installed as part of crosstool-ng. Its position in the toolchain either when copied or when used in a separate SDK means that the crosstool built libgcc is not used (and so recently added fp routines are missed)

When the SDK version is renamed, a hidden size problem with .text and iram becomes apparent

davydnorris commented 7 years ago

This script for ar will remove the functions from libgcc.a which are in the esp8266 ROM. This then means that applications linked with the crosstool-NG built libgcc will now fit.

It also means that the esp-open-sdk Makefile can replace the SDK supplied one.

strip_libgcc_funcs.txt

ghost commented 7 years ago

In my case, the libgcc.a files in "xtensa-lx106-elf/xtensa-lx106-elf/sysroot/usr/lib" and "NONOS_SDK/lib/" have exactly the same size but i still get the message if i try to make my project.