[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-commits] [COMMIT 59a36a2] Win32: Fix compilation with SDL.
From: |
Anthony Liguori |
Subject: |
[Qemu-commits] [COMMIT 59a36a2] Win32: Fix compilation with SDL. |
Date: |
Mon, 22 Jun 2009 15:51:16 -0000 |
From: Stefan Weil <address@hidden>
`sdl-config --cflags` defines main = SDL_main
on some platforms. One of these platforms is
Windows with mingw32.
For those platforms, the solution already developed
for __APPLE__ is now applied.
A compiler warning (missing return value) is fixed, too.
Maybe __APPLE__ no longer needs a separate check.
Signed-off-by: Stefan Weil <address@hidden>
Signed-off-by: Anthony Liguori <address@hidden>
diff --git a/vl.c b/vl.c
index 7ef9748..60a00e1 100644
--- a/vl.c
+++ b/vl.c
@@ -113,12 +113,12 @@
#endif
#ifdef CONFIG_SDL
-#ifdef __APPLE__
+#if defined(__APPLE__) || defined(main)
#include <SDL.h>
int qemu_main(int argc, char **argv, char **envp);
int main(int argc, char **argv)
{
- qemu_main(argc, argv, NULL);
+ return qemu_main(argc, argv, NULL);
}
#undef main
#define main qemu_main
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Qemu-commits] [COMMIT 59a36a2] Win32: Fix compilation with SDL.,
Anthony Liguori <=