From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:46603) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qxu9P-0003EW-8M for qemu-devel@nongnu.org; Mon, 29 Aug 2011 01:12:48 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Qxu9O-0008PS-AH for qemu-devel@nongnu.org; Mon, 29 Aug 2011 01:12:47 -0400 Received: from v220110690675601.yourvserver.net ([78.47.199.172]:48479) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qxu9O-0008PO-5l for qemu-devel@nongnu.org; Mon, 29 Aug 2011 01:12:46 -0400 Message-ID: <4E5B1FCC.5000808@mail.berlios.de> Date: Mon, 29 Aug 2011 07:12:44 +0200 From: Stefan Weil MIME-Version: 1.0 References: <1314564200-6872-1-git-send-email-weil@mail.berlios.de> <1314564200-6872-2-git-send-email-weil@mail.berlios.de> <1D3513E3-B93D-49FC-8B36-814F4DD0FBBF@web.de> In-Reply-To: <1D3513E3-B93D-49FC-8B36-814F4DD0FBBF@web.de> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH 1/7] Add new macro QEMU_PACKED for packed C structures List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: =?ISO-8859-1?Q?Andreas_F=E4rber?= Cc: QEMU Developers Am 28.08.2011 22:47, schrieb Andreas F=E4rber: > Am 28.08.2011 um 22:43 schrieb Stefan Weil: > >> A packed struct needs different gcc attributes for compilations >> with MinGW compilers because glib-2.0 adds compiler flag >> -mms-bitfields which modifies the packing algorithm. > > Is that algorithm actually needed anywhere? If not, is there no GCC=20 > option to fix this centrally in configure for win32 only? > > Andreas I think it is needed: glib-2.0 requires -mms-bitfields for MinGW which breaks networking (and more) for w32 hosts because of changes in struct alignment. A central solution would require removal of -mms-bitfields or its effects. This is possible, but very risky, because it will raise problems with glib-2.0 and w32 libraries. Therefore a central solution was rejected. See this thread: http://lists.gnu.org/archive/html/qemu-devel/2011-08/msg01877.html Stefan