64 bit python

E. McKay Hyde hyde at math.umn.edu
Thu Jun 5 17:04:57 CEST 2003


Martin v. Löwis wrote:

> So either LONG_BIT or SIZEOF_LONG is incorrect. Can you tell the
> values for either #define?
> 
> Notice that this problem is not generic for 64-bit systems, as there
> are actual 64-bit systems which do get their defines right (e.g. Sparc
> Solaris 64-bit, or Tru64). So it would be more a problem specific to
> your system, or your configuration. For example, which compiler did
> you use during configure?
> 
> Regards,
> Martin
> 

Sure. The value of LONG_BIT (defined in sys/limits.h on my system) 
depends on the compiler flags:  if I use xlC -q64 (as I did in the 
configure) LONG_BIT=64, otherwise if one uses xlC alone LONG_BIT=32.

SIZEOF_LONG=4, as defined in pyconfig.h; this value appears to be set by 
the autoconf macro AC_CHECK_SIZEOF(long,4).  Does this mean that the 
configure script expects a size of 4 bytes?  Or perhaps the macro is 
using a different compiler in determining the size?  I guess I will try 
to understand how AC_CHECK_SIZEOF works to see if it is using the 
correct compiler and compiler flags.

Thanks,

McKay





More information about the Python-list mailing list