Discuss here different C compiler set ups, and compiling executables for the ESP8266

User avatar
By Kevin Uhlir (N0BEL)
#15098 It is used by sqrt(), which in turn is used by pow(), which I'd like to use.

Just an fyi, sqrtf() and powf() work, because __ieee_sqrtf() is in there (the single precision float versions).

Just to see if its in a newer library, i've even looked at libm.a from the recently released Arduino build environment.

Any pointers are appreciated.

/Kevin
User avatar
By Kevin Uhlir (N0BEL)
#15132 Thank you. I was hoping to avoid a toolchain compile, since I've not done one yet, and been relying on provided libraries.

Anyone have a newer compile of the libraries done? Anyone have a pointer to it?

Any help is appreciated.

Thanks,
/Kevin
User avatar
By Kevin Uhlir (N0BEL)
#15231 I did go and pull crosstool-ng (https://github.com/jcmvbkbc/crosstool-NG) lx106-g++ branch, and did the compile and came up with a corrected libm.a, thanks!

Something else I did to the library, for my own purposes:
objcopy --rename-section .text=.irom0.text --rename-section .literal=.irom0.literal libm.a

This allows me to use every math function in my app, without overflowing the iram segment. YAY!

People say its slower, that may be, but I can get, for example, over 10,000 sin() calculations per second, which is well fast enough for what I'm working on.

/Kevin