[Spice-devel] mingw compilation error
Nerijus Baliunas
nerijus at users.sourceforge.net
Sun Mar 25 18:57:54 PDT 2012
On Mon, 26 Mar 2012 03:08:32 +0300 Nerijus Baliunas <nerijus at users.sourceforge.net> wrote:
> ../spice-common/common/gdi_canvas.c:986:66: error: 'AlphaBlend' was not declared in this scope
It is defined in /usr/i686-pc-mingw32/sys-root/mingw/include/wingdi.h, but only
#if (WINVER >= 0x0410), and by default my mingw (Fedora 16 cross) has #define WINVER 0x0400.
I also had a problem with swprintf_s() undeclared. The following patch helped:
--- a/client/common.h
+++ b/client/common.h
@@ -44,7 +44,7 @@
#ifdef __GNUC__
#define UNICODE 1
#define _UNICODE 1
-#if !defined __MINGW32__
+#if defined __MINGW32__
#define WINVER 0x0501
#define swprintf_s(_str, _len, _fmt, ...) \
swprintf(_str, _fmt, ## __VA_ARGS__)
Regards,
Nerijus
More information about the Spice-devel
mailing list