Commit | Line | Data |
---|---|---|
348209ec FF |
1 | diff -u -r ../gcc-5.2.0/gcc/system.h ./gcc/system.h |
2 | --- ../gcc-5.2.0/gcc/system.h 2015-01-05 07:33:28.000000000 -0500 | |
3 | +++ ./gcc/system.h 2015-08-09 09:11:10.048889012 -0400 | |
4 | @@ -50,150 +50,6 @@ | |
5 | #define NULL 0 | |
6 | #endif | |
7 | ||
8 | -/* Use the unlocked open routines from libiberty. */ | |
9 | - | |
10 | -/* Some of these are #define on some systems, e.g. on AIX to redirect | |
11 | - the names to 64bit capable functions for LARGE_FILES support. These | |
12 | - redefs are pointless here so we can override them. */ | |
13 | - | |
14 | -#undef fopen | |
15 | -#undef freopen | |
16 | - | |
17 | -#define fopen(PATH, MODE) fopen_unlocked (PATH, MODE) | |
18 | -#define fdopen(FILDES, MODE) fdopen_unlocked (FILDES, MODE) | |
19 | -#define freopen(PATH, MODE, STREAM) freopen_unlocked (PATH, MODE, STREAM) | |
20 | - | |
21 | -/* The compiler is not a multi-threaded application and therefore we | |
22 | - do not have to use the locking functions. In fact, using the locking | |
23 | - functions can cause the compiler to be significantly slower under | |
24 | - I/O bound conditions (such as -g -O0 on very large source files). | |
25 | - | |
26 | - HAVE_DECL_PUTC_UNLOCKED actually indicates whether or not the stdio | |
27 | - code is multi-thread safe by default. If it is set to 0, then do | |
28 | - not worry about using the _unlocked functions. | |
29 | - | |
30 | - fputs_unlocked, fwrite_unlocked, and fprintf_unlocked are | |
31 | - extensions and need to be prototyped by hand (since we do not | |
32 | - define _GNU_SOURCE). */ | |
33 | - | |
34 | -#if defined HAVE_DECL_PUTC_UNLOCKED && HAVE_DECL_PUTC_UNLOCKED | |
35 | - | |
36 | -# ifdef HAVE_PUTC_UNLOCKED | |
37 | -# undef putc | |
38 | -# define putc(C, Stream) putc_unlocked (C, Stream) | |
39 | -# endif | |
40 | -# ifdef HAVE_PUTCHAR_UNLOCKED | |
41 | -# undef putchar | |
42 | -# define putchar(C) putchar_unlocked (C) | |
43 | -# endif | |
44 | -# ifdef HAVE_GETC_UNLOCKED | |
45 | -# undef getc | |
46 | -# define getc(Stream) getc_unlocked (Stream) | |
47 | -# endif | |
48 | -# ifdef HAVE_GETCHAR_UNLOCKED | |
49 | -# undef getchar | |
50 | -# define getchar() getchar_unlocked () | |
51 | -# endif | |
52 | -# ifdef HAVE_FPUTC_UNLOCKED | |
53 | -# undef fputc | |
54 | -# define fputc(C, Stream) fputc_unlocked (C, Stream) | |
55 | -# endif | |
56 | - | |
57 | -#ifdef __cplusplus | |
58 | -extern "C" { | |
59 | -#endif | |
60 | - | |
61 | -# ifdef HAVE_CLEARERR_UNLOCKED | |
62 | -# undef clearerr | |
63 | -# define clearerr(Stream) clearerr_unlocked (Stream) | |
64 | -# if defined (HAVE_DECL_CLEARERR_UNLOCKED) && !HAVE_DECL_CLEARERR_UNLOCKED | |
65 | -extern void clearerr_unlocked (FILE *); | |
66 | -# endif | |
67 | -# endif | |
68 | -# ifdef HAVE_FEOF_UNLOCKED | |
69 | -# undef feof | |
70 | -# define feof(Stream) feof_unlocked (Stream) | |
71 | -# if defined (HAVE_DECL_FEOF_UNLOCKED) && !HAVE_DECL_FEOF_UNLOCKED | |
72 | -extern int feof_unlocked (FILE *); | |
73 | -# endif | |
74 | -# endif | |
75 | -# ifdef HAVE_FILENO_UNLOCKED | |
76 | -# undef fileno | |
77 | -# define fileno(Stream) fileno_unlocked (Stream) | |
78 | -# if defined (HAVE_DECL_FILENO_UNLOCKED) && !HAVE_DECL_FILENO_UNLOCKED | |
79 | -extern int fileno_unlocked (FILE *); | |
80 | -# endif | |
81 | -# endif | |
82 | -# ifdef HAVE_FFLUSH_UNLOCKED | |
83 | -# undef fflush | |
84 | -# define fflush(Stream) fflush_unlocked (Stream) | |
85 | -# if defined (HAVE_DECL_FFLUSH_UNLOCKED) && !HAVE_DECL_FFLUSH_UNLOCKED | |
86 | -extern int fflush_unlocked (FILE *); | |
87 | -# endif | |
88 | -# endif | |
89 | -# ifdef HAVE_FGETC_UNLOCKED | |
90 | -# undef fgetc | |
91 | -# define fgetc(Stream) fgetc_unlocked (Stream) | |
92 | -# if defined (HAVE_DECL_FGETC_UNLOCKED) && !HAVE_DECL_FGETC_UNLOCKED | |
93 | -extern int fgetc_unlocked (FILE *); | |
94 | -# endif | |
95 | -# endif | |
96 | -# ifdef HAVE_FGETS_UNLOCKED | |
97 | -# undef fgets | |
98 | -# define fgets(S, n, Stream) fgets_unlocked (S, n, Stream) | |
99 | -# if defined (HAVE_DECL_FGETS_UNLOCKED) && !HAVE_DECL_FGETS_UNLOCKED | |
100 | -extern char *fgets_unlocked (char *, int, FILE *); | |
101 | -# endif | |
102 | -# endif | |
103 | -# ifdef HAVE_FPUTS_UNLOCKED | |
104 | -# undef fputs | |
105 | -# define fputs(String, Stream) fputs_unlocked (String, Stream) | |
106 | -# if defined (HAVE_DECL_FPUTS_UNLOCKED) && !HAVE_DECL_FPUTS_UNLOCKED | |
107 | -extern int fputs_unlocked (const char *, FILE *); | |
108 | -# endif | |
109 | -# endif | |
110 | -# ifdef HAVE_FERROR_UNLOCKED | |
111 | -# undef ferror | |
112 | -# define ferror(Stream) ferror_unlocked (Stream) | |
113 | -# if defined (HAVE_DECL_FERROR_UNLOCKED) && !HAVE_DECL_FERROR_UNLOCKED | |
114 | -extern int ferror_unlocked (FILE *); | |
115 | -# endif | |
116 | -# endif | |
117 | -# ifdef HAVE_FREAD_UNLOCKED | |
118 | -# undef fread | |
119 | -# define fread(Ptr, Size, N, Stream) fread_unlocked (Ptr, Size, N, Stream) | |
120 | -# if defined (HAVE_DECL_FREAD_UNLOCKED) && !HAVE_DECL_FREAD_UNLOCKED | |
121 | -extern size_t fread_unlocked (void *, size_t, size_t, FILE *); | |
122 | -# endif | |
123 | -# endif | |
124 | -# ifdef HAVE_FWRITE_UNLOCKED | |
125 | -# undef fwrite | |
126 | -# define fwrite(Ptr, Size, N, Stream) fwrite_unlocked (Ptr, Size, N, Stream) | |
127 | -# if defined (HAVE_DECL_FWRITE_UNLOCKED) && !HAVE_DECL_FWRITE_UNLOCKED | |
128 | -extern size_t fwrite_unlocked (const void *, size_t, size_t, FILE *); | |
129 | -# endif | |
130 | -# endif | |
131 | -# ifdef HAVE_FPRINTF_UNLOCKED | |
132 | -# undef fprintf | |
133 | -/* We can't use a function-like macro here because we don't know if | |
134 | - we have varargs macros. */ | |
135 | -# define fprintf fprintf_unlocked | |
136 | -# if defined (HAVE_DECL_FPRINTF_UNLOCKED) && !HAVE_DECL_FPRINTF_UNLOCKED | |
137 | -extern int fprintf_unlocked (FILE *, const char *, ...); | |
138 | -# endif | |
139 | -# endif | |
140 | - | |
141 | -#ifdef __cplusplus | |
142 | -} | |
143 | -#endif | |
144 | - | |
145 | -#endif | |
146 | - | |
147 | -/* ??? Glibc's fwrite/fread_unlocked macros cause | |
148 | - "warning: signed and unsigned type in conditional expression". */ | |
149 | -#undef fread_unlocked | |
150 | -#undef fwrite_unlocked | |
151 | - | |
152 | /* Include <string> before "safe-ctype.h" to avoid GCC poisoning | |
153 | the ctype macros through safe-ctype.h */ | |
154 |