warning fixes, aka don't redefine log2() et al. if already defined (Win32)

This commit is contained in:
gbeauche 2005-11-27 20:20:25 +00:00
parent c1c4345594
commit 90670c2652

View File

@ -64,9 +64,11 @@ extern "C" float exp2f(float x);
extern "C" double exp2(double x);
#define exp2f(x) (float)exp2(x)
#else
#ifndef exp2f
#define exp2f(x) powf(2.0, (x))
#endif
#endif
#endif
// 7.12.6.10 The log2 functions
#ifdef HAVE_LOG2F
@ -79,9 +81,11 @@ extern "C" double log2(double x);
#ifndef M_LN2
#define M_LN2 logf(2.0)
#endif
#ifndef log2f
#define log2f(x) logf(x) / M_LN2
#endif
#endif
#endif
// 7.12.9.1 The ceil functions
#ifdef HAVE_CEILF