From 9f0ff1bfd2b56bf6d834c1148da0e3848b56c7af Mon Sep 17 00:00:00 2001 From: Alexandre Julliard Date: Wed, 29 May 2002 02:02:19 +0000 Subject: [PATCH] Moved WORDS_BIGENDIAN macros to basetsd.h. Fixed FILETIME definition for big-endian. --- include/basetsd.h | 23 ++++++++++++++++++++--- include/winbase.h | 5 +++++ include/winnt.h | 19 ------------------- 3 files changed, 25 insertions(+), 22 deletions(-) diff --git a/include/basetsd.h b/include/basetsd.h index 31b28017ce1..c1ef3ae9902 100644 --- a/include/basetsd.h +++ b/include/basetsd.h @@ -154,11 +154,28 @@ typedef __uint32 DWORD_PTR, *PDWORD_PTR; typedef INT_PTR SSIZE_T, *PSSIZE_T; typedef UINT_PTR SIZE_T, *PSIZE_T; +/* Some Wine-specific definitions */ + +/* Architecture dependent settings. */ +/* These are hardcoded to avoid dependencies on config.h in Winelib apps. */ +#if defined(__i386__) +# undef WORDS_BIGENDIAN +# undef BITFIELDS_BIGENDIAN +# define ALLOW_UNALIGNED_ACCESS +#elif defined(__sparc__) +# define WORDS_BIGENDIAN +# define BITFIELDS_BIGENDIAN +# undef ALLOW_UNALIGNED_ACCESS +#elif defined(__PPC__) +# define WORDS_BIGENDIAN +# define BITFIELDS_BIGENDIAN +# undef ALLOW_UNALIGNED_ACCESS +#elif !defined(RC_INVOKED) +# error Unknown CPU architecture! +#endif + #ifdef __cplusplus } /* extern "C" */ #endif /* defined(__cplusplus) */ #endif /* !defined(__WINE_BASETSD_H) */ - - - diff --git a/include/winbase.h b/include/winbase.h index 3b44bc30b85..769bab02006 100644 --- a/include/winbase.h +++ b/include/winbase.h @@ -202,8 +202,13 @@ typedef struct _SECURITY_ATTRIBUTES /* 64 bit number of 100 nanoseconds intervals since January 1, 1601 */ typedef struct { +#ifdef WORDS_BIGENDIAN + DWORD dwHighDateTime; + DWORD dwLowDateTime; +#else DWORD dwLowDateTime; DWORD dwHighDateTime; +#endif } FILETIME, *PFILETIME, *LPFILETIME; #endif /* _FILETIME_ */ diff --git a/include/winnt.h b/include/winnt.h index 397fcf5971a..92d4d369df2 100644 --- a/include/winnt.h +++ b/include/winnt.h @@ -41,25 +41,6 @@ /**** Some Wine specific definitions *****/ -/* Architecture dependent settings. */ -/* These are hardcoded to avoid dependencies on config.h in Winelib apps. */ -#if defined(__i386__) -# undef WORDS_BIGENDIAN -# undef BITFIELDS_BIGENDIAN -# define ALLOW_UNALIGNED_ACCESS -#elif defined(__sparc__) -# define WORDS_BIGENDIAN -# define BITFIELDS_BIGENDIAN -# undef ALLOW_UNALIGNED_ACCESS -#elif defined(__PPC__) -# define WORDS_BIGENDIAN -# define BITFIELDS_BIGENDIAN -# undef ALLOW_UNALIGNED_ACCESS -#elif !defined(RC_INVOKED) -# error Unknown CPU architecture! -#endif - - /* Calling conventions definitions */ #ifdef __i386__