Re: [Flightgear-devel] MSVC 6.0 Problem with systems/vacuum/vacuum.cxx
Richard Bytheway writes: > I changed my copy to use min() rather than fmin() (W2K, cygwin, gcc version 2.95.3-5 (cygwin special)). > Builds, links, and appears to run OK. Yes that works, however it would be nice to be able to use the (f) version of the common math functions when they are available in that they **maybe** faster depending on the machine compiler combination. AFAIK This was part of the rationale behind their addition to the C99 standard Cheers Norman > > -Original Message- > > From: Bernie Bright [mailto:[EMAIL PROTECTED]] > > Sent: 24 September 2002 10:34 am > > To: [EMAIL PROTECTED] > > Subject: Re: [Flightgear-devel] MSVC 6.0 Problem with > > systems/vacuum/vacuum.cxx > > > > > > On Tue, 24 Sep 2002 03:46:54 -0400 > > "Norman Vine" <[EMAIL PROTECTED]> wrote: > > > > > Bernie Bright writes: > > > > > > > On Mon, 23 Sep 2002 18:51:25 -0700 > > > > Jonathan Polley <[EMAIL PROTECTED]> wrote: > > > > > > > > > MSVC does not have fmin() defined, so complains in vacuum.cxx. > > > > > > > > > > > > > gcc 2.95.3 complains too. fmin() is only defined if > > _ISOC99_SOURCE is > > > defined before including . > > > > > > I wonder if we are going to need a sg_math.h > > > if so here is a first stab at one > > > > > [cut] > > > > Well, as far as I can tell, fmin() is C99 not Std C++. We > > could use std::min() but that causes a problem with MSVC > > where you have to use cpp_min() instead. And so it goes on... > > > > Bernie > > > > > > ___ > Flightgear-devel mailing list > [EMAIL PROTECTED] > http://mail.flightgear.org/mailman/listinfo/flightgear-devel > ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel
Re: [Flightgear-devel] MSVC 6.0 Problem with systems/vacuum/vacuum.cxx
Bernie Bright writes: > Well, as far as I can tell, fmin() is C99 not Std C++. We could > use std::min() but that causes a problem with MSVC where you have > to use cpp_min() instead. And so it goes on... My fault -- I didn't realize that fmin() was non-ANSI. I've fixed it in the CVS (in advance of integration of Alex's vacuum model from steam.cxx). All the best, David -- David Megginson, [EMAIL PROTECTED], http://www.megginson.com/ ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel
RE: [Flightgear-devel] MSVC 6.0 Problem with systems/vacuum/vacuum.cxx
I changed my copy to use min() rather than fmin() (W2K, cygwin, gcc version 2.95.3-5 (cygwin special)). Builds, links, and appears to run OK. Richard > -Original Message- > From: Bernie Bright [mailto:[EMAIL PROTECTED]] > Sent: 24 September 2002 10:34 am > To: [EMAIL PROTECTED] > Subject: Re: [Flightgear-devel] MSVC 6.0 Problem with > systems/vacuum/vacuum.cxx > > > On Tue, 24 Sep 2002 03:46:54 -0400 > "Norman Vine" <[EMAIL PROTECTED]> wrote: > > > Bernie Bright writes: > > > > > On Mon, 23 Sep 2002 18:51:25 -0700 > > > Jonathan Polley <[EMAIL PROTECTED]> wrote: > > > > > > > MSVC does not have fmin() defined, so complains in vacuum.cxx. > > > > > > > > > > gcc 2.95.3 complains too. fmin() is only defined if > _ISOC99_SOURCE is > > defined before including . > > > > I wonder if we are going to need a sg_math.h > > if so here is a first stab at one > > > [cut] > > Well, as far as I can tell, fmin() is C99 not Std C++. We > could use std::min() but that causes a problem with MSVC > where you have to use cpp_min() instead. And so it goes on... > > Bernie > > ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel
Re: [Flightgear-devel] MSVC 6.0 Problem with systems/vacuum/vacuum.cxx
On Tue, 24 Sep 2002 03:46:54 -0400 "Norman Vine" <[EMAIL PROTECTED]> wrote: > Bernie Bright writes: > > > On Mon, 23 Sep 2002 18:51:25 -0700 > > Jonathan Polley <[EMAIL PROTECTED]> wrote: > > > > > MSVC does not have fmin() defined, so complains in vacuum.cxx. > > > > > > > gcc 2.95.3 complains too. fmin() is only defined if _ISOC99_SOURCE is > defined before including . > > I wonder if we are going to need a sg_math.h > if so here is a first stab at one > [cut] Well, as far as I can tell, fmin() is C99 not Std C++. We could use std::min() but that causes a problem with MSVC where you have to use cpp_min() instead. And so it goes on... Bernie ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel
Re: [Flightgear-devel] MSVC 6.0 Problem with systems/vacuum/vacuum.cxx
Bernie Bright writes: > On Mon, 23 Sep 2002 18:51:25 -0700 > Jonathan Polley <[EMAIL PROTECTED]> wrote: > > > MSVC does not have fmin() defined, so complains in vacuum.cxx. > > > > gcc 2.95.3 complains too. fmin() is only defined if _ISOC99_SOURCE is defined before including . I wonder if we are going to need a sg_math.h if so here is a first stab at one cut #ifndef __SG_MATH #define __SG_MATH #include #if defined(_MSC_VER) && (_MSC_VER >= 1300) #include #endif #if (defined(WIN32) && !(defined(_MSC_VER) && (_MSC_VER >= 1300)) ) || \ defined (macintosh)|| \ defined (sun) || \ defined (__DARWIN_OSX__) #include #ifndef acosf #define acosf (float)acos #endif #ifndef asinf #define asinf (float)asin #endif #ifndef cosf #define cosf (float)cos #endif #ifndef sinf #define sinf (float)sin #endif #ifndef logf #define logf (float)log #endif #ifndef powf #define powf (float)pow #endif #ifndef sqrtf #define sqrtf (float)sqrt #endif #ifndef fabsf #define fabsf (float)fabs #endif #ifndef isnanf #define isnanf (float)isnan #endif #endif #if (defined(WIN32) && !(defined(_MSC_VER) && (_MSC_VER >= 1300)) ) || \ defined (macintosh)|| \ defined (sun) || \ defined (__DARWIN_OSX__) ||\ defined (__hpux__) #ifndef floorf #define floorf (float)floor #endif #endif #endif // __SG_MATH ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel
Re: [Flightgear-devel] MSVC 6.0 Problem with systems/vacuum/vacuum.cxx
From: "Curtis L. Olson" <[EMAIL PROTECTED]> > Jonathan Polley writes: > > MSVC does not have fmin() defined, so complains in vacuum.cxx. > > gcc-2.95 is also complaining about it missing. Same for MSVC 7. Cheers, -Fred ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel
Re: [Flightgear-devel] MSVC 6.0 Problem with systems/vacuum/vacuum.cxx
On Mon, 23 Sep 2002 18:51:25 -0700 Jonathan Polley <[EMAIL PROTECTED]> wrote: > MSVC does not have fmin() defined, so complains in vacuum.cxx. > gcc 2.95.3 complains too. fmin() is only defined if _ISOC99_SOURCE is defined before including . Bernie ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel
Re: [Flightgear-devel] MSVC 6.0 Problem with systems/vacuum/vacuum.cxx
Jonathan Polley writes: > MSVC does not have fmin() defined, so complains in vacuum.cxx. gcc-2.95 is also complaining about it missing. Curt. -- Curtis Olson IVLab / HumanFIRST Program FlightGear Project Twin Cities[EMAIL PROTECTED] [EMAIL PROTECTED] Minnesota http://www.menet.umn.edu/~curt http://www.flightgear.org ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel
[Flightgear-devel] MSVC 6.0 Problem with systems/vacuum/vacuum.cxx
MSVC does not have fmin() defined, so complains in vacuum.cxx. Thanks, Jonthan Polley Of COURSE they can do that. They're engineers! ___ Flightgear-devel mailing list [EMAIL PROTECTED] http://mail.flightgear.org/mailman/listinfo/flightgear-devel