diff options
author | Blue Swirl | 2012-04-15 21:56:06 +0200 |
---|---|---|
committer | Blue Swirl | 2012-04-15 21:56:06 +0200 |
commit | e6f5d0be730a41bacb10edba19d1369ec2949486 (patch) | |
tree | ecf6fded694c4409c16d953f36d6e68aca33de12 /qemu-os-win32.h | |
parent | target-alpha: QOM'ify CPU init (diff) | |
parent | w64: Fix time conversion for some versions of MinGW-w64 (diff) | |
download | qemu-e6f5d0be730a41bacb10edba19d1369ec2949486.tar.gz qemu-e6f5d0be730a41bacb10edba19d1369ec2949486.tar.xz qemu-e6f5d0be730a41bacb10edba19d1369ec2949486.zip |
Merge branch 'w64' of git://qemu.weilnetz.de/qemu
* 'w64' of git://qemu.weilnetz.de/qemu:
w64: Fix time conversion for some versions of MinGW-w64
nbd: Fix compiler warning (w64)
disas: Replace 'unsigned long' by 'uintptr_t'
cpu-exec: Remove non-portable type cast and fix format string
target-mips: Fix type cast for w64 (uintptr_t)
w64: Fix type cast in os_host_main_loop_wait
w64: Fix data types in softmmu*.h
w64: Use uintptr_t in exec.c
softmmu: Use uintptr_t for physaddr and rename it
w64: Fix struct CPUTLBEntry
w64: Fix definition of setjmp
w32: Move defines for socket specific errors to qemu-os-win32.h
w64: Use larger alignment for section with generated code
w64: Fix data types in cpu-all.h, exec.c
w64: Fix type casts used in some macros in cpu-all.h
tcg/i386: Add support for w64 ABI
tcg/i386: Use GDB JIT debugging interface only for hosts with ELF
Diffstat (limited to 'qemu-os-win32.h')
-rw-r--r-- | qemu-os-win32.h | 35 |
1 files changed, 35 insertions, 0 deletions
diff --git a/qemu-os-win32.h b/qemu-os-win32.h index 8eda4bdc20..753679b194 100644 --- a/qemu-os-win32.h +++ b/qemu-os-win32.h @@ -30,6 +30,41 @@ #include <winsock2.h> #include "main-loop.h" +/* Workaround for older versions of MinGW. */ +#ifndef ECONNREFUSED +# define ECONNREFUSED WSAECONNREFUSED +#endif +#ifndef EINPROGRESS +# define EINPROGRESS WSAEINPROGRESS +#endif +#ifndef EHOSTUNREACH +# define EHOSTUNREACH WSAEHOSTUNREACH +#endif +#ifndef EINTR +# define EINTR WSAEINTR +#endif +#ifndef EINPROGRESS +# define EINPROGRESS WSAEINPROGRESS +#endif +#ifndef ENETUNREACH +# define ENETUNREACH WSAENETUNREACH +#endif +#ifndef ENOTCONN +# define ENOTCONN WSAENOTCONN +#endif +#ifndef EWOULDBLOCK +# define EWOULDBLOCK WSAEWOULDBLOCK +#endif + +#if defined(_WIN64) +/* On w64, setjmp is implemented by _setjmp which needs a second parameter. + * If this parameter is NULL, longjump does no stack unwinding. + * That is what we need for QEMU. Passing the value of register rsp (default) + * lets longjmp try a stack unwinding which will crash with generated code. */ +# undef setjmp +# define setjmp(env) _setjmp(env, NULL) +#endif + /* Declaration of ffs() is missing in MinGW's strings.h. */ int ffs(int i); |