diff options
author | Paolo Bonzini | 2016-02-09 15:16:57 +0100 |
---|---|---|
committer | Michael Tokarev | 2016-02-11 13:15:47 +0100 |
commit | 1834ed3afc578b8dbf39838cfdf27d457771a334 (patch) | |
tree | 10fceee8af46217b8ffc0993aa034485f61e2684 /include/sysemu/os-win32.h | |
parent | Adds keycode 86 to the hid_usage_keys translation table. (diff) | |
download | qemu-1834ed3afc578b8dbf39838cfdf27d457771a334.tar.gz qemu-1834ed3afc578b8dbf39838cfdf27d457771a334.tar.xz qemu-1834ed3afc578b8dbf39838cfdf27d457771a334.zip |
w32: include winsock2.h before windows.h
Recent Fedora complains while compiling ui/sdl.c:
/usr/x86_64-w64-mingw32/sys-root/mingw/include/winsock2.h:15:2: warning: #warning Please include winsock2.h before windows.h [-Wcpp]
And with this patch we dutifully obey.
Stefan Weil:
Without that patch, windows.h will include winsock.h
(which conflicts with winsock2.h) when compiling sdl.c.
Normally we define WIN32_LEAN_AND_MEAN, and
windows.h won't include winsock.h.
include/ui/sdl2.h and ui/sdl.c undefine that macro,
so the order of the include files is important.
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Stefan Weil <sw@weilnetz.de>
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
Diffstat (limited to 'include/sysemu/os-win32.h')
-rw-r--r-- | include/sysemu/os-win32.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/sysemu/os-win32.h b/include/sysemu/os-win32.h index 400e098607..fbed346716 100644 --- a/include/sysemu/os-win32.h +++ b/include/sysemu/os-win32.h @@ -26,8 +26,8 @@ #ifndef QEMU_OS_WIN32_H #define QEMU_OS_WIN32_H -#include <windows.h> #include <winsock2.h> +#include <windows.h> /* Workaround for older versions of MinGW. */ #ifndef ECONNREFUSED |