bootstrap/4037: Can't link C++ programs to Sun's libsunmath (regression vs. 2.95)
Wolfgang Bangerth
wolfgang.bangerth@iwr.uni-heidelberg.de
Mon Feb 25 08:58:00 GMT 2002
> Synopsis: Can't link C++ programs to Sun's libsunmath (regression vs. 2.95)
>
> State-Changed-From-To: open->closed
> State-Changed-By: rodrigc
> State-Changed-When: Sun Feb 24 07:32:10 2002
> State-Changed-Why:
> Those symbols are not defined in libsunmath.so.
>
> nm libsunmath.so | grep cos
>
> U __cos
>
> They are defined in libm.so, so you need to add:
> -libm -libsunmath
>
> to your link line.
For whatever reason, I did not need to link with libm with gcc2.95. The
problem has nevertheless gone away somehow, and I can again link as
previously, i.e. without -lm and everything works. Thanks anyway,
regards
Wolfgang
-------------------------------------------------------------------------
Wolfgang Bangerth email: wolfgang.bangerth@iwr.uni-heidelberg.de
www: http://gaia.iwr.uni-heidelberg.de/~wolf
More information about the Gcc-bugs
mailing list