Location of sqrt for g++ compilation

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Location of sqrt for g++ compilation

Jeffrey Gitlin

When compiling with MINGW g++

where is the code for sqrt?  Is in libstdc++.a?


Years ago when you wanted to compile a program that used sqrt,

you had to type:

g++ prog.cpp -lm

to link against libm.a


Thanks for any reply.

    Jeff Gitlin


------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi
_______________________________________________
MinGW-users mailing list
[hidden email]

This list observes the Etiquette found at
http://www.mingw.org/Mailing_Lists.
We ask that you be polite and do the same.  Disregard for the list etiquette may cause your account to be moderated.

_______________________________________________
You may change your MinGW Account Options or unsubscribe at:
https://lists.sourceforge.net/lists/listinfo/mingw-users
Also: mailto:[hidden email]?subject=unsubscribe
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: Location of sqrt for g++ compilation

Eli Zaretskii
> From: Jeffrey Gitlin <[hidden email]>
> Date: Sat, 14 Jan 2017 18:22:35 +0000
>
> When compiling with MINGW g++
> where is the code for sqrt? Is in libstdc++.a?
>
> Years ago when you wanted to compile a program that used sqrt,
> you had to type:
>
> g++ prog.cpp -lm
>
> to link against libm.a

It will still work with MinGW, although you don't have to (math
functions are in the standard library, which is always linked in).

------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi
_______________________________________________
MinGW-users mailing list
[hidden email]

This list observes the Etiquette found at
http://www.mingw.org/Mailing_Lists.
We ask that you be polite and do the same.  Disregard for the list etiquette may cause your account to be moderated.

_______________________________________________
You may change your MinGW Account Options or unsubscribe at:
https://lists.sourceforge.net/lists/listinfo/mingw-users
Also: mailto:[hidden email]?subject=unsubscribe
Loading...