summaryrefslogtreecommitdiff
path: root/src/gallium/include/pipe/p_debug.h
diff options
context:
space:
mode:
authorJosé Fonseca <jrfonseca@tungstengraphics.com>2008-05-28 16:12:14 +0900
committerJosé Fonseca <jrfonseca@tungstengraphics.com>2008-05-28 16:13:24 +0900
commit55d29a8d48663982a1aeea414f69a5896b97d1ea (patch)
treebaac13009d92054ba1d597e9da81dc0c3cbc8e65 /src/gallium/include/pipe/p_debug.h
parent96a40345bb3b7c87d9742d0b5683355f42596823 (diff)
gallium: Windows CE portability fixes.
Diffstat (limited to 'src/gallium/include/pipe/p_debug.h')
-rw-r--r--src/gallium/include/pipe/p_debug.h11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/gallium/include/pipe/p_debug.h b/src/gallium/include/pipe/p_debug.h
index 0af635be57..05eca75201 100644
--- a/src/gallium/include/pipe/p_debug.h
+++ b/src/gallium/include/pipe/p_debug.h
@@ -59,6 +59,13 @@ extern "C" {
#endif
#endif
+
+/* MSVC bebore VC7 does not have the __FUNCTION__ macro */
+#if defined(_MSC_VER) && _MSC_VER < 1300
+#define __FUNCTION__ "???"
+#endif
+
+
void _debug_vprintf(const char *format, va_list ap);
@@ -127,8 +134,8 @@ void _debug_break(void);
#ifdef DEBUG
#if (defined(__i386__) || defined(__386__)) && defined(__GNUC__)
#define debug_break() __asm("int3")
-#elif (defined(__i386__) || defined(__386__)) && defined(__MSC__)
-#define debug_break() _asm {int 3}
+#elif defined(_M_IX86) && defined(_MSC_VER)
+#define debug_break() do { _asm {int 3} } while(0)
#else
#define debug_break() _debug_break()
#endif