From: José Fonseca Date: Wed, 14 Jul 2010 15:15:56 +0000 (+0100) Subject: gallium: Ensure prototypes are wrapped in extern "C". X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=467928c6e01d66ea83d90df9903c2a8f0e675240;p=mesa.git gallium: Ensure prototypes are wrapped in extern "C". Fixes MSVC build failure due to inconsistent _ReadWriteBarrier prototype. --- diff --git a/src/gallium/include/pipe/p_compiler.h b/src/gallium/include/pipe/p_compiler.h index 619a62f8f14..0358c14e24b 100644 --- a/src/gallium/include/pipe/p_compiler.h +++ b/src/gallium/include/pipe/p_compiler.h @@ -60,6 +60,11 @@ #include +#ifdef __cplusplus +extern "C" { +#endif + + #if !defined(__HAIKU__) && !defined(__USE_MISC) typedef unsigned int uint; typedef unsigned short ushort; @@ -243,4 +248,10 @@ void _ReadWriteBarrier(void); #define unlikely(x) !!(x) #endif + +#if defined(__cplusplus) +} +#endif + + #endif /* P_COMPILER_H */