[Mesa-dev] [PATCH 1/4] mesa: Put extern "C" guards in renderbuffer.h.

Kenneth Graunke kenneth at whitecape.org
Tue Jan 29 00:36:34 PST 2013


I need to use this from C++ code.

Signed-off-by: Kenneth Graunke <kenneth at whitecape.org>
---
 src/mesa/main/renderbuffer.h | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)

diff --git a/src/mesa/main/renderbuffer.h b/src/mesa/main/renderbuffer.h
index 5495ae1..c450b33 100644
--- a/src/mesa/main/renderbuffer.h
+++ b/src/mesa/main/renderbuffer.h
@@ -29,6 +29,10 @@
 #include "glheader.h"
 #include "mtypes.h"
 
+#ifdef __cplusplus
+extern "C" {
+#endif
+
 struct gl_context;
 struct gl_framebuffer;
 struct gl_renderbuffer;
@@ -62,6 +66,8 @@ _mesa_reference_renderbuffer(struct gl_renderbuffer **ptr,
       _mesa_reference_renderbuffer_(ptr, rb);
 }
       
-
+#ifdef __cplusplus
+}
+#endif
 
 #endif /* RENDERBUFFER_H */
-- 
1.8.1.2



More information about the mesa-dev mailing list