summaryrefslogtreecommitdiff
path: root/include/GL
diff options
context:
space:
mode:
Diffstat (limited to 'include/GL')
-rw-r--r--include/GL/glut.h13
1 files changed, 10 insertions, 3 deletions
diff --git a/include/GL/glut.h b/include/GL/glut.h
index 45fed435492..a3add59a4f1 100644
--- a/include/GL/glut.h
+++ b/include/GL/glut.h
@@ -200,10 +200,17 @@ WGLAPI int GLAPIENTRY SetPixelFormat(HDC,int,const PIXELFORMATDESCRIPTOR *);
# pragma warning( pop )
#endif
-#else /* _WIN32 not defined */
+#elif defined(__GNUC__) && (__GNUC__ * 100 + __GNUC_MINOR__) >= 303
-/* Define GLUTAPIENTRY and GLUTCALLBACK to nothing if we aren't on Win32. */
-# define GLUTAPIENTRY GLAPIENTRY
+# define GLUTAPIENTRY
+# define GLUTAPIENTRYV
+# define GLUTCALLBACK
+# define GLUTAPI __attribute__((visibility("default")))
+
+#else
+
+/* Define GLUTAPIENTRY and GLUTCALLBACK to nothing */
+# define GLUTAPIENTRY
# define GLUTAPIENTRYV
# define GLUTCALLBACK
# define GLUTAPI extern