Subject: Re: mingw32 (egcs or not) math
From: [email-masked] (Mumit Khan)

31 Jul 1998 12:30:39 -0700
Message-ID: <[email-masked]>
References: <[email-masked]>
Mime-Version: 1.0
Content-Type: TEXT/PLAIN; charset=US-ASCII
To: Stephane Cateland <[email-masked]>
Cc: [email-masked]

On Wed, 29 Jul 1998, Stephane Cateland wrote:

> I have been trying to port some math stuff with native gcc.
> after fiddling with include math.h  I realised that at link stage some 
> math function are actually missing.
>  i noticed : rint    (not much important)
>                 cbrt   more annoying.
> (performed several nm -ao *.a | grep "function")
> is someone who knows the direct answer
> or would tell me where to find source code to build functional libm.a

There is really no "libm.a" for mingw32. It's just a stub for routines
exported by crtdll.dll, which is the MS-supplied runtime.

Now to answer you question, neither rint** nor cbrt*** are defined by
ANSI or POSIX standards; quite a few of the Unix runtime libraries do
provide it, but I've seen a few that do not. If you need it, you can
roll your own or get it from one of the freely available math libraries
such as newlib (it's bundled with Cygwin32 CDK distribution). You can
download just the newlib distribution from
ftp://ftp.cygnus.com/pub/newlib/.

Regards,
Mumit

** rint is specified by XPG4 

*** I believe that the "Future Library Directions" section of the ANSI C
standard does mention cbrt. It is still not standard. 

-
For help on using this list (especially unsubscribing), send a message to
"[email-masked]" with one line of text: "help".