We had reported a problem on 30 June 2005 regarding
failing to link math routines in msp430-gcc on Windows
platform.
We have not been able to get a solution to that
problem yet.
We subsequently installed msp430-gcc on Linux (FC3)
platform. We have the same problem that math routines
don't get linked. Can anyone help?
We are using msp430-gcc ver 3.4.2 on FC3. We could
complile source code successfully, but could not link
math library.
** The source code (main2.c) is below:
#include<msp430x14x.h>
#include<math.h>
main()
{
double num = 40.0;
double res;
res = sqrt(num);
}
** The command we tried:
$msp430-gcc -mmcu=msp430x149 -o main main2.c -lm
** The error message we got:
/tmp/cc4WCY3f.o(.text+0x1c): In function `main':
undefined reference to `sqrt'
Regards,
Guruprasad
_______________________________________________________
Too much spam in your inbox? Yahoo! Mail gives you the best spam protection for
FREE! http://in.mail.yahoo.com