From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1MHM4v-0005dt-8P for qemu-devel@nongnu.org; Thu, 18 Jun 2009 14:11:13 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1MHM4q-0005Ss-Gv for qemu-devel@nongnu.org; Thu, 18 Jun 2009 14:11:12 -0400 Received: from [199.232.76.173] (port=49139 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1MHM4q-0005Sc-Dn for qemu-devel@nongnu.org; Thu, 18 Jun 2009 14:11:08 -0400 Received: from moutng.kundenserver.de ([212.227.126.186]:57475) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1MHM4p-00010a-TQ for qemu-devel@nongnu.org; Thu, 18 Jun 2009 14:11:08 -0400 From: Stefan Weil Date: Thu, 18 Jun 2009 20:11:03 +0200 Message-Id: <1245348663-9022-1-git-send-email-weil@mail.berlios.de> Subject: [Qemu-devel] [PATCH] Win32: Fix compilation with SDL. List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: QEMU Developers `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 --- vl.c | 4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/vl.c b/vl.c index 3242c23..e688837 100644 --- a/vl.c +++ b/vl.c @@ -113,12 +113,12 @@ #endif #ifdef CONFIG_SDL -#ifdef __APPLE__ +#if defined(__APPLE__) || defined(main) #include 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 -- 1.5.6.5