From c06c131d79abaea87bc97548163c5fd9ac39e119 Mon Sep 17 00:00:00 2001 From: José Fonseca Date: Fri, 15 Jul 2011 16:08:28 +0100 Subject: Don't depend on glut to get proc addresses on MacOSX. dlsym() is all one needs. --- src/glean/glutils.cpp | 4 ++-- src/glh/glwrap.h | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/src/glean/glutils.cpp b/src/glean/glutils.cpp index 2c8ab60..70cf0cc 100644 --- a/src/glean/glutils.cpp +++ b/src/glean/glutils.cpp @@ -37,7 +37,7 @@ #include "environ.h" #include "lex.h" #include "glutils.h" -#if defined(__X11__) +#if defined(__X11__) || defined(__AGL__) # include #endif #if defined(__AGL__) @@ -141,7 +141,7 @@ void # error "Need GetProcAddress (or equivalent) for BeOS" return 0; #elif defined(__AGL__) - return reinterpret_cast(glutGetProcAddress(name)); + return reinterpret_cast(dlsym(RTLD_DEFAULT, name)); #endif } // getProcAddress diff --git a/src/glh/glwrap.h b/src/glh/glwrap.h index 8463eb3..91e5d48 100644 --- a/src/glh/glwrap.h +++ b/src/glh/glwrap.h @@ -74,7 +74,6 @@ # include # include # include -# include # include # include # if !defined(APIENTRY) -- cgit v1.2.3