Problem linking libm.a.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello!
I have tried to link the libm archive to get functions sqrt and pow needed in my program.
I did that after consulting gcc mail lists.
When doing this I get the error message "undefined reference to __errno" instead.


The message looks like this:
/usr/local/gcc-m68k/m68k-coff/lib/libm.a(w_sqrt.o): In function `sqrt':
/tmp/gcc-2.95.3/newlib/libm/math/w_sqrt.c:83: undefined reference to `__errno'
/tmp/gcc-2.95.3/newlib/libm/math/w_sqrt.c:86: undefined reference to `__errno'
/usr/local/gcc-m68k/m68k-coff/lib/libm.a(w_pow.o): In function `pow':
/tmp/gcc-2.95.3/newlib/libm/math/w_pow.c:100: undefined reference to `__errno'
/tmp/gcc-2.95.3/newlib/libm/math/w_pow.c:120: undefined reference to `__errno'
/tmp/gcc-2.95.3/newlib/libm/math/w_pow.c:138: undefined reference to `__errno'
/usr/local/gcc-m68k/m68k-coff/lib/libm.a(w_pow.o):/tmp/gcc-2.95.3/newlib/libm/math/w_pow.c:140:


My command line looks like this:
m68k-coff-ld --oformat=srec -T script1.ld -M -cref -lc -o $baseline$1$index$sre *.o -lm > $baseline$1$FASTC_index$map 2> _gcclink.logg


How do I get errno with me in the link? As you can see I tried som other libraries using l option
without success.


I'm using gcc 2.95.3 and GNU ld 2.11.

Could anyone please tell me what I missed in the mail lists or direct me somewhere.

Thanks beforehand.

Mikael

_________________________________________________________________
Chatt: Träffa nya nätkompisar på Habbo Hotel http://habbohotel.msn.se/habbo/sv/channelizer



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux