I am trying to port some C code from Windows (i.e. no makefile) and I am using gcc for the first time. One of the files has some sin() and cos() calls in it. And yes it includes math.h. If I do a:
% gcc -o main main.c file1.c file2.c I get some error messages about not finding sin and cos. I assume I need to include some library that has sin/cos. I found the -l switch to pass libraries to the linker but I have no idea what library to use. Am I missing something obvious here? Any ideas? Thanks!!