diff --git a/ChangeLog b/ChangeLog index 888fcb990..6fd653cc2 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2003-09-29 Havoc Pennington + + * src/xprops.c (cvtINT16toInt): fix the 64-bit check not to use + macros from the X tree that don't get set + + * configure.in: check for sizes of various types + 2003-09-29 Havoc Pennington * src/delete.c (meta_window_delete): don't move the focus after diff --git a/configure.in b/configure.in index cd50cc1ad..fbe7ad1d5 100644 --- a/configure.in +++ b/configure.in @@ -23,6 +23,18 @@ AC_HEADER_STDC AC_LIBTOOL_WIN32_DLL AM_PROG_LIBTOOL +#### Integer sizes + +AC_CHECK_SIZEOF(char) +AC_CHECK_SIZEOF(short) +AC_CHECK_SIZEOF(long) +AC_CHECK_SIZEOF(int) +AC_CHECK_SIZEOF(void *) +AC_CHECK_SIZEOF(long long) +AC_CHECK_SIZEOF(__int64) + +#### Warnings + changequote(,)dnl if test "x$GCC" = "xyes"; then case " $CFLAGS " in diff --git a/src/xprops.c b/src/xprops.c index d8859ab03..cc9bd97c2 100644 --- a/src/xprops.c +++ b/src/xprops.c @@ -657,7 +657,7 @@ meta_prop_get_text_property (MetaDisplay *display, /* From Xmd.h */ #ifndef cvtINT32toInt -#if defined(WORD64) && defined(UNSIGNEDBITFIELDS) +#if SIZEOF_VOID_P == 8 #define cvtINT8toInt(val) (((val) & 0x00000080) ? ((val) | 0xffffffffffffff00) : (val)) #define cvtINT16toInt(val) (((val) & 0x00008000) ? ((val) | 0xffffffffffff0000) : (val)) #define cvtINT32toInt(val) (((val) & 0x80000000) ? ((val) | 0xffffffff00000000) : (val)) @@ -677,7 +677,7 @@ meta_prop_get_text_property (MetaDisplay *display, #define cvtINT8toLong(val) (val) #define cvtINT16toLong(val) (val) #define cvtINT32toLong(val) (val) -#endif /* WORD64 and UNSIGNEDBITFIELDS */ +#endif /* SIZEOF_VOID_P == 8 */ #endif /* cvtINT32toInt() */ static gboolean