FreeBSD fix.

This commit is contained in:
curt 2004-11-20 19:11:08 +00:00
parent a52b1ec64f
commit 84cba33aab
2 changed files with 5 additions and 4 deletions

View File

@ -21,15 +21,13 @@
// #include <stdio.h>
#include <math.h>
#if defined (__APPLE__)
#if defined (__APPLE__) || defined (__FreeBSD__)
// any C++ header file undefines isinf and isnan
// so this should be included before <iostream>
inline int (isinf)(double r) { return isinf(r); }
inline int (isnan)(double r) { return isnan(r); }
#endif
// #include STL_IOSTREAM
#include <plib/sg.h>
#include <plib/ssg.h>
@ -634,7 +632,6 @@ bool SGCloudLayer::repaint( sgVec3 fog_color ) {
return true;
}
// reposition the cloud layer at the specified origin and orientation
// lon specifies a rotation about the Z axis
// lat specifies a rotation about the new Y axis

View File

@ -113,7 +113,11 @@ void *SGGetGLProcAddress(const char *func) {
if (libHandle != NULL) {
fptr = dlsym(libHandle, func);
#if defined (__FreeBSD__)
const char *error = dlerror();
#else
char *error = dlerror();
#endif
if (error)
SG_LOG(SG_GENERAL, SG_INFO, error);
}