From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from [140.186.70.92] (port=38148 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Q8Ivy-0005Bn-EA for qemu-devel@nongnu.org; Fri, 08 Apr 2011 17:09:39 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Q8Ivx-0007ec-Mj for qemu-devel@nongnu.org; Fri, 08 Apr 2011 17:09:38 -0400 Received: from moutng.kundenserver.de ([212.227.126.186]:63556) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Q8Ivx-0007eH-9U for qemu-devel@nongnu.org; Fri, 08 Apr 2011 17:09:37 -0400 Message-ID: <4D9F798C.3060206@mail.berlios.de> Date: Fri, 08 Apr 2011 23:09:32 +0200 From: Stefan Weil MIME-Version: 1.0 References: In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Subject: [Qemu-devel] Re: [PATCH 04/11] Move generic or OS function declarations to qemu-common.h List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Blue Swirl Cc: qemu-devel Am 08.04.2011 22:45, schrieb Blue Swirl: > Move generic or OS related function declarations and macro > TFR to qemu-common.h. > > While moving, also add #include to fix a > recent mingw32 build breakage. > > Signed-off-by: Blue Swirl > --- > qemu-common.h | 21 +++++++++++++++++++++ > sysemu.h | 21 --------------------- > 2 files changed, 21 insertions(+), 21 deletions(-) > > diff --git a/qemu-common.h b/qemu-common.h > index 82e27c1..8b48a09 100644 > --- a/qemu-common.h > +++ b/qemu-common.h > @@ -12,6 +12,7 @@ > #endif > > #define QEMU_BUILD_BUG_ON(x) typedef char > __build_bug_on__##__LINE__[(x)?-1:1]; > +#define TFR(expr) do { if ((expr) != -1) break; } while (errno == EINTR) > > typedef struct QEMUTimer QEMUTimer; > typedef struct QEMUFile QEMUFile; > @@ -39,6 +40,16 @@ typedef struct Monitor Monitor; > #include > #include > > +#ifdef _WIN32 > +#include > +#include > +#include "qemu-os-win32.h" > +#endif > + As far as I could see, there is no file which includes qemu-os-win32.h without including qemu-common.h. So it is possible to move windows.h and winsock2.h to qemu-os-win32.h This would reduce complexity of the common header qemu-common.h a little.