summaryrefslogtreecommitdiff
path: root/include/u.h
diff options
context:
space:
mode:
authorHector Chu <hectorchu@gmail.com>2009-11-30 11:53:11 -0800
committerHector Chu <hectorchu@gmail.com>2009-11-30 11:53:11 -0800
commit8eabe8208c32050802c06abdc2baf49febf6fb7a (patch)
tree7ac62e529fdf4675e7449e7171ed7cc0a573e517 /include/u.h
parent2c880cf84880cfac9c667f48087c7c30d19b76ba (diff)
downloadgolang-8eabe8208c32050802c06abdc2baf49febf6fb7a.tar.gz
Ports of lib9, libbio and libmach to Windows.
R=rsc http://codereview.appspot.com/157159 Committer: Russ Cox <rsc@golang.org>
Diffstat (limited to 'include/u.h')
-rw-r--r--include/u.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/include/u.h b/include/u.h
index 1b196286e..6dd55a09c 100644
--- a/include/u.h
+++ b/include/u.h
@@ -77,6 +77,9 @@ extern "C" {
#define _NEEDUINT 1
#define _NEEDULONG 1
+#ifdef __MINGW32__
+typedef jmp_buf sigjmp_buf;
+#endif
typedef long p9jmp_buf[sizeof(sigjmp_buf)/sizeof(long)];
#if defined(__linux__)
@@ -135,6 +138,7 @@ typedef long p9jmp_buf[sizeof(sigjmp_buf)/sizeof(long)];
# undef _NEEDUSHORT
# undef _NEEDUINT
# undef _NEEDULONG
+#elif defined(__MINGW32__)
#else
/* No idea what system this is -- try some defaults */
# include <pthread.h>
@@ -199,7 +203,7 @@ typedef u64int uint64;
*/
#if defined(__GNUC__)
# undef strcmp /* causes way too many warnings */
-# if __GNUC__ >= 4 || (__GNUC__==3 && !defined(__APPLE_CC__))
+# if __GNUC__ >= 4 || (__GNUC__==3 && !defined(__APPLE_CC__) && !defined(__MINGW32__))
# undef AUTOLIB
# define AUTOLIB(x) int __p9l_autolib_ ## x __attribute__ ((weak));
# undef AUTOFRAMEWORK