annotate src/s/dgux.h @ 149:538048ae2ab8 r20-3b1

Import from CVS: tag r20-3b1
author cvs
date Mon, 13 Aug 2007 09:36:16 +0200
parents 376386a54a3c
children 0132846995bd
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1 /* Definitions file for GNU Emacs running on Data General's DG/UX
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
2 version 4.32 upto and including 5.4.1.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
3 Copyright (C) 1994 Free Software Foundation, Inc.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
4
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
5 This file is part of GNU Emacs.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
6
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
7 GNU Emacs is free software; you can redistribute it and/or modify
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
8 it under the terms of the GNU General Public License as published by
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
9 the Free Software Foundation; either version 2, or (at your option)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
10 any later version.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
11
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
12 GNU Emacs is distributed in the hope that it will be useful,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
13 but WITHOUT ANY WARRANTY; without even the implied warranty of
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
14 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
15 GNU General Public License for more details.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
16
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
17 You should have received a copy of the GNU General Public License
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
18 along with XEmacs; see the file COPYING. If not, write to
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
19 the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
20 Boston, MA 02111-1307, USA. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
21
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
22 /* Synched up with: FSF 19.31. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
23
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
24 /*
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
25 * Define symbols to identify the version of Unix this is.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
26 * Define all the symbols that apply correctly.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
27 */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
28
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
29 /* #define UNIPLUS */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
30 /* #define USG5 */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
31 /* #define USG */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
32 /* #define HPUX */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
33 /* #define UMAX */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
34 /* #define BSD4_1 */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
35 #define BSD4_2
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
36 #define BSD4_3
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
37 #define BSD4_4
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
38 #define BSD
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
39
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
40 /* SYSTEM_TYPE should indicate the kind of system you are using.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
41 It sets the Lisp variable system-type. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
42
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
43 #define SYSTEM_TYPE "dgux"
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
44
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
45 /* XEmacs: There is apparently a bug in DGUX involving a SIGTTOU getting
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
46 sent to the process if a background write is attempted when we're
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
47 started under a job-control shell, if we turn on FASYNC (which we
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
48 do when SIGIO is working). So don't use SIGIO. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
49 #define BROKEN_SIGIO
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
50
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
51 /*
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
52 * Define HAVE_UNIX_DOMAIN if the system supports Unix
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
53 * domain sockets.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
54 */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
55
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
56 #define HAVE_UNIX_DOMAIN
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
57
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
58 /*
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
59 * Define HAVE_PTYS if the system supports pty devices.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
60 */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
61
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
62 #define HAVE_PTYS
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
63
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
64 /* If your system uses COFF (Common Object File Format) then define the
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
65 preprocessor symbol "COFF".
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
66
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
67 DGUX can use either COFF or ELF; the default is ELF.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
68 To compile for COFF (or BCS) use the TARGET_BINARY_INTERFACE
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
69 environment variable. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
70
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
71 #if defined(_DGUXCOFF_TARGET) || defined(_DGUXBCS_TARGET)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
72 #undef ELF
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
73 #ifndef COFF
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
74 #define COFF
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
75 #endif /* COFF */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
76 #else /* defined(_DGUXCOFF_TARGET) || defined(_DGUXBCS_TARGET) */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
77 #undef COFF
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
78 #ifndef ELF
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
79 #define ELF
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
80 #endif /* ELF */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
81 #endif /* defined(_DGUXCOFF_TARGET) || defined(_DGUXBCS_TARGET) */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
82
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
83 #ifndef COFF /* People will probably find this apparently unreliable
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
84 till the NFS dumping bug is fixed. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
85
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
86 /* It is possible to undump to ELF with DG/UX 5.4, but for revisions below
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
87 5.4.1 the undump MUST be done on a local file system, or the kernel will
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
88 panic. ELF executables have the advantage of using shared libraries,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
89 while COFF executables will still work on 4.2x systems. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
90
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
91 #define UNEXEC unexelf.o
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
92
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
93 /* This makes sure that all segments in the executable are undumped,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
94 not just text, data, and bss. In the case of Mxdb and shared
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
95 libraries, additional information is stored in other sections.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
96 It does not hurt to have this defined if you don't use Mxdb or
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
97 shared libraries. In fact, it makes no difference. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
98
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
99 /* Necessary for shared libraries and Mxdb debugging information. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
100 #define USG_SHARED_LIBRARIES
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
101 #endif
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
102
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
103 /* define MAIL_USE_FLOCK if the mailer uses flock
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
104 to interlock access to /usr/spool/mail/$USER.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
105 The alternative is that a lock file named
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
106 /usr/spool/mail/$USER.lock. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
107
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
108 /* #define MAIL_USE_FLOCK */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
109
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
110 /* Define a replacement for the baud rate switch, since DG/UX uses a different
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
111 from BSD. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
112
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
113 #define BAUD_CONVERT { 0, 110, 134, 150, 300, 600, 1200, 1800, 2400, \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
114 4800, 9600, 19200, 38400 }
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
115
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
116 /*
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
117 * Make WM Interface Compliant.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
118 */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
119
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
120 #define XICCC
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
121
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
122 /* Here, on a separate page, add any special hacks needed
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
123 to make Emacs work on this system. For example,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
124 you might define certain system call names that don't
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
125 exist on your system, or that do different things on
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
126 your system and must be used only through an encapsulation
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
127 (Which you should place, by convention, in sysdep.c). */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
128
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
129 /* DG/UX SPECIFIC ADDITIONS TO TEMPLATE FOLLOW: */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
130
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
131 /* Use the Berkeley flavors of the library routines, instead of System V. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
132
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
133 #define setpgrp(pid, pgrp) setpgrp2 (pid, pgrp)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
134 #define getpgrp(pid) getpgrp2 (pid)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
135
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
136 /* Use TERMINFO instead of termcap */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
137
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
138 #define TERMINFO
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
139
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
140 /*
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
141 * Send signals to subprocesses using characters.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
142 *
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
143 */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
144
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
145 #define SIGNALS_VIA_CHARACTERS
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
146
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
147 /*
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
148 * Prevent redundant inclusion of termio.h.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
149 */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
150
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
151 #define NO_TERMIO
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
152
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
153 /*
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
154 * Use a Berkeley style sys/wait.h.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
155 * This makes WIF* macros operate on structures instead of ints.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
156 */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
157
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
158 #define _BSD_WAIT_FLAVOR
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
159
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
160 /* #define SYSTEM_MALLOC */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
161
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
162 /* MAKING_MAKEFILE must be defined in "ymakefile" before including config.h */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
163 #ifndef NOT_C_CODE
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
164
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
165 /* Define this if you use System 5 Release 4 Streams */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
166
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
167 #define INTERRUPTIBLE_OPEN
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
168 #define INTERRUPTIBLE_CLOSE
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
169 /* can't hurt to define these, even though read/write should auto restart */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
170 #define INTERRUPTIBLE_IO
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
171
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
172 #endif /* not NOT_C_CODE */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
173
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
174 #ifndef __GNUC__
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
175 #error You must use GCC to compile Emacs on DGUX
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
176 #endif
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
177
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
178 #define ORDINARY_LINK
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
179 #define START_FILES pre-crt0.o
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
180 #define LIB_GCC /usr/lib/gcc/libgcc.a
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
181
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
182 #ifdef _M88KBCS_TARGET
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
183 /* Karl Berry says: the environment
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
184 recommended by gcc (88/open, a.k.a. m88kbcs) doesn't support some system
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
185 functions, and gcc doesn't make it easy to switch environments. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
186 #define NO_GET_LOAD_AVG
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
187 #endif
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
188
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
189 /* definitions for xmakefile production */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
190 #ifdef COFF
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
191
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
192 /* Define the following to use all of the available pty's. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
193
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
194 #define PTY_ITERATION \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
195 for (c = 'p'; c < 't'; c++) \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
196 for (i = 0; (((c == 'p') && (i < 64)) || ((c != 'p') && (i < 16))); i++)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
197
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
198 #define PTY_NAME_SPRINTF \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
199 if (c == 'p') \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
200 sprintf (pty_name, "/dev/pty%c%d", c, i); \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
201 else \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
202 sprintf (pty_name, "/dev/pty%c%x", c, i);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
203
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
204 #define PTY_TTY_NAME_SPRINTF \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
205 if (c == 'p') \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
206 sprintf (pty_name, "/dev/tty%c%d", c, i); \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
207 else \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
208 sprintf (pty_name, "/dev/tty%c%x", c, i);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
209
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
210 #define C_DEBUG_SWITCH -g
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
211
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
212 #else /* not COFF */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
213
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
214 /* We are generating ELF object format. This makes the system more
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
215 SVR4 like. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
216
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
217 #define SVR4
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
218
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
219 /* Pseudo-terminal support under SVR4 only loops to deal with errors. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
220
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
221 #define PTY_ITERATION for (i = 0; i < 1; i++)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
222
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
223 /* This sets the name of the master side of the PTY. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
224
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
225 #define PTY_NAME_SPRINTF strcpy (pty_name, "/dev/ptmx");
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
226
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
227 /* This sets the name of the slave side of the PTY. On SysVr4,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
228 grantpt(3) forks a subprocess, so keep sigchld_handler() from
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
229 intercepting that death. If any child but grantpt's should die
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
230 within, it should be caught after EMACS_UNBLOCK_SIGNAL. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
231
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
232 #define PTY_TTY_NAME_SPRINTF \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
233 { \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
234 char *ptyname; \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
235 \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
236 EMACS_BLOCK_SIGCHLD; \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
237 if (grantpt (fd) == -1) \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
238 { close (fd); return -1; } \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
239 EMACS_UNBLOCK_SIGCHLD; \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
240 if (unlockpt (fd) == -1) \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
241 { close (fd); return -1; } \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
242 if (!(ptyname = ptsname (fd))) \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
243 { close (fd); return -1; } \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
244 strncpy (pty_name, ptyname, sizeof (pty_name)); \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
245 pty_name[sizeof (pty_name) - 1] = 0; \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
246 }
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
247
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
248 /* Push various streams modules onto a PTY channel. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
249
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
250 #define SETUP_SLAVE_PTY \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
251 if (ioctl (xforkin, I_PUSH, "ptem") == -1) \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
252 fatal ("ioctl I_PUSH ptem", errno); \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
253 if (ioctl (xforkin, I_PUSH, "ldterm") == -1) \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
254 fatal ("ioctl I_PUSH ldterm", errno); \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
255 if (ioctl (xforkin, I_PUSH, "ttcompat") == -1) \
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
256 fatal ("ioctl I_PUSH ttcompat", errno);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
257
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
258 #ifdef __GNUC__
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
259 #define C_DEBUG_SWITCH -g -V2 -mversion-03.00 -mstandard
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
260 #endif
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
261
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
262 #endif /* ELF */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
263
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
264 /* Extra stuff which probably should be someplace else but is here out
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
265 of expediency. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
266
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
267 #define LIB_X11_LIB -lX11
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
268 #define LIB_MOTIF -lXm -lgen
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
269
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
270 /* Formerly "BSD_PGRPS" */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
271
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
272 #define SIGIO_REQUIRES_SEPARATE_PROCESS_GROUP