sin, cos, tan, .. math functions in OpenAT 3.13

Hi everybody,

I’m using a Q24NG module and OpenAT v3.13, and I need to make use of some mathematical C functions such as sin, cos and others. I’m already including the math.h and stdlib.h headers in my program.

However, i always have a message “undefined reference to `sin’”, after compilation . Why ? Does anyone know ? Or if is necessary configure math functions (math lib …) ? How ?

thanks

In project wizard / wmnew script additional options add following lines:

-extlib C:/OpenAT/V313/IDE/GCC/4.0.1.0/arm-elf/lib/thumb/interwork 
-libname libm.a

Path info should reflect your installation. This will add correct entries to your .mak file in PATH_EXT_LIB and EXTERNAL_LIB_LIST entries.

Also, include math.h in source file.