diff --git a/include/epoxy/gl.h b/include/epoxy/gl.h index 2b3bbaf..71f06ad 100644 --- a/include/epoxy/gl.h +++ b/include/epoxy/gl.h @@ -37,6 +37,10 @@ #ifndef __EPOXY_GL_H #define __EPOXY_GL_H +#ifdef __cplusplus +extern "C" { +#endif + #if defined(__gl_h_) || defined(__glext_h_) #error epoxy/gl.h must be included before (or in place of) GL/gl.h #else @@ -49,4 +53,8 @@ #include "epoxy/gl_generated.h" #include "epoxy/gl_generated_vtable_defines.h" +#ifdef __cplusplus +} /* extern "C" */ +#endif + #endif /* __EPOXY_GL_H */ diff --git a/include/epoxy/glx.h b/include/epoxy/glx.h index a583d7c..fa7077f 100644 --- a/include/epoxy/glx.h +++ b/include/epoxy/glx.h @@ -35,6 +35,10 @@ #ifndef __EPOXY_GLX_H #define __EPOXY_GLX_H +#ifdef __cplusplus +extern "C" { +#endif + #if defined(GLX_H) || defined(__glxext_h_) #error epoxy/glx.h must be included before (or in place of) GL/glx.h #else @@ -48,4 +52,8 @@ #include "epoxy/glx_generated.h" #include "epoxy/glx_generated_vtable_defines.h" +#ifdef __cplusplus +} /* extern "C" */ +#endif + #endif /* __EPOXY_GLX_H */