diff options
Diffstat (limited to 'winsup/mingw/include')
-rw-r--r-- | winsup/mingw/include/_mingw.h | 25 | ||||
-rw-r--r-- | winsup/mingw/include/excpt.h | 23 | ||||
-rw-r--r-- | winsup/mingw/include/inttypes.h | 39 | ||||
-rw-r--r-- | winsup/mingw/include/limits.h | 4 | ||||
-rw-r--r-- | winsup/mingw/include/process.h | 22 | ||||
-rw-r--r-- | winsup/mingw/include/stdint.h | 1 | ||||
-rw-r--r-- | winsup/mingw/include/stdio.h | 8 | ||||
-rw-r--r-- | winsup/mingw/include/stdlib.h | 9 | ||||
-rw-r--r-- | winsup/mingw/include/sys/param.h | 4 | ||||
-rw-r--r-- | winsup/mingw/include/wchar.h | 4 |
10 files changed, 23 insertions, 116 deletions
diff --git a/winsup/mingw/include/_mingw.h b/winsup/mingw/include/_mingw.h index cbfd54ced..cb0ff53a7 100644 --- a/winsup/mingw/include/_mingw.h +++ b/winsup/mingw/include/_mingw.h @@ -22,13 +22,6 @@ */ #define __MINGW_H -#define __MINGW_VERSION 4 -#define __MINGW_MAJOR_VERSION 0 -#define __MINGW_MINOR_VERSION 0 -#define __MINGW_PATCHLEVEL 0 - -// These four macros are deprecated and will be removed in the next major -// version release. #define __MINGW32_VERSION 3.20 #define __MINGW32_MAJOR_VERSION 3 #define __MINGW32_MINOR_VERSION 20 @@ -47,10 +40,10 @@ __MINGW_IMPORT The attribute definition to specify imported variables/functions. _CRTIMP As above. For MS compatibility. - __MINGW_VERSION Runtime version. - __MINGW_MAJOR_VERSION Runtime major version. - __MINGW_MINOR_VERSION Runtime minor version. - __MINGW_BUILD_DATE Runtime build date. + __MINGW32_VERSION Runtime version. + __MINGW32_MAJOR_VERSION Runtime major version. + __MINGW32_MINOR_VERSION Runtime minor version. + __MINGW32_BUILD_DATE Runtime build date. Macros to enable MinGW features which deviate from standard MSVC compatible behaviour; these may be specified directly in user code, @@ -290,14 +283,4 @@ allow GCC to optimize away some EH unwind code, at least in DW2 case. */ # endif #endif -struct threadlocalinfostruct; -struct threadmbinfostruct; -typedef struct threadlocalinfostruct *pthreadlocinfo; -typedef struct threadmbcinfostruct *pthreadmbcinfo; - -typedef struct localeinfo_struct { - pthreadlocinfo locinfo; - pthreadmbcinfo mbcinfo; -} _locale_tstruct, *_locale_t; - #endif /* __MINGW_H */ diff --git a/winsup/mingw/include/excpt.h b/winsup/mingw/include/excpt.h index 3919cb791..e75ceb78f 100644 --- a/winsup/mingw/include/excpt.h +++ b/winsup/mingw/include/excpt.h @@ -75,15 +75,8 @@ typedef PEXCEPTION_REGISTRATION PEXCEPTION_REGISTRATION_RECORD; * onto the stack, then put a pointer to the new registration * structure (i.e. the current stack pointer) at fs:0. */ -#ifdef _WIN64 -# define __try1(pHandler) \ - __asm__ __volatile__ ("pushq %0;pushq %%gs:0;movq %%rsp,%%gs:0;" : : \ - "g" (pHandler)); -#else -# define __try1(pHandler) \ - __asm__ __volatile__ ("pushl %0;pushl %%fs:0;movl %%esp,%%fs:0;" : : \ - "g" (pHandler)); -#endif +#define __try1(pHandler) \ + __asm__ ("pushl %0;pushl %%fs:0;movl %%esp,%%fs:0;" : : "g" (pHandler)); /* * A macro which (despite its name) *removes* an installed @@ -96,15 +89,9 @@ typedef PEXCEPTION_REGISTRATION PEXCEPTION_REGISTRATION_RECORD; * the stack must be in the exact state at this point that it was * after we did __try1 or this will smash things. */ -#ifdef _WIN64 -# define __except1 \ - __asm__ __volatile__ ("movq (%%rsp),%%rax;movq %%rax,%%gs:0;addq \ - $16,%%rsp;" : : : "%rax"); -#else -# define __except1 \ - __asm__ __volatile__ ("movl (%%esp),%%eax;movl %%eax,%%fs:0;addl \ - $8,%%esp;" : : : "%eax"); -#endif +#define __except1 \ + __asm__ ("movl (%%esp),%%eax;movl %%eax,%%fs:0;addl $8,%%esp;" \ + : : : "%eax"); #ifdef __cplusplus } diff --git a/winsup/mingw/include/inttypes.h b/winsup/mingw/include/inttypes.h index e13040634..2d2bb8d80 100644 --- a/winsup/mingw/include/inttypes.h +++ b/winsup/mingw/include/inttypes.h @@ -44,6 +44,7 @@ typedef struct { #define PRIdFAST64 "I64d" #define PRIdMAX "I64d" +#define PRIdPTR "d" #define PRIi8 "i" #define PRIi16 "i" @@ -61,6 +62,7 @@ typedef struct { #define PRIiFAST64 "I64i" #define PRIiMAX "I64i" +#define PRIiPTR "i" #define PRIo8 "o" #define PRIo16 "o" @@ -79,6 +81,8 @@ typedef struct { #define PRIoMAX "I64o" +#define PRIoPTR "o" + /* fprintf macros for unsigned types */ #define PRIu8 "u" #define PRIu16 "u" @@ -97,6 +101,7 @@ typedef struct { #define PRIuFAST64 "I64u" #define PRIuMAX "I64u" +#define PRIuPTR "u" #define PRIx8 "x" #define PRIx16 "x" @@ -114,6 +119,7 @@ typedef struct { #define PRIxFAST64 "I64x" #define PRIxMAX "I64x" +#define PRIxPTR "x" #define PRIX8 "X" #define PRIX16 "X" @@ -131,22 +137,7 @@ typedef struct { #define PRIXFAST64 "I64X" #define PRIXMAX "I64X" - -#ifdef _WIN64 -#define PRIdPTR "I64d" -#define PRIiPTR "I64i" -#define PRIoPTR "I64o" -#define PRIuPTR "I64u" -#define PRIxPTR "I64x" -#define PRIXPTR "I64X" -#else -#define PRIdPTR "d" -#define PRIiPTR "i" -#define PRIoPTR "o" -#define PRIuPTR "u" -#define PRIxPTR "x" #define PRIXPTR "X" -#endif /* * fscanf macros for signed int types @@ -168,6 +159,7 @@ typedef struct { #define SCNdFAST64 "I64d" #define SCNdMAX "I64d" +#define SCNdPTR "d" #define SCNi16 "hi" #define SCNi32 "i" @@ -182,6 +174,7 @@ typedef struct { #define SCNiFAST64 "I64i" #define SCNiMAX "I64i" +#define SCNiPTR "i" #define SCNo16 "ho" #define SCNo32 "o" @@ -196,6 +189,7 @@ typedef struct { #define SCNoFAST64 "I64o" #define SCNoMAX "I64o" +#define SCNoPTR "o" #define SCNx16 "hx" #define SCNx32 "x" @@ -210,6 +204,8 @@ typedef struct { #define SCNxFAST64 "I64x" #define SCNxMAX "I64x" +#define SCNxPTR "x" + /* fscanf macros for unsigned int types */ @@ -226,20 +222,7 @@ typedef struct { #define SCNuFAST64 "I64u" #define SCNuMAX "I64u" - -#ifdef _WIN64 -#define SCNdPTR "I64d" -#define SCNiPTR "I64i" -#define SCNoPTR "I64o" -#define SCNxPTR "I64x" -#define SCNuPTR "I64u" -#else -#define SCNdPTR "d" -#define SCNiPTR "i" -#define SCNoPTR "o" -#define SCNxPTR "x" #define SCNuPTR "u" -#endif #if defined (__STDC_VERSION__) && __STDC_VERSION__ >= 199901L /* diff --git a/winsup/mingw/include/limits.h b/winsup/mingw/include/limits.h index ca4900610..96ad26cec 100644 --- a/winsup/mingw/include/limits.h +++ b/winsup/mingw/include/limits.h @@ -29,9 +29,7 @@ * are semantically identical, with a limit of 259 characters for the * path name, plus one for a terminating NUL, for a total of 260. */ -#ifndef __STRICT_ANSI__ -# define PATH_MAX 260 -#endif +#define PATH_MAX 260 /* * Characteristics of the char data type. diff --git a/winsup/mingw/include/process.h b/winsup/mingw/include/process.h index 0a3511f4d..c0c380fbd 100644 --- a/winsup/mingw/include/process.h +++ b/winsup/mingw/include/process.h @@ -79,28 +79,6 @@ _CRTIMP intptr_t __cdecl __MINGW_NOTHROW _spawnve (int, const char*, const char* _CRTIMP intptr_t __cdecl __MINGW_NOTHROW _spawnvp (int, const char*, const char* const*); _CRTIMP intptr_t __cdecl __MINGW_NOTHROW _spawnvpe (int, const char*, const char* const*, const char* const*); -#ifndef _WPROCESS_DEFINED -/* Also in wchar.h - keep in sync */ -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wexecl (const wchar_t*, const wchar_t*, ...); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wexecle (const wchar_t*, const wchar_t*, ...); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wexeclp (const wchar_t*, const wchar_t*, ...); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wexeclpe (const wchar_t*, const wchar_t*, ...); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wexecv (const wchar_t*, const wchar_t* const*); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wexecve (const wchar_t*, const wchar_t* const*, const wchar_t* const*); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wexecvp (const wchar_t*, const wchar_t* const*); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wexecvpe (const wchar_t*, const wchar_t* const*, const wchar_t* const*); - -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wspawnl (int, const wchar_t*, const wchar_t*, ...); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wspawnle (int, const wchar_t*, const wchar_t*, ...); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wspawnlp (int, const wchar_t*, const wchar_t*, ...); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wspawnlpe (int, const wchar_t*, const wchar_t*, ...); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wspawnv (int, const wchar_t*, const wchar_t* const*); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wspawnve (int, const wchar_t*, const wchar_t* const*, const wchar_t* const*); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wspawnvp (int, const wchar_t*, const wchar_t* const*); -_CRTIMP intptr_t __cdecl __MINGW_NOTHROW _wspawnvpe (int, const wchar_t*, const wchar_t* const*, const wchar_t* const*); - -#define _WPROCESS_DEFINED -#endif /* * The functions _beginthreadex and _endthreadex are not provided by CRTDLL. diff --git a/winsup/mingw/include/stdint.h b/winsup/mingw/include/stdint.h index 942a1a8fc..c6ab3bcef 100644 --- a/winsup/mingw/include/stdint.h +++ b/winsup/mingw/include/stdint.h @@ -19,7 +19,6 @@ #ifndef _STDINT_H #define _STDINT_H -#include <_mingw.h> #define __need_wint_t #define __need_wchar_t #include <stddef.h> diff --git a/winsup/mingw/include/stdio.h b/winsup/mingw/include/stdio.h index 60f540114..fe9f2b735 100644 --- a/winsup/mingw/include/stdio.h +++ b/winsup/mingw/include/stdio.h @@ -591,13 +591,10 @@ _CRTIMP wchar_t* __cdecl __MINGW_NOTHROW fgetws (wchar_t*, int, FILE*); _CRTIMP int __cdecl __MINGW_NOTHROW fputws (const wchar_t*, FILE*); _CRTIMP wint_t __cdecl __MINGW_NOTHROW getwc (FILE*); _CRTIMP wint_t __cdecl __MINGW_NOTHROW getwchar (void); -_CRTIMP wint_t __cdecl __MINGW_NOTHROW putwc (wint_t, FILE*); -_CRTIMP wint_t __cdecl __MINGW_NOTHROW putwchar (wint_t); -#ifndef __STRICT_ANSI__ -_CRTIMP void __cdecl __MINGW_NOTHROW _lock_file(FILE*); -_CRTIMP void __cdecl __MINGW_NOTHROW _unlock_file(FILE*); _CRTIMP wchar_t* __cdecl __MINGW_NOTHROW _getws (wchar_t*); +_CRTIMP wint_t __cdecl __MINGW_NOTHROW putwc (wint_t, FILE*); _CRTIMP int __cdecl __MINGW_NOTHROW _putws (const wchar_t*); +_CRTIMP wint_t __cdecl __MINGW_NOTHROW putwchar (wint_t); _CRTIMP FILE* __cdecl __MINGW_NOTHROW _wfdopen(int, const wchar_t *); _CRTIMP FILE* __cdecl __MINGW_NOTHROW _wfopen (const wchar_t*, const wchar_t*); _CRTIMP FILE* __cdecl __MINGW_NOTHROW _wfreopen (const wchar_t*, const wchar_t*, FILE*); @@ -608,7 +605,6 @@ _CRTIMP int __cdecl __MINGW_NOTHROW _wrename (const wchar_t*, const wchar_t*); _CRTIMP int __cdecl __MINGW_NOTHROW _wremove (const wchar_t*); _CRTIMP void __cdecl __MINGW_NOTHROW _wperror (const wchar_t*); _CRTIMP FILE* __cdecl __MINGW_NOTHROW _wpopen (const wchar_t*, const wchar_t*); -#endif /* __STRICT_ANSI__ */ #endif /* __MSVCRT__ */ #ifndef __NO_ISOCEXT /* externs in libmingwex.a */ diff --git a/winsup/mingw/include/stdlib.h b/winsup/mingw/include/stdlib.h index ece21cb44..4df18aab3 100644 --- a/winsup/mingw/include/stdlib.h +++ b/winsup/mingw/include/stdlib.h @@ -300,11 +300,6 @@ __MINGW_IMPORT int _fmode_dll; #endif /* Not __STRICT_ANSI__ */ -_CRTIMP __int64 __cdecl _strtoi64(const char*, char **, int); -_CRTIMP __int64 __cdecl _strtoi64_l(const char *, char **, int, _locale_t); -_CRTIMP unsigned __int64 __cdecl _strtoui64(const char*, char **, int); -_CRTIMP unsigned __int64 __cdecl _strtoui64_l(const char *, char **, int, _locale_t); - _CRTIMP double __cdecl __MINGW_NOTHROW atof (const char*); _CRTIMP int __cdecl __MINGW_NOTHROW atoi (const char*); _CRTIMP long __cdecl __MINGW_NOTHROW atol (const char*); @@ -328,10 +323,6 @@ _CRTIMP unsigned long __cdecl __MINGW_NOTHROW strtoul (const char*, char**, int) #ifndef _WSTDLIB_DEFINED /* also declared in wchar.h */ -_CRTIMP __int64 __cdecl _wcstoi64(const wchar_t *, wchar_t **, int); -_CRTIMP __int64 __cdecl _wcstoi64_l(const wchar_t *, wchar_t **, int, _locale_t); -_CRTIMP unsigned __int64 __cdecl _wcstoui64(const wchar_t *, wchar_t **, int); -_CRTIMP unsigned __int64 __cdecl _wcstoui64_l(const wchar_t *, wchar_t **, int, _locale_t); _CRTIMP long __cdecl __MINGW_NOTHROW wcstol (const wchar_t*, wchar_t**, int); _CRTIMP unsigned long __cdecl __MINGW_NOTHROW wcstoul (const wchar_t*, wchar_t**, int); _CRTIMP double __cdecl __MINGW_NOTHROW wcstod (const wchar_t*, wchar_t**); diff --git a/winsup/mingw/include/sys/param.h b/winsup/mingw/include/sys/param.h index d38b46a5c..74966bd78 100644 --- a/winsup/mingw/include/sys/param.h +++ b/winsup/mingw/include/sys/param.h @@ -17,10 +17,6 @@ #define LITTLE_ENDIAN 1234 #define BYTE_ORDER LITTLE_ENDIAN -#ifdef PATH_MAX #define MAXPATHLEN PATH_MAX -#else -#define MAXPATHLEN 260 -#endif #endif diff --git a/winsup/mingw/include/wchar.h b/winsup/mingw/include/wchar.h index dadeda6d3..60e8d9c2b 100644 --- a/winsup/mingw/include/wchar.h +++ b/winsup/mingw/include/wchar.h @@ -177,10 +177,6 @@ _CRTIMP void __cdecl __MINGW_NOTHROW _wmakepath(wchar_t*, const wchar_t*, const _CRTIMP void __cdecl __MINGW_NOTHROW _wsplitpath (const wchar_t*, wchar_t*, wchar_t*, wchar_t*, wchar_t*); _CRTIMP wchar_t* __cdecl __MINGW_NOTHROW _wfullpath (wchar_t*, const wchar_t*, size_t); #endif -_CRTIMP __int64 __cdecl _wcstoi64(const wchar_t *, wchar_t **, int); -_CRTIMP __int64 __cdecl _wcstoi64_l(const wchar_t *, wchar_t **, int, _locale_t); -_CRTIMP unsigned __int64 __cdecl _wcstoui64(const wchar_t *, wchar_t **, int); -_CRTIMP unsigned __int64 __cdecl _wcstoui64_l(const wchar_t *, wchar_t **, int, _locale_t); #define _WSTDLIB_DEFINED #endif /* _WSTDLIB_DEFINED */ |