summaryrefslogtreecommitdiff
path: root/src/egl/main/eglcompiler.h
diff options
context:
space:
mode:
authorChia-I Wu <olvaffe@gmail.com>2009-07-16 21:21:51 -0700
committerBrian Paul <brianp@vmware.com>2009-07-17 11:36:45 -0600
commit8e92ec9fdd58bdfcdef65a995988974d3266b9ad (patch)
treeb19cdfa71f5825eb051d8328b53a3a294ae78325 /src/egl/main/eglcompiler.h
parent9cea84b6b5f96bf3bb42546e49b76024d7126e30 (diff)
egl: Add eglcompiler.h for compiler features.
Only INLINE (from mesa/main/compiler.h) is defined now. It may be used to deal with symbol visibility and int/pointer conversion in the future. Signed-off-by: Chia-I Wu <olvaffe@gmail.com> Signed-off-by: Brian Paul <brianp@vmware.com>
Diffstat (limited to 'src/egl/main/eglcompiler.h')
-rw-r--r--src/egl/main/eglcompiler.h31
1 files changed, 31 insertions, 0 deletions
diff --git a/src/egl/main/eglcompiler.h b/src/egl/main/eglcompiler.h
new file mode 100644
index 0000000000..0b19afedfd
--- /dev/null
+++ b/src/egl/main/eglcompiler.h
@@ -0,0 +1,31 @@
+#ifndef EGLCOMPILER_INCLUDED
+#define EGLCOMPILER_INCLUDED
+
+
+/**
+ * Function inlining
+ */
+#if defined(__GNUC__)
+# define INLINE __inline__
+#elif defined(__MSC__)
+# define INLINE __inline
+#elif defined(_MSC_VER)
+# define INLINE __inline
+#elif defined(__ICL)
+# define INLINE __inline
+#elif defined(__INTEL_COMPILER)
+# define INLINE inline
+#elif defined(__WATCOMC__) && (__WATCOMC__ >= 1100)
+# define INLINE __inline
+#elif defined(__SUNPRO_C) && defined(__C99FEATURES__)
+# define INLINE inline
+# define __inline inline
+# define __inline__ inline
+#elif (__STDC_VERSION__ >= 199901L) /* C99 */
+# define INLINE inline
+#else
+# define INLINE
+#endif
+
+
+#endif /* EGLCOMPILER_INCLUDED */