What GCC version had <stdint.h> defined?
Jeff Epler
jepler at unpythonic.net
Thu Aug 26 22:26:43 EDT 2004
I glanced at configure.in and it checks for HAVE_UINTPTR_T, but not
HAVE_INTPTR_T. If you want this define where it's available, add the
proper test to configure.in and regenerate configure.
I think the block would be something like this, a straightforward
search-and-replace of the block for HAVE_UINTPTR_T:
AC_MSG_CHECKING(for intptr_t support)
have_intptr_t=no
AC_TRY_COMPILE([], [intptr_t x; x = (intptr_t)0;], [
AC_DEFINE(HAVE_INTPTR_T, 1, [Define this if you have the type
intptr_t.])
have_intptr_t=yes
])
AC_MSG_RESULT($have_intptr_t)
if test "$have_intptr_t" = yes ; then
AC_CHECK_SIZEOF(intptr_t, 4)
fi
on the other hand, maybe this test is broken, because my system (Fedora
Core 2) configured with #undef HAVE_UINTPTR_T.
Maybe this article shows the way:
http://sources.redhat.com/ml/gdb-patches/2003-02/msg00687.html
AC_MSG_CHECKING(for uintptr_t in C library)
AC_CACHE_VAL(gdb_cv_have_uintptr_t,
[AC_TRY_COMPILE([#include <stdint.h>],
[uintptr_t foo = 0;
return foo;],
gdb_cv_have_uintptr_t=yes,
gdb_cv_have_uintptr_t=no)])
AC_MSG_RESULT($gdb_cv_have_uintptr_t)
if test $gdb_cv_have_uintptr_t = yes; then
AC_DEFINE(HAVE_UINTPTR_T)
fi
... with appropriate renaming for Python.
I'm not sure why uintptr_t or intptr_t are all that useful, since the
spellings "unsigned *" and "int *" are going to work everywhere anyway.
Jeff
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 196 bytes
Desc: not available
URL: <http://mail.python.org/pipermail/python-list/attachments/20040826/3c431778/attachment.sig>
More information about the Python-list
mailing list