crtdefs.h revision 3194da424708abdd288b28d96892b3a5f3f7df0b
/*
* CRT definitions
*
* Copyright 2000 Francois Gouget.
*
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#ifndef __WINE_CRTDEFS_H
#define __WINE_CRTDEFS_H
#ifndef __WINE_USE_MSVCRT
#define __WINE_USE_MSVCRT
#endif
#ifdef __WINE_WINE_PORT_H
#endif
#if (defined(__x86_64__) || defined(__powerpc64__) || defined(__sparc64__) || defined(__aarch64__)) && !defined(_WIN64)
#define _WIN64
#endif
# if defined(_WIN64) && !defined(__MINGW64__)
# define __int64 long
# else
# define __int64 long long
# endif
#endif
#ifndef __stdcall
# ifdef __i386__
# ifdef __GNUC__
# ifdef __APPLE__ /* Mac OS X uses a 16-byte aligned stack and not a 4-byte one */
# else
# endif
/* Nothing needs to be done. __stdcall already exists */
# else
# endif
# else
# define __stdcall
# endif
#endif /* __stdcall */
#ifndef __cdecl
# ifdef __APPLE__ /* Mac OS X uses 16-byte aligned stack and not a 4-byte one */
# else
# endif
# define __cdecl
# endif
#endif /* __cdecl */
#ifndef __ms_va_list
# if defined(__x86_64__) && defined (__GNUC__)
# define __ms_va_list __builtin_ms_va_list
# else
# define __ms_va_list va_list
# endif
#endif
#ifndef DECLSPEC_ALIGN
# else
# define DECLSPEC_ALIGN(x)
# endif
#endif
#define _ARGMAX 100
#ifndef _MSVCRT_LONG_DEFINED
#define _MSVCRT_LONG_DEFINED
/* we need 32-bit longs even on 64-bit */
typedef int __msvcrt_long;
typedef unsigned int __msvcrt_ulong;
#endif
#ifndef _INTPTR_T_DEFINED
#ifdef _WIN64
#else
typedef int intptr_t;
#endif
#define _INTPTR_T_DEFINED
#endif
#ifndef _UINTPTR_T_DEFINED
#ifdef _WIN64
#else
typedef unsigned int uintptr_t;
#endif
#define _UINTPTR_T_DEFINED
#endif
#ifndef _PTRDIFF_T_DEFINED
#ifdef _WIN64
#else
typedef int ptrdiff_t;
#endif
#define _PTRDIFF_T_DEFINED
#endif
#ifndef _SIZE_T_DEFINED
#ifdef _WIN64
#else
typedef unsigned int size_t;
#endif
#define _SIZE_T_DEFINED
#endif
#ifndef _TIME32_T_DEFINED
typedef __msvcrt_long __time32_t;
#define _TIME32_T_DEFINED
#endif
#ifndef _TIME64_T_DEFINED
#define _TIME64_T_DEFINED
#endif
#ifdef _USE_32BIT_TIME_T
# ifdef _WIN64
# endif
# define _USE_32BIT_TIME_T
#endif
#ifndef _TIME_T_DEFINED
#ifdef _USE_32BIT_TIME_T
typedef __time32_t time_t;
#else
typedef __time64_t time_t;
#endif
#define _TIME_T_DEFINED
#endif
#ifndef _WCHAR_T_DEFINED
#ifndef __cplusplus
typedef unsigned short wchar_t;
#endif
#define _WCHAR_T_DEFINED
#endif
#ifndef _WCTYPE_T_DEFINED
typedef unsigned short wint_t;
typedef unsigned short wctype_t;
#define _WCTYPE_T_DEFINED
#endif
#ifndef _ERRNO_T_DEFINED
typedef int errno_t;
#define _ERRNO_T_DEFINED
#endif
struct threadlocaleinfostruct;
struct threadmbcinfostruct;
typedef struct threadlocaleinfostruct *pthreadlocinfo;
typedef struct threadmbcinfostruct *pthreadmbcinfo;
typedef struct localeinfo_struct
{
} _locale_tstruct, *_locale_t;
#ifndef _TAGLC_ID_DEFINED
typedef struct tagLC_ID {
unsigned short wLanguage;
unsigned short wCountry;
unsigned short wCodePage;
#define _TAGLC_ID_DEFINED
#endif
#ifndef _THREADLOCALEINFO
typedef struct threadlocaleinfostruct {
int refcount;
unsigned int lc_codepage;
unsigned int lc_collate_cp;
struct {
char *locale;
int *refcount;
int *wrefcount;
} lc_category[6];
int lc_clike;
int mb_cur_max;
int *lconv_intl_refcount;
int *lconv_num_refcount;
int *lconv_mon_refcount;
int *ctype1_refcount;
unsigned short *ctype1;
const unsigned short *pctype;
const unsigned char *pclmap;
const unsigned char *pcumap;
struct __lc_time_data *lc_time_curr;
#define _THREADLOCALEINFO
#endif
#endif /* __WINE_CRTDEFS_H */