From 0dc81367c3bbf97171df787ab9042d777d802ea4 Mon Sep 17 00:00:00 2001 From: Tatsuya Yatagawa Date: Fri, 5 Jun 2020 12:57:43 +0900 Subject: [PATCH] Fixed: GLFW_INCLUDE_GLU is not working related to issue #1695. --- include/GLFW/glfw3.h | 22 ++++++++++++++++------ 1 file changed, 16 insertions(+), 6 deletions(-) diff --git a/include/GLFW/glfw3.h b/include/GLFW/glfw3.h index 6db5b5798..ac9d3d68a 100644 --- a/include/GLFW/glfw3.h +++ b/include/GLFW/glfw3.h @@ -193,6 +193,22 @@ extern "C" { #endif /*__APPLE__*/ +#elif defined(GLFW_INCLUDE_GLU) + + #if defined(__APPLE__) + + #if defined(GLFW_INCLUDE_GLU) + #include + #endif + + #else /*__APPLE__*/ + + #if defined(GLFW_INCLUDE_GLU) + #include + #endif + + #endif /*__APPLE__*/ + #elif !defined(GLFW_INCLUDE_NONE) && \ !defined(__gl_h_) && \ !defined(__gles1_gl_h_) && \ @@ -216,9 +232,6 @@ extern "C" { #define GL_GLEXT_LEGACY #endif #include - #if defined(GLFW_INCLUDE_GLU) - #include - #endif #else /*__APPLE__*/ @@ -226,9 +239,6 @@ extern "C" { #if defined(GLFW_INCLUDE_GLEXT) #include #endif - #if defined(GLFW_INCLUDE_GLU) - #include - #endif #endif /*__APPLE__*/