From 94aba23ef45d4faadb9d1657a2707f6721eca48d Mon Sep 17 00:00:00 2001 From: Peter0x44 Date: Thu, 23 Nov 2023 23:41:44 +0000 Subject: [PATCH] Expose glad functions when building raylib as a shared lib (#3572) --- src/rlgl.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/rlgl.h b/src/rlgl.h index 2c5c3e3f3..27cfaa0d0 100644 --- a/src/rlgl.h +++ b/src/rlgl.h @@ -773,6 +773,11 @@ RLAPI void rlLoadDrawQuad(void); // Load and draw a quad #if defined(RLGL_IMPLEMENTATION) +// Expose OpenGL functions from glad in raylib +#if defined(BUILD_SHARED_LIBS) + #define GLAD_API_CALL_EXPORT_BUILD +#endif + #if defined(GRAPHICS_API_OPENGL_11) #if defined(__APPLE__) #include // OpenGL 1.1 library for OSX