Define data types to the correct size on 64-bit platforms.
This commit is contained in:
parent
470f23d471
commit
bdf01c368d
|
@ -38,6 +38,10 @@ extern "C" {
|
||||||
* type model where int and long are 32 bit and pointer is 64-bit.
|
* type model where int and long are 32 bit and pointer is 64-bit.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
#ifdef __x86_64__
|
||||||
|
#define _WIN64
|
||||||
|
#endif
|
||||||
|
|
||||||
/* Type model independent typedefs */
|
/* Type model independent typedefs */
|
||||||
/* The __intXX types are native types defined by the MS C compiler.
|
/* The __intXX types are native types defined by the MS C compiler.
|
||||||
* Apps that make use of them before they get defined here, can
|
* Apps that make use of them before they get defined here, can
|
||||||
|
@ -55,7 +59,11 @@ extern "C" {
|
||||||
# define __int32 int
|
# define __int32 int
|
||||||
# endif
|
# endif
|
||||||
# ifndef __int64
|
# ifndef __int64
|
||||||
# define __int64 long long
|
# ifdef _WIN64
|
||||||
|
# define __int64 long
|
||||||
|
# else
|
||||||
|
# define __int64 long long
|
||||||
|
# endif
|
||||||
# endif
|
# endif
|
||||||
#endif /* !defined(_MSC_VER) */
|
#endif /* !defined(_MSC_VER) */
|
||||||
|
|
||||||
|
|
|
@ -41,6 +41,10 @@ extern "C" {
|
||||||
# define _X86_
|
# define _X86_
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef __x86_64__
|
||||||
|
#define _WIN64
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifndef __stdcall
|
#ifndef __stdcall
|
||||||
# ifdef __i386__
|
# ifdef __i386__
|
||||||
# ifdef __GNUC__
|
# ifdef __GNUC__
|
||||||
|
@ -174,11 +178,17 @@ typedef unsigned short WORD, *PWORD, *LPWORD;
|
||||||
typedef unsigned short USHORT, *PUSHORT;
|
typedef unsigned short USHORT, *PUSHORT;
|
||||||
typedef int INT, *PINT, *LPINT;
|
typedef int INT, *PINT, *LPINT;
|
||||||
typedef unsigned int UINT, *PUINT;
|
typedef unsigned int UINT, *PUINT;
|
||||||
|
typedef float FLOAT, *PFLOAT;
|
||||||
|
typedef char *PSZ;
|
||||||
|
#if defined(_WIN64) && !defined(_MSC_VER)
|
||||||
|
typedef int *LPLONG;
|
||||||
|
typedef unsigned int DWORD, *PDWORD, *LPDWORD;
|
||||||
|
typedef unsigned int ULONG, *PULONG;
|
||||||
|
#else
|
||||||
typedef long *LPLONG;
|
typedef long *LPLONG;
|
||||||
typedef unsigned long DWORD, *PDWORD, *LPDWORD;
|
typedef unsigned long DWORD, *PDWORD, *LPDWORD;
|
||||||
typedef unsigned long ULONG, *PULONG;
|
typedef unsigned long ULONG, *PULONG;
|
||||||
typedef float FLOAT, *PFLOAT;
|
#endif
|
||||||
typedef char *PSZ;
|
|
||||||
|
|
||||||
/* Macros to map Winelib names to the correct implementation name */
|
/* Macros to map Winelib names to the correct implementation name */
|
||||||
/* Note that Winelib is purely Win32. */
|
/* Note that Winelib is purely Win32. */
|
||||||
|
|
|
@ -300,7 +300,11 @@ typedef VOID *PVOID64;
|
||||||
typedef BYTE BOOLEAN, *PBOOLEAN;
|
typedef BYTE BOOLEAN, *PBOOLEAN;
|
||||||
typedef char CHAR, *PCHAR;
|
typedef char CHAR, *PCHAR;
|
||||||
typedef short SHORT, *PSHORT;
|
typedef short SHORT, *PSHORT;
|
||||||
|
#if defined(_WIN64) && !defined(_MSC_VER)
|
||||||
|
typedef int LONG, *PLONG;
|
||||||
|
#else
|
||||||
typedef long LONG, *PLONG;
|
typedef long LONG, *PLONG;
|
||||||
|
#endif
|
||||||
|
|
||||||
/* Some systems might have wchar_t, but we really need 16 bit characters */
|
/* Some systems might have wchar_t, but we really need 16 bit characters */
|
||||||
#ifdef WINE_UNICODE_NATIVE
|
#ifdef WINE_UNICODE_NATIVE
|
||||||
|
|
Loading…
Reference in New Issue