Today I was refreshing my little c knowledge, and I failed to compile simple app with
So why isn't acosf defined? (How to solve this correctly?)
EDIT:
fount it... heck I was missig -lm linker switch
I got math.h included. compiling with -std=c99. Why is it failing? I checked math.h source it hasundefined reference to `acosf`
Code:
/* float versions of ANSI/POSIX functions */
#if __ISO_C_VISIBLE >= 1999
float acosf(float);
...
So why isn't acosf defined? (How to solve this correctly?)
EDIT:
fount it... heck I was missig -lm linker switch