From 3f129ff6e53618d5d03ac5060f3c2351b94955d6 Mon Sep 17 00:00:00 2001 From: Arthur O'Dwyer Date: Sun, 16 Feb 2020 10:10:50 -0500 Subject: [PATCH] Define `GL_SILENCE_DEPRECATION` on OSX. This is gross and inexplicable, but Xcode now spews warnings whenever you use any part of OpenGL on Mac. https://www.reddit.com/r/opengl/comments/b44tyu/apple_is_deprecating_opengl/ https://www.reddit.com/r/opengl/comments/8okcf1/opengl_deprecated_in_macos_1014/ Fortunately the workaround for now is to just suppress the warnings. In file included from hyper.cpp:26: ./glhr.cpp:21:20: error: 'glGetError' is deprecated: first deprecated in macOS 10.14 - OpenGL API deprecated. (Define GL_SILENCE_DEPRECATION to silence these warnings) [-Werror,-Wdeprecated-declarations] GLenum errCode = glGetError(); ^ --- sysconfig.h | 1 + 1 file changed, 1 insertion(+) diff --git a/sysconfig.h b/sysconfig.h index d8e0bd8e..1f375f33 100644 --- a/sysconfig.h +++ b/sysconfig.h @@ -389,6 +389,7 @@ extern "C" { #else #define GL_GLEXT_PROTOTYPES 1 #if ISMAC + #define GL_SILENCE_DEPRECATION 1 #include #include #include