OESF Portables Forum

Model Specific Forums => Sharp Zaurus => Zaurus - pdaXrom => Topic started by: omega on November 03, 2004, 01:30:13 pm

Title: sin function for gcc in pdaxrom?
Post by: omega on November 03, 2004, 01:30:13 pm
Hi,

I'm writing some DSP stuff in C and i found trouble trying to get sin / cos functions... any advice? i tried including math.h and tgmath.h...
Title: sin function for gcc in pdaxrom?
Post by: blakeyez on November 03, 2004, 03:03:32 pm
I'm able to build this:

Code: [Select]
#include
#include

int main(void)
{
  printf("sin(%f) = %f\n", 1.0, sin(1.0));
  return 0;
}

like this:

Code: [Select]
$ gcc -o sintest sintest.c -lm
and it works fine here.

Dave
Title: sin function for gcc in pdaxrom?
Post by: omega on November 04, 2004, 06:53:34 am
score! thank you very much, the -lm did it...