From: <fr...@us...> - 2010-02-21 05:45:06
|
Revision: 4122 http://fuse-emulator.svn.sourceforge.net/fuse-emulator/?rev=4122&view=rev Author: fredm Date: 2010-02-21 05:45:00 +0000 (Sun, 21 Feb 2010) Log Message: ----------- Define M_LN2 for use with non C99 math.h (part of patch #2533274) (Simon Owen). Modified Paths: -------------- trunk/libspectrum/hacking/ChangeLog trunk/libspectrum/internals.h Modified: trunk/libspectrum/hacking/ChangeLog =================================================================== --- trunk/libspectrum/hacking/ChangeLog 2010-02-21 05:10:28 UTC (rev 4121) +++ trunk/libspectrum/hacking/ChangeLog 2010-02-21 05:45:00 UTC (rev 4122) @@ -761,3 +761,5 @@ of patch #2533274) (Simon Owen). 20100221 internals.h: define __func__ in MSVC (part of patch #2533274) (Simon Owen). +20100221 internals.h: define M_LN2 for use with non C99 math.h (part of patch + #2533274) (Simon Owen). Modified: trunk/libspectrum/internals.h =================================================================== --- trunk/libspectrum/internals.h 2010-02-21 05:10:28 UTC (rev 4121) +++ trunk/libspectrum/internals.h 2010-02-21 05:45:00 UTC (rev 4122) @@ -51,6 +51,12 @@ #endif /* _MSC_VER > 1200 */ #endif /* #ifdef _MSC_VER */ +/* VC6 lacks M_LN2, and VS2003+ require _USE_MATH_DEFINES defined before math.h + */ +#ifndef M_LN2 +#define M_LN2 0.693147180559945309417 +#endif + /* On Win32 systems, map snprintf -> _snprintf, strcasecmp -> _stricmp and strncasecmp -> _strnicmp */ #if !defined(HAVE_SNPRINTF) && defined(HAVE__SNPRINTF) This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |