qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH 08/39] provide portable sizeof(long) test


From: malc
Subject: Re: [Qemu-devel] [PATCH 08/39] provide portable sizeof(long) test
Date: Tue, 12 Oct 2010 18:38:38 +0400 (MSD)
User-agent: Alpine 2.00 (LNX 1167 2008-08-23)

On Tue, 12 Oct 2010, Paolo Bonzini wrote:

> On 10/12/2010 03:47 PM, malc wrote:
> > >   # host long bits test
> > > -hostlongbits="32"
> > > -case "$cpu" in
> > > -  x86_64|alpha|ia64|sparc64|ppc64|s390x)
> > > -    hostlongbits=64
> > > -  ;;
> > > -esac
> > > +cat>  $TMPC<<  EOF
> > > +int sizeof_long_is_8[sizeof(long) == 8 ? 1 : -1];
> > > +EOF
> > > +if compile_object; then
> > > +hostlongbits=64
> > > +else
> > > +hostlongbits=32
> > > +fi
> > 
> > This is wrong.
> 
> Care to expand?

Gives wrong results on Win64.

> 
> $ grep LONG +build*/config-host.h
> +build-32/config-host.h:#define HOST_LONG_BITS 32
> +build-64/config-host.h:#define HOST_LONG_BITS 64
> 
> Paolo
> 

-- 
mailto:address@hidden



reply via email to

[Prev in Thread] Current Thread [Next in Thread]