Mercurial > hg > xemacs-beta
comparison src/sysdep.h @ 398:74fd4e045ea6 r21-2-29
Import from CVS: tag r21-2-29
author | cvs |
---|---|
date | Mon, 13 Aug 2007 11:13:30 +0200 |
parents | 8626e4521993 |
children | 2f8bb876ab1d |
comparison
equal
deleted
inserted
replaced
397:f4aeb21a5bad | 398:74fd4e045ea6 |
---|---|
18 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, | 18 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
19 Boston, MA 02111-1307, USA. */ | 19 Boston, MA 02111-1307, USA. */ |
20 | 20 |
21 /* Synched up with: FSF 19.30. Split out of sysdep.c/emacs.c. */ | 21 /* Synched up with: FSF 19.30. Split out of sysdep.c/emacs.c. */ |
22 | 22 |
23 #ifndef _XEMACS_SYSDEP_H_ | 23 #ifndef INCLUDED_sysdep_h_ |
24 #define _XEMACS_SYSDEP_H_ | 24 #define INCLUDED_sysdep_h_ |
25 | 25 |
26 #include <setjmp.h> | 26 #include <setjmp.h> |
27 | 27 |
28 #ifndef WINDOWSNT | |
28 extern char **environ; | 29 extern char **environ; |
29 | 30 #endif |
30 struct emacs_tty; | |
31 int emacs_get_tty (int fd, struct emacs_tty *settings); | |
32 int emacs_set_tty (int fd, struct emacs_tty *settings, int waitp); | |
33 | 31 |
34 int eight_bit_tty (struct device *d); | 32 int eight_bit_tty (struct device *d); |
35 | 33 |
36 void stuff_char (struct console *con, int c); | 34 void stuff_char (struct console *con, int c); |
37 | 35 |
46 int get_pty_max_bytes (int fd); | 44 int get_pty_max_bytes (int fd); |
47 Bufbyte get_eof_char (int fd); | 45 Bufbyte get_eof_char (int fd); |
48 | 46 |
49 /* Wait for subprocess with process id `pid' to terminate and | 47 /* Wait for subprocess with process id `pid' to terminate and |
50 make sure it will get eliminated (not remain forever as a zombie) */ | 48 make sure it will get eliminated (not remain forever as a zombie) */ |
49 #ifdef WINDOWSNT | |
50 #include <windows.h> | |
51 void wait_for_termination (HANDLE pid); | |
52 #else | |
51 void wait_for_termination (int pid); | 53 void wait_for_termination (int pid); |
54 #endif | |
52 | 55 |
53 /* flush any pending output | 56 /* flush any pending output |
54 * (may flush input as well; it does not matter the way we use it) | 57 * (may flush input as well; it does not matter the way we use it) |
55 */ | 58 */ |
56 void flush_pending_output (int channel); | 59 void flush_pending_output (int channel); |
76 naturally interruptible. */ | 79 naturally interruptible. */ |
77 | 80 |
78 extern JMP_BUF break_system_call_jump; | 81 extern JMP_BUF break_system_call_jump; |
79 extern volatile int can_break_system_calls; | 82 extern volatile int can_break_system_calls; |
80 | 83 |
81 int sys_write_1 (int fildes, CONST void *buf, size_t nbyte, | 84 ssize_t sys_write_1 (int fildes, const void *buf, size_t nbyte, |
82 int allow_quit); | 85 int allow_quit); |
83 int sys_read_1 (int fildes, void *buf, size_t nbyte, | 86 ssize_t sys_read_1 (int fildes, void *buf, size_t nbyte, |
84 int allow_quit); | 87 int allow_quit); |
85 | 88 |
86 /* Call these functions if you want to change some terminal parameter -- | 89 /* Call these functions if you want to change some terminal parameter -- |
87 reset the console, change the parameter, and init it again. */ | 90 reset the console, change the parameter, and init it again. */ |
88 void init_one_console (struct console *c); | 91 void init_one_console (struct console *c); |
89 void reset_one_console (struct console *c); | 92 void reset_one_console (struct console *c); |
140 | 143 |
141 /* Get_system_name returns as its value a string for system-name to return. */ | 144 /* Get_system_name returns as its value a string for system-name to return. */ |
142 void init_system_name (void); | 145 void init_system_name (void); |
143 | 146 |
144 #ifndef HAVE_GETCWD | 147 #ifndef HAVE_GETCWD |
145 char *getcwd (char *pathname, int size); | 148 char *getcwd (char *pathname, size_t size); |
146 #endif | 149 #endif |
147 | 150 |
148 #ifndef HAVE_RENAME | 151 #ifndef HAVE_RENAME |
149 int rename (CONST char *from, CONST char *to); | 152 int rename (const char *from, const char *to); |
150 #endif | 153 #endif |
151 | 154 |
152 #ifndef HAVE_DUP2 | 155 #ifndef HAVE_DUP2 |
153 int dup2 (int oldd, int newd); | 156 int dup2 (int oldd, int newd); |
154 #endif | 157 #endif |
156 #ifndef HAVE_STRERROR | 159 #ifndef HAVE_STRERROR |
157 /* X11R6 defines strerror as a macro */ | 160 /* X11R6 defines strerror as a macro */ |
158 # ifdef strerror | 161 # ifdef strerror |
159 # undef strerror | 162 # undef strerror |
160 # endif | 163 # endif |
161 CONST char *strerror (int); | 164 const char *strerror (int); |
162 #endif | 165 #endif |
163 | 166 |
164 #ifdef WINDOWSNT | 167 #ifdef WINDOWSNT |
165 void mswindows_set_errno (unsigned long win32_error); | 168 void mswindows_set_errno (unsigned long win32_error); |
166 void mswindows_set_last_errno (void); | 169 void mswindows_set_last_errno (void); |
167 #endif | 170 #endif |
168 | 171 |
169 int interruptible_open (CONST char *path, int oflag, int mode); | 172 int interruptible_open (const char *path, int oflag, int mode); |
170 | 173 |
171 #ifndef HAVE_H_ERRNO | 174 #ifndef HAVE_H_ERRNO |
172 extern int h_errno; | 175 extern int h_errno; |
173 #endif | 176 #endif |
174 | 177 |
175 #ifdef HAVE_REALPATH | 178 #ifdef HAVE_REALPATH |
176 #define xrealpath realpath | 179 #define xrealpath realpath |
177 #else | 180 #else |
178 char *xrealpath(CONST char *path, char resolved_path []); | 181 char *xrealpath(const char *path, char resolved_path []); |
179 #endif | 182 #endif |
180 | 183 |
181 #endif /* _XEMACS_SYSDEP_H_ */ | 184 #endif /* INCLUDED_sysdep_h_ */ |