From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:54689) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QQo9K-0000BS-CE for qemu-devel@nongnu.org; Sun, 29 May 2011 18:07:55 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QQo9J-00071S-8Q for qemu-devel@nongnu.org; Sun, 29 May 2011 18:07:54 -0400 Received: from e32.co.us.ibm.com ([32.97.110.150]:46669) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QQo9J-00071F-3D for qemu-devel@nongnu.org; Sun, 29 May 2011 18:07:53 -0400 Received: from d03relay05.boulder.ibm.com (d03relay05.boulder.ibm.com [9.17.195.107]) by e32.co.us.ibm.com (8.14.4/8.13.1) with ESMTP id p4TLuHK8018251 for ; Sun, 29 May 2011 15:56:17 -0600 Received: from d03av05.boulder.ibm.com (d03av05.boulder.ibm.com [9.17.195.85]) by d03relay05.boulder.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id p4TM7k9O364486 for ; Sun, 29 May 2011 16:07:46 -0600 Received: from d03av05.boulder.ibm.com (loopback [127.0.0.1]) by d03av05.boulder.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id p4TM7kCV003921 for ; Sun, 29 May 2011 16:07:46 -0600 Message-ID: <4DE2C3B1.6060209@linux.vnet.ibm.com> Date: Sun, 29 May 2011 18:07:45 -0400 From: Stefan Berger MIME-Version: 1.0 References: <4DDEA34C.4040304@linux.vnet.ibm.com> <4DDEB8B3.20807@linux.vnet.ibm.com> <7DC4629D-B668-48EB-B4A7-9DF571A478FC@web.de> <4DDED354.9090009@linux.vnet.ibm.com> <6768C91F-25A5-4A55-B84F-E5EAB67D3762@web.de> In-Reply-To: <6768C91F-25A5-4A55-B84F-E5EAB67D3762@web.de> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PATCH] host-pcc: enable building with -m32 or -m64 List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: =?ISO-8859-1?Q?Andreas_F=E4rber?= Cc: Paolo Bonzini , QEMU Developers , Alexander Graf On 05/29/2011 05:09 PM, Andreas F=E4rber wrote: > Am 27.05.2011 um 00:25 schrieb Stefan Berger: > >> On 05/26/2011 05:24 PM, Andreas F=E4rber wrote: >>> Am 26.05.2011 um 22:31 schrieb Stefan Berger: >>> >>>> On 05/26/2011 04:20 PM, Andreas F=E4rber wrote: >>>>> Am 26.05.2011 um 21:00 schrieb Stefan Berger: >>>>> >>>>>> With the below patch I can build either ppc (-m32) or ppc64=20 >>>>>> (-m64) versions of Qemu (on a ppc64 host) when passing these=20 >>>>>> compiler flags via 'configure ... --extra-cflags=3D"-m32"'. >>>>> >>>>> You probably meant "without passing"? >>>>> >>>>> Nack. Please don't hardcode -mXX in configure, it's -arch ppc vs.=20 >>>>> -arch ppc64 on my host/gcc. What's wrong with passing --extra-cflag= s? >>>>> >>>> I posted the following patch today for compiling libcacard with=20 >>>> -m32 on a 64 bit machine. >>>> >>>> http://lists.nongnu.org/archive/html/qemu-devel/2011-05/msg02909.htm= l >>>> >>>> It adds LDFLAGS. This works fine on x86-64. Then trying this out on=20 >>>> ppc64 with -m32 in extra-cflags I find the following in=20 >>>> config-host.mak >>>> >>>> [...] >>>> HELPER_CFLAGS=3D >>>> LDFLAGS=3D-Wl,--warn-common -g >>>> ARLIBS_BEGIN=3D >>>> [...] >>>> >>>> The -m32 doesn't make it into LDFLAGS. The below patch fixed it for=20 >>>> me following the pattern of x86-64 and i686 a bit further up in the=20 >>>> case statement in configure. >>> >>> Erm, you did try --extra-ldflags for LDFLAGS, did you? That=20 >>> --extra-cflags doesn't end up there is intentional! >>> >> No, I didn't. Here's what happened. On x86_64 host I used to be able=20 >> to compile 32bit executables with --extra-cflags=3D"-m32". That stoppe= d=20 >> working when libcacard showed up -- I posted a patch today -- only=20 >> the linking of vscclient in libcacard/ didn't work. The "work-around"=20 >> before the patch was --disable-smartcard. Now taking that same habit=20 >> of passing --extra-cflags=3D"-m32" to the ppc64 machine again didn't=20 >> work, but was broken somewhere else. So this is where this is all=20 >> coming from. > > Stefan, I rather care about where this is going, and my unanswered=20 > question is: Does it work if you use --extra-cflags=3D-m32=20 > --extra-ldflags=3D-m32? > If yes, then we can drop this patch and be good. Otherwise we need to=20 > think about a better solution. > It works as you show above once this patch here has been applied: http://lists.nongnu.org/archive/html/qemu-devel/2011-05/msg02909.html Stefan