[Scummvm-cvs-logs] SF.net SVN: scummvm: [30972] scummvm/trunk/sound/softsynth/mt32
fingolfin at users.sourceforge.net
fingolfin at users.sourceforge.net
Tue Feb 26 18:03:11 CET 2008
Revision: 30972
http://scummvm.svn.sourceforge.net/scummvm/?rev=30972&view=rev
Author: fingolfin
Date: 2008-02-26 09:03:10 -0800 (Tue, 26 Feb 2008)
Log Message:
-----------
Completed fix for bug #1523129 (SOLARIS: solaris 8 build broken)
Modified Paths:
--------------
scummvm/trunk/sound/softsynth/mt32/partial.cpp
scummvm/trunk/sound/softsynth/mt32/synth.cpp
scummvm/trunk/sound/softsynth/mt32/tables.cpp
Modified: scummvm/trunk/sound/softsynth/mt32/partial.cpp
===================================================================
--- scummvm/trunk/sound/softsynth/mt32/partial.cpp 2008-02-26 16:55:58 UTC (rev 30971)
+++ scummvm/trunk/sound/softsynth/mt32/partial.cpp 2008-02-26 17:03:10 UTC (rev 30972)
@@ -25,11 +25,16 @@
#include "mt32emu.h"
-#ifdef MACOSX
-// Older versions of Mac OS X didn't supply a powf function. To ensure
-// binary compatibility, we force using pow instead of powf (the only
-// potential drawback is that it might be a little bit slower).
+#if defined(MACOSX) || defined(__solaris__)
+// Older versions of Mac OS X didn't supply a powf function, so using it
+// will cause a binary incompatibility when trying to run a binary built
+// on a newer OS X release on an olderr one. And Solaris 8 doesn't provide
+// powf, floorf, fabsf etc. at all.
+// Hence we re-define them here. The only potential drawback is that it
+// might be a little bit slower this way.
#define powf pow
+#define floorf floor
+#define fabsf fabs
#endif
#define FIXEDPOINT_UDIV(x, y, point) (((x) << (point)) / ((y)))
Modified: scummvm/trunk/sound/softsynth/mt32/synth.cpp
===================================================================
--- scummvm/trunk/sound/softsynth/mt32/synth.cpp 2008-02-26 16:55:58 UTC (rev 30971)
+++ scummvm/trunk/sound/softsynth/mt32/synth.cpp 2008-02-26 17:03:10 UTC (rev 30972)
@@ -25,11 +25,16 @@
#include "mt32emu.h"
-#ifdef MACOSX
-// Older versions of Mac OS X didn't supply a powf function. To ensure
-// binary compatibility, we force using pow instead of powf (the only
-// potential drawback is that it might be a little bit slower).
+#if defined(MACOSX) || defined(__solaris__)
+// Older versions of Mac OS X didn't supply a powf function, so using it
+// will cause a binary incompatibility when trying to run a binary built
+// on a newer OS X release on an olderr one. And Solaris 8 doesn't provide
+// powf, floorf, fabsf etc. at all.
+// Hence we re-define them here. The only potential drawback is that it
+// might be a little bit slower this way.
#define powf pow
+#define floorf floor
+#define fabsf fabs
#endif
namespace MT32Emu {
Modified: scummvm/trunk/sound/softsynth/mt32/tables.cpp
===================================================================
--- scummvm/trunk/sound/softsynth/mt32/tables.cpp 2008-02-26 16:55:58 UTC (rev 30971)
+++ scummvm/trunk/sound/softsynth/mt32/tables.cpp 2008-02-26 17:03:10 UTC (rev 30972)
@@ -25,11 +25,16 @@
#include "mt32emu.h"
-#ifdef MACOSX
-// Older versions of Mac OS X didn't supply a powf function. To ensure
-// binary compatibility, we force using pow instead of powf (the only
-// potential drawback is that it might be a little bit slower).
+#if defined(MACOSX) || defined(__solaris__)
+// Older versions of Mac OS X didn't supply a powf function, so using it
+// will cause a binary incompatibility when trying to run a binary built
+// on a newer OS X release on an olderr one. And Solaris 8 doesn't provide
+// powf, floorf, fabsf etc. at all.
+// Hence we re-define them here. The only potential drawback is that it
+// might be a little bit slower this way.
#define powf pow
+#define floorf floor
+#define fabsf fabs
#endif
#define FIXEDPOINT_MAKE(x, point) ((Bit32u)((1 << point) * x))
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list