New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stable version libm.a compilation error #612

Closed
ghost opened this Issue Jul 25, 2015 · 43 comments

Comments

Projects
None yet
@ghost
Copy link

ghost commented Jul 25, 2015

Compiling project using libm.a throws:
packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-e_pow.o):(.literal+0xf8): undefined reference to `__ieee754_sqrt'

packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-e_pow.o): In function __ieee754_pow': d:\ivan\projects\arduinoesp\toolchain\dl\esp-newlib\build\xtensa-lx106-elf\newlib\libm\math/../../../../../newlib/libm/math/e_pow.c:164: undefined reference to__ieee754_sqrt'
collect2.exe: error: ld returned 1 exit status

Some hints how to deal with this? Thanks

Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

@krulkip

This comment has been minimized.

Copy link

krulkip commented Jul 26, 2015

I get same problem.

Arduino: 1.6.5 (Windows 7), Board: "Generic ESP8266 Module, Serial, 80 MHz, 40MHz, DIO, 115200, 512K (64K SPIFFS)"

j:/arduino-1.6.5-r2/portable/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-e_pow.o):(.literal+0xec): undefined reference to __ieee754_sqrt' j:/arduino-1.6.5-r2/portable/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-e_pow.o): In function__ieee754_pow':
d:\ivan\projects\arduinoesp\toolchain\dl\esp-newlib\build\xtensa-lx106-elf\newlib\libm\math/../../../../../newlib/libm/math/e_pow.c:164: undefined reference to `__ieee754_sqrt'
collect2.exe: error: ld returned 1 exit status

@forkineye

This comment has been minimized.

Copy link
Contributor

forkineye commented Jul 28, 2015

Experiencing this as well / windows 8.1 and Arduino 1.6.5-r2
Arduino: 1.6.5 (Windows 8.1), Board: "NodeMCU 1.0 (ESP-12E Module), 80 MHz, 115200"

c:/users/xxxx/appdata/roaming/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-e_pow.o):(.literal+0x104): undefined reference to __ieee754_sqrt'c:/users/xxxx/appdata/roaming/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-e_pow.o): In function __ieee754_pow':
d:\ivan\projects\arduinoesp\toolchain\dl\esp-newlib\build\xtensa-lx106-elf\newlib\libm\math/../../../../../newlib/libm/math/e_pow.c:164: undefined reference to __ieee754_sqrt'`
collect2.exe: error: ld returned 1 exit status

@igrr

This comment has been minimized.

Copy link
Member

igrr commented Jul 28, 2015

I think the workaround is to delete the downloaded package (it's somewhere
in the user folder on Windows) as well as downloaded toolchain archive.
Arduino doesn't download the file again even though the size and checksum
had changed.

I will bump toolchain version for the next release.

On Tue, Jul 28, 2015, 20:23 Shelby Merrick notifications@github.com wrote:

Experiencing this as well / windows 8.1 and Arduino 1.6.5-r2
Arduino: 1.6.5 (Windows 8.1), Board: "NodeMCU 1.0 (ESP-12E Module), 80
MHz, 115200"

c:/users/xxxx/appdata/roaming/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-e_pow.o):(.literal+0x104):
undefined reference to __ieee754_sqrt' c:/users/xxxx/appdata/roaming/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-e_pow.o): In function__ieee754_pow':
d:\ivan\projects\arduinoesp\toolchain\dl\esp-newlib\build\xtensa-lx106-elf\newlib\libm\math/../../../../../newlib/libm/math/e_pow.c:164:
undefined reference to `__ieee754_sqrt'

collect2.exe: error: ld returned 1 exit status

Reply to this email directly or view it on GitHub
#612 (comment).

@forkineye

This comment has been minimized.

Copy link
Contributor

forkineye commented Jul 28, 2015

@igrr I just tried that out, removing the ESP8266 board from the Arduino IDE and then removing all ESP and xtensa references located in the users\<user>\appdata\arduino15 packaging and staging directories. Same issue when trying to call pow().

Example from a gamma table generation loop: Serial.print((int)(255 * pow((i / 255), gamma)));

@krulkip krulkip referenced this issue Aug 2, 2015

Closed

compile error #12

@forkineye

This comment has been minimized.

Copy link
Contributor

forkineye commented Aug 4, 2015

I'm able to recreate this issue, but only with floats inside of loops. Code to re-create is here - https://gist.github.com/forkineye/d05909c5c0184c7300ae. The toolchain is 1.20.0-26-gb404fb9. Toolchain archive is win32-xtensa-lx106-elf-gb404fb9.tar.gz with a MD5 hash of 7e6cf4fb104022ddee0b9ef716232439

void setup() {
    Serial.begin(115200);
    Serial.println("");

    float x = 2.0; 
    float y = 2.2;

    int i;
    for(i = 0; i < 10; i++) {
        Serial.println(pow(i, x));
        Serial.println(pow(i, y));    // Fails to compile
    }
    Serial.println(pow(i, y));        // Compiles fine, 10 ^ 2.2
}

void loop() {

}
@krulkip

This comment has been minimized.

Copy link

krulkip commented Aug 8, 2015

This seems to refer to a fix for this issue, but not sure how to try
jcmvbkbc/crosstool-NG@b404fb9

@igrr

This comment has been minimized.

Copy link
Member

igrr commented Aug 9, 2015

Windows toolchain is not built using crosstool-NG, so probably not exactly
relevant.

On Sun, Aug 9, 2015, 00:41 krulkip notifications@github.com wrote:

This seems to refer to a fix for this issue, but not sure how to try
jcmvbkbc/crosstool-NG@b404fb9
jcmvbkbc/crosstool-NG@b404fb9


Reply to this email directly or view it on GitHub
#612 (comment).

@krulkip

This comment has been minimized.

Copy link

krulkip commented Aug 9, 2015

I installed this libm.a file replacing the xisting one in 1.20.0-26-gb404fb9/xtensa-lx106-elf/lib/ and the error was solved.
https://files.gitter.im/esp8266/Arduino/Abqa/libm.a.tbz

@igrr igrr closed this in 5c410c7 Aug 10, 2015

@igrr igrr reopened this Aug 10, 2015

@Testato

This comment has been minimized.

Copy link
Contributor

Testato commented Aug 22, 2015

same problem here, i use the Stable version on Win7-64

Is it solved on Staging Version ?

@locchi93

This comment has been minimized.

Copy link

locchi93 commented Aug 30, 2015

same problem on windows using the current Stable version and Arduino ide 1.6.5

@Testato

This comment has been minimized.

Copy link
Contributor

Testato commented Aug 30, 2015

@krulkip
Thanks, whit your lib there is no problem

@erhome00

This comment has been minimized.

Copy link

erhome00 commented Sep 4, 2015

Testato or igrr,

can you please tell me how exactly I use that corrected LIB? I have the same problem and am not able to solve it...

@tim-in-oakton

This comment has been minimized.

Copy link

tim-in-oakton commented Sep 6, 2015

Doh!! I was multiplexing and missed the note from krulkip - copied his older libm.a over, now compiles -

we must have a bug in the package..... but this is a workaround!

Same issue here, trying to port over a module that uses math - at compile I get:

c:/users/timm/appdata/roaming/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-w_sqrt.o):(.literal+0x4): undefined reference to __ieee754_sqrt' c:/users/timm/appdata/roaming/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-w_sqrt.o): In functionsqrt':
d:\ivan\projects\arduinoesp\toolchain\dl\esp-newlib\build\xtensa-lx106-elf\newlib\libm\math/../../../../../newlib/libm/math/w_sqrt.c:63: undefined reference to __ieee754_sqrt' c:/users/timm/appdata/roaming/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-e_asin.o): In function__ieee754_asin':
d:\ivan\projects\arduinoesp\toolchain\dl\esp-newlib\build\xtensa-lx106-elf\newlib\libm\math/../../../../../newlib/libm/math/e_asin.c:104: undefined reference to `__ieee754_sqrt'
collect2.exe: error: ld returned 1 exit status
Error compiling.

I'm on 1.6.5 of the IDE, and did a remove/replace of the ESP8266 board support package - no change in displayed error message. Windows dev environment.

Any idea how to mitigate this?
tim

@Testato

This comment has been minimized.

Copy link
Contributor

Testato commented Sep 6, 2015

@erhome00
I followed exactly what krulkip wrote

worked on Win7-64

@erhome00

This comment has been minimized.

Copy link

erhome00 commented Sep 7, 2015

Thanks for the replies. It was my mistake...got to use the Stageing version and not the Stable version. The change was not yet migrated to the Stable...

Now everything works just fine!

Thanks for that nice fix!

@aniston

This comment has been minimized.

Copy link

aniston commented Sep 27, 2015

Just to confirm, changing the libm.a with the link supplied by Krulkip and the error with - undefined reference to `__ieee754_sqrt' is no more, code compiles and works.

I had to change the file in this folder ::
C:\Users\aniston\AppData\Roaming\Arduino15\packages\esp8266\tools\xtensa-lx106-elf-gcc\1.20.0-26-gb404fb9\xtensa-lx106-elf\lib

Arduino: 1.6.5 (Windows 7 x64), Generic ESP8266 Module, Serial, 80 MHz, 40MHz, DIO, 115200, 512K (64K SPIFFS)

@cuillerj

This comment has been minimized.

Copy link

cuillerj commented Sep 28, 2015

I got the same problem and did exactly what krulkip wrote.
And it works
Thanks

@QuadTinnakon

This comment has been minimized.

Copy link

QuadTinnakon commented Sep 29, 2015

c:/users/n_sam/appdata/roaming/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-w_sqrt.o):(.literal+0x4): undefined reference to __ieee754_sqrt' c:/users/n_sam/appdata/roaming/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-w_sqrt.o): In functionsqrt':
d:\ivan\projects\arduinoesp\toolchain\dl\esp-newlib\build\xtensa-lx106-elf\newlib\libm\math/../../../../../newlib/libm/math/w_sqrt.c:63: undefined reference to __ieee754_sqrt' c:/users/n_sam/appdata/roaming/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-e_asin.o): In function__ieee754_asin':
d:\ivan\projects\arduinoesp\toolchain\dl\esp-newlib\build\xtensa-lx106-elf\newlib\libm\math/../../../../../newlib/libm/math/e_asin.c:104: undefined reference to `__ieee754_sqrt'
collect2.exe: error: ld returned 1 exit status
Error compiling.

What causes.
Thanks.

@mytot

This comment has been minimized.

Copy link

mytot commented Oct 25, 2015

while i am downloading krulkip file, it was of 165KB, and previoius one is 2MB, and after replacing the file i am getting below error.

Arduino: 1.6.5 (Windows 8.1), Board: "Generic ESP8266 Module, Serial, 80 MHz, 40MHz, DIO, 115200, 512K (64K SPIFFS)"

c:/users/shann/appdata/roaming/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a: file not recognized: File format not recognized
collect2.exe: error: ld returned 1 exit status
Error compiling.

This report would have more information with
"Show verbose output during compilation"
enabled in File > Preferences.

Help me in resolving the issue

@aniston

This comment has been minimized.

Copy link

aniston commented Oct 25, 2015

@mytot I think you have the wrong path, try downloading it into c:\users\shann\AppData\Roaming\Arduino15\packages\esp8266\tools\xtensa-lx106-elf-gcc\1.20.0-26-gb404fb9\xtensa-lx106-elf\lib

EDIT: @mytot sorry for the confusion, please ignore the path suggestion above as it points to the same folder you have used, can only confirm that the file size of libm.a is 1051142 bytes

@DiegoDVG

This comment has been minimized.

Copy link

DiegoDVG commented Oct 27, 2015

hi!

this is my problem

Arduino:1.6.5 (Windows 8.1), Placa:"Generic ESP8266 Module, Serial, 80 MHz, 40MHz, DIO, 115200, 512K (64K SPIFFS)"

c:/users/diego/appdata/roaming/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-w_sqrt.o):(.literal+0x8): undefined reference to __ieee754_sqrt' c:/users/diego/appdata/roaming/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-w_sqrt.o): In functionsqrt':
d:\ivan\projects\arduinoesp\toolchain\dl\esp-newlib\build\xtensa-lx106-elf\newlib\libm\math/../../../../../newlib/libm/math/w_sqrt.c:63: undefined reference to `__ieee754_sqrt'
collect2.exe: error: ld returned 1 exit status
Error de compilación

This report would have more information with
"Show verbose output during compilation"
activala desde Archivo > Preferencias

win 10 pro

I try to use MPU6050

@nabkey

This comment has been minimized.

Copy link

nabkey commented Oct 27, 2015

@mytot The reason you're having the issue is that @krulkip posted a file that's in an archive - you have to extract it first, instead of just renaming the archive file.

@igrr igrr added this to the 2.0.0 milestone Nov 5, 2015

@jwschull

This comment has been minimized.

Copy link

jwschull commented Nov 10, 2015

Got a couple issues... NOTE: I'm using the build from 11/10 (1.6.7)

  1. Getting this error:Invalid library found in C:\Users\JerryHB\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\1.6.5-947-g39819f0\libraries\esp8266: C:\Users\JerryHB\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\1.6.5-947-g39819f0\libraries\esp8266

If I go there (i.e."C:\Users\JerryHB\AppData\Local\Arduino15\packages\esp8266\hardware\esp8266\1.6.5-947-g39819f0\libraries\esp8266") I see only 1 directory "Examples" and Nothing else. No library.

  1. per nabkey's suggestion I extracted the archive and replaced it. (i.e. "C:\Users\JerryHB\AppData\Local\Arduino15\packages\esp8266\tools\xtensa-lx106-elf-gcc\1.20.0-26-gb404fb9\xtensa-lx106-elf\lib" The file libm.a went from 2202KB -> 1027K.

It now compiles, But I'm still getting the error #1 above and a warning (i.e. "Warning: platform.txt from core 'ESP8266 Modules' contains deprecated recipe.ar.pattern="{compiler.path}{compiler.ar.cmd}" {compiler.ar.flags} {compiler.ar.extra_flags} "{build.path}/{archive_file}" "{object_file}", automatically converted to recipe.ar.pattern="{compiler.path}{compiler.ar.cmd}" {compiler.ar.flags} {compiler.ar.extra_flags} "{archive_file_path}" "{object_file}". Consider upgrading this core.")

@homerruma

This comment has been minimized.

Copy link

homerruma commented Nov 12, 2015

@krulkip
Thanks, whit your lib there is no problem

@Hopperpop

This comment has been minimized.

Copy link

Hopperpop commented Nov 12, 2015

The lib from krulkip works for all functions I need, except "fmod". It gives this error:

c:/users/xxx/appdata/roaming/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9-2/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-e_fmod.o):(.literal+0x4): undefined reference to __ieee754_remainder' c:/users/xxx/appdata/roaming/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9-2/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-e_fmod.o): In function__ieee754_fmod':
e_fmod.c:(.text+0x48): undefined reference to `__ieee754_remainder'
collect2.exe: error: ld returned 1 exit status

@igrr igrr removed this from the 2.1.0 milestone Feb 27, 2016

@igrr igrr modified the milestones: 2.2.0, 2.3.0 Apr 18, 2016

igrr added a commit to igrr/newlib-xtensa that referenced this issue Apr 19, 2016

igrr added a commit to igrr/newlib-xtensa that referenced this issue Apr 19, 2016

@igrr

This comment has been minimized.

Copy link
Member

igrr commented Apr 19, 2016

#1752 addresses fmod issue.

@igrr igrr modified the milestones: 2.3.0, 2.4.0 Jun 3, 2016

igrr added a commit that referenced this issue Jun 23, 2016

@umarjunaid

This comment has been minimized.

Copy link

umarjunaid commented Jun 29, 2016

Thanks to @krulkip and aniston for there comments which solve my problem

@krulkip said:
This seems to refer to a fix for this issue, but not sure how to try
jcmvbkbc/crosstool-NG@b404fb9

aniston said:
Just to confirm, changing the libm.a with the link supplied by Krulkip and the error with - undefined reference to `__ieee754_sqrt' is no more, code compiles and works.

I had to change the file in this folder ::
C:\Users\aniston\AppData\Roaming\Arduino15\packages\esp8266\tools\xtensa-lx106-elf-gcc\1.20.0-26-gb404fb9\xtensa-lx106-elf\lib

Arduino: 1.6.5 (Windows 7 x64), Generic ESP8266 Module, Serial, 80 MHz, 40MHz, DIO, 115200, 512K (64K SPIFFS)

@umarjunaid

This comment has been minimized.

Copy link

umarjunaid commented Jun 29, 2016

sorry

@krulkip said:
I installed this libm.a file replacing the xisting one in 1.20.0-26-gb404fb9/xtensa-lx106-elf/lib/ and the error was solved.
https://files.gitter.im/esp8266/Arduino/Abqa/libm.a.tbz

@anilkunchalaece

This comment has been minimized.

Copy link

anilkunchalaece commented Aug 11, 2016

i am Facing the Error
`

c:/users/med/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9-2/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-e_fmod.o):(.literal+0x0): undefined reference to `__ieee754_remainder'

c:/users/med/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9-2/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-e_fmod.o): In function `__ieee754_fmod':

e_fmod.c:(.text+0x48): undefined reference to `__ieee754_remainder'

collect2.exe: error: ld returned 1 exit status

exit status 1
Error compiling for board NodeMCU 1.0 (ESP-12E Module).`

I Did replace the file libm.a
But I am facing the Same Error.

I am Trying to use the Adafruit Ultimate Gps Library with NodeMCU

@dkgrieshammer

This comment has been minimized.

Copy link

dkgrieshammer commented Aug 12, 2016

thanks Hopperpop, thats it :)

@kjhulin

This comment has been minimized.

Copy link

kjhulin commented Apr 15, 2017

I am having this same error, using Adafruit Ultimate GPS library with the ESP8266WiFi

Using Arduino 1.8.2 on Windows 10; using Adafruit GPS Library 1.0.2.

I've attempted to replace libm.a as suggested above, but still see the following compile-time error:

"C:\Users\Kevin\Documents\ArduinoData\packages\esp8266\tools\xtensa-lx106-elf-gcc\1.20.0-26-gb404fb9-2/bin/xtensa-lx106-elf-gcc" -g -w -Os -nostdlib -Wl,--no-check-sections -u call_user_start -Wl,-static "-LC:\Users\Kevin\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.3.0/tools/sdk/lib" "-LC:\Users\Kevin\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.3.0/tools/sdk/ld" "-Teagle.flash.4m.ld" -Wl,--gc-sections -Wl,-wrap,system_restart_local -Wl,-wrap,register_chipv6_phy -o "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862/sketch_mar30a.ino.elf" -Wl,--start-group "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862\sketch\sketch_mar30a.ino.cpp.o" "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862\libraries\ESP8266WiFi\ESP8266WiFi.cpp.o" "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862\libraries\ESP8266WiFi\ESP8266WiFiAP.cpp.o" "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862\libraries\ESP8266WiFi\ESP8266WiFiGeneric.cpp.o" "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862\libraries\ESP8266WiFi\ESP8266WiFiMulti.cpp.o" "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862\libraries\ESP8266WiFi\ESP8266WiFiSTA.cpp.o" "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862\libraries\ESP8266WiFi\ESP8266WiFiScan.cpp.o" "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862\libraries\ESP8266WiFi\WiFiClient.cpp.o" "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862\libraries\ESP8266WiFi\WiFiClientSecure.cpp.o" "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862\libraries\ESP8266WiFi\WiFiServer.cpp.o" "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862\libraries\ESP8266WiFi\WiFiUdp.cpp.o" "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862\libraries\Adafruit_MQTT_Library\Adafruit_MQTT.cpp.o" "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862\libraries\Adafruit_MQTT_Library\Adafruit_MQTT_Client.cpp.o" "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862\libraries\Adafruit_GPS-master\Adafruit_GPS.cpp.o" "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862\libraries\SPI\SPI.cpp.o" "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862\libraries\Wire\Wire.cpp.o" "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862\libraries\Adafruit_GFX_Library\glcdfont.c.o" "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862\libraries\Adafruit_GFX_Library\Adafruit_GFX.cpp.o" "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862\libraries\Adafruit_SSD1306\Adafruit_SSD1306.cpp.o" "C:\Users\Kevin\AppData\Local\Temp\arduino_build_258862/arduino.ar" -lm -lgcc -lhal -lphy -lpp -lnet80211 -lwpa -lcrypto -lmain -lwps -laxtls -lsmartconfig -lmesh -lwpa2 -llwip_gcc -lstdc++ -Wl,--end-group "-LC:\Users\Kevin\AppData\Local\Temp\arduino_build_258862" c:/users/kevin/documents/arduinodata/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9-2/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-e_fmod.o):(.literal+0x0): undefined reference to__ieee754_remainder'

c:/users/kevin/documents/arduinodata/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9-2/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-e_fmod.o): In function `__ieee754_fmod':

e_fmod.c:(.text+0x48): undefined reference to '__ieee754_remainder'

collect2.exe: error: ld returned 1 exit status

Using library ESP8266WiFi at version 1.0 in folder: C:\Users\Kevin\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.3.0\libraries\ESP8266WiFi
Using library Adafruit_MQTT_Library at version 0.17.0 in folder: C:\Users\Kevin\Documents\Arduino\libraries\Adafruit_MQTT_Library
Using library Adafruit_GPS-master at version 1.0.2 in folder: C:\Users\Kevin\Documents\Arduino\libraries\Adafruit_GPS-master
Using library SPI at version 1.0 in folder: C:\Users\Kevin\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.3.0\libraries\SPI
Using library Wire at version 1.0 in folder: C:\Users\Kevin\Documents\ArduinoData\packages\esp8266\hardware\esp8266\2.3.0\libraries\Wire
Using library Adafruit_GFX_Library at version 1.1.8 in folder: C:\Users\Kevin\Documents\Arduino\libraries\Adafruit_GFX_Library
Using library Adafruit_SSD1306 at version 1.1.2 in folder: C:\Users\Kevin\Documents\Arduino\libraries\Adafruit_SSD1306
exit status 1
Error compiling for board Adafruit HUZZAH ESP8266.
`

@igrr igrr referenced this issue May 8, 2017

Closed

xtensa error #3216

@mjs513

This comment has been minimized.

Copy link

mjs513 commented Dec 18, 2017

I am getting a similar error for fmod:
Archiving built core (caching) in: C:\Users\CYBERP~1\AppData\Local\Temp\arduino_cache_461718\core\core_esp8266_esp8266_generic_CpuFrequency_80,FlashFreq_40,FlashMode_dio,UploadSpeed_115200,FlashSize_512K64,ResetMethod_ck,Debug_Disabled,DebugLevel_None_____6f0ffaa82fb8685893767509385827e5.a c:/users/cyberpalin/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9-2/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-e_fmod.o):(.literal+0x0): undefined reference to __ieee754_remainder'

c:/users/cyberpalin/appdata/local/arduino15/packages/esp8266/tools/xtensa-lx106-elf-gcc/1.20.0-26-gb404fb9-2/bin/../lib/gcc/xtensa-lx106-elf/4.8.2/../../../../xtensa-lx106-elf/lib\libm.a(lib_a-e_fmod.o): In function `__ieee754_fmod':

e_fmod.c:(.text+0x48): undefined reference to `__ieee754_remainder'

collect2.exe: error: ld returned 1 exit status

exit status 1
Error compiling for board Generic ESP8266 Module.
`
I am IDE1.8.5, Windows 10, stable release 2.3.0. Is there an easy fix for this or do I have to wait for a new release?

Thanks
Mike

EDIT: Ok. Think I got my answer to this from xtensa error #3216 issue. Its only fixed in master branch?

@devyte

This comment has been minimized.

Copy link
Collaborator

devyte commented Dec 19, 2017

@mjs513 Staged for release means the issue was found before 2.3.0, and has been already fixed in master branch. So try latest git.

@KevinLod

This comment has been minimized.

Copy link

KevinLod commented May 11, 2018

@igrr
Im having a problem with my IDE
exec: "C:\Users\Doesn't matter\AppData\Local\Arduino15\packages\esp8266\tools\xtensa-lx106-elf-gcc\1.20.0-26-gb404fb9-2/bin/xtensa-lx106-elf-g++": file does not exist

would you please help me fixing this issue
I've tried many ways to fix it but i couldn't

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment