178
|
1 #ifndef __micro_c__aaa
|
61
|
2 #include "/usr/include/stdio.h"
|
|
3 #else
|
|
4
|
18
|
5 #ifdef __APPLE__
|
0
|
6
|
116
|
7 typedef struct {
|
|
8 /* char pad[96]; */
|
|
9 char pad[88];
|
|
10 } FILE;
|
18
|
11 extern FILE __sF[];
|
|
12 #define stdin (&__sF[0])
|
|
13 #define stdout (&__sF[1])
|
|
14 #define stderr (&__sF[2])
|
|
15
|
|
16 #else
|
116
|
17 typedef struct {
|
|
18 /* this is all wrong, but so what? */
|
|
19 /* char pad[96]; */
|
|
20 char pad[148];
|
|
21 } FILE;
|
21
|
22 #ifdef bsd
|
0
|
23 extern FILE __sstdin;
|
|
24 extern FILE __sstdout;
|
|
25 extern FILE __sstderr;
|
|
26
|
|
27 #define stdin (&__sstdin)
|
|
28 #define stdout (&__sstdout)
|
|
29 #define stderr (&__sstderr)
|
21
|
30 #else
|
|
31 /* new Linux */
|
|
32 extern FILE *stdin;
|
|
33 extern FILE *stdout;
|
|
34 extern FILE *stderr;
|
|
35 /*
|
|
36 #define stdin stdin
|
|
37 #define stdout stdout
|
|
38 #define stderr stderr
|
|
39 */
|
|
40 #endif
|
18
|
41 #endif
|
19
|
42
|
0
|
43 #define BUFSIZ 1024 /* size of buffer used by setbuf */
|
|
44 #define EOF (-1)
|
|
45 #define NULL 0
|
|
46
|
|
47 typedef int size_t;
|
|
48 typedef /*long*/ int fpos_t;
|
|
49 typedef void *__gnuc_va_list;
|
|
50
|
|
51 void clearerr(FILE *);
|
|
52 int fclose(FILE *);
|
|
53 int feof(FILE *);
|
|
54 int ferror(FILE *);
|
|
55 int fflush(FILE *);
|
|
56 int fgetc(FILE *);
|
|
57 int fgetpos(FILE *, fpos_t *);
|
|
58 int fileno(FILE *);
|
|
59 void flockfile();
|
19
|
60
|
0
|
61 int fprintf(FILE *, const char *, ...);
|
|
62 int fpurge();
|
|
63 int fputc(int, FILE *);
|
|
64 int fputs(const char *, FILE *);
|
|
65 size_t fread(void *, size_t, size_t, FILE *);
|
|
66 int fscanf(FILE *, const char *, ...);
|
19
|
67
|
0
|
68 /* int fseek(FILE *, long int, int); */
|
19
|
69
|
0
|
70 int fsetpos(FILE *, const fpos_t *);
|
|
71 long ftell(FILE *);
|
|
72 int ftrylockfile();
|
|
73 void funlockfile();
|
|
74 size_t fwrite(const void *, size_t, size_t, FILE *);
|
|
75 int getc(FILE *);
|
|
76 int getc_unlocked();
|
|
77 int getchar(void);
|
|
78 int getchar_unlocked();
|
|
79 int getw(FILE *);
|
|
80 int pclose(FILE *);
|
|
81 void perror(const char *);
|
|
82 int printf(const char *, ...);
|
|
83 int putc(int, FILE *);
|
|
84 int putc_unlocked();
|
|
85 int putchar(int);
|
|
86 int putchar_unlocked();
|
|
87 int puts(const char *);
|
|
88 int putw(int, FILE *);
|
|
89 int remove(const char *);
|
|
90 int rename (const char *, const char *);
|
|
91 void rewind(FILE *);
|
|
92 int scanf(const char *, ...);
|
|
93 void setbuf(FILE *, char *);
|
|
94 void setbuffer();
|
|
95 int setlinebuf();
|
|
96 int setvbuf(FILE *, char *, int, size_t);
|
|
97 int snprintf();
|
|
98 int sprintf(char *, const char *, ...);
|
|
99 int sscanf(const char *, const char *, ...);
|
|
100 int ungetc(int, FILE *);
|
|
101 int vfprintf(FILE *, const char *, __gnuc_va_list);
|
|
102 int vfscanf();
|
|
103 int vprintf(const char *, __gnuc_va_list);
|
|
104 int vscanf();
|
|
105 int vsnprintf();
|
|
106 int vsprintf(char *, const char *, __gnuc_va_list);
|
|
107 int vsscanf();
|
|
108 char *ctermid(char *);
|
|
109 FILE *fdopen(int, const char *);
|
|
110 char *fgetln();
|
|
111 char *fgets(char *, int, FILE *);
|
|
112 FILE *fopen(const char *, const char *);
|
|
113 FILE *freopen(const char *, const char *, FILE *);
|
|
114 FILE *funopen();
|
|
115 char *gets(char *);
|
|
116 FILE *popen(const char *, const char *);
|
|
117 char *tempnam(const char *, const char *);
|
|
118 FILE *tmpfile(void);
|
|
119 char *tmpnam(char *);
|
61
|
120 #endif
|