[Spice-devel] [PATCH spice-protocol] macros: define INLINE

Arnon Gilboa agilboa at redhat.com
Thu May 12 01:49:38 PDT 2011


needed for spice/common files used by the client, server & qxl driver.
in windows _inline works for both c/c++, while inline is c++ only.
compiling the client with mixed c/c++ code required this define.
---
 spice/macros.h |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)

diff --git a/spice/macros.h b/spice/macros.h
index 62157b4..78538a5 100644
--- a/spice/macros.h
+++ b/spice/macros.h
@@ -101,6 +101,12 @@
 # define SPICE_END_DECLS
 #endif
 
+#ifdef __GNUC__
+#define INLINE inline
+#else
+#define INLINE _inline
+#endif /* __GNUC__ */
+
 #ifndef	FALSE
 #define	FALSE	(0)
 #endif
-- 
1.7.4.1



More information about the Spice-devel mailing list