From 979bd1ec6122ff75551107fcad57de405eb6fa16 Mon Sep 17 00:00:00 2001 From: Yves Starreveld Date: Fri, 6 Sep 2002 14:03:47 -0400 Subject: ERR: Fix opengl finding on osx --- Modules/FindOpenGL.cmake | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/Modules/FindOpenGL.cmake b/Modules/FindOpenGL.cmake index aeaf519..026c214 100644 --- a/Modules/FindOpenGL.cmake +++ b/Modules/FindOpenGL.cmake @@ -140,6 +140,18 @@ IF(OPENGL_INCLUDE_DIR) ENDIF(OPENGL_INCLUDE_DIR) +# On OSX, OpenGL is always there - this will need refining for those using OpenGL with X11 +IF (APPLE) + SET (OPENGL_FOUND "YES") + SET (OPENGL_GLU_FOUND "YES") + SET (OPENGL_LIBRARIES "-framework AGL -framework OpenGL" CACHE STRING "OpenGL lib for OSX") + SET (OPENGL_LIBRARY ${OPENGL_LIBRARIES} CACHE STRING "OpenGL lib for OSX (for CMake 1.4)") + SET (OPENGL_gl_LIBRARY "-framework OpenGL" CACHE STRING "OpenGL lib for OSX") + SET (OPENGL_glu_LIBRARY "-framework AGL" CACHE STRING "AGL lib for OSX") +ENDIF (APPLE) + + + MARK_AS_ADVANCED( OPENGL_INCLUDE_DIR OPENGL_xmesa_INCLUDE_DIR -- cgit v0.12