Commit | Line | Data |
---|---|---|
9b71f02b | 1 | /* Definitions file for GNU Emacs running on Data General's DG/UX |
5be71b29 PR |
2 | version 4.32 upto and including 5.4.1. |
3 | Copyright (C) 1994 Free Software Foundation, Inc. | |
9b71f02b JB |
4 | |
5 | This file is part of GNU Emacs. | |
6 | ||
7 | GNU Emacs is free software; you can redistribute it and/or modify | |
8 | it under the terms of the GNU General Public License as published by | |
17385adc | 9 | the Free Software Foundation; either version 2, or (at your option) |
9b71f02b JB |
10 | any later version. |
11 | ||
12 | GNU Emacs is distributed in the hope that it will be useful, | |
13 | but WITHOUT ANY WARRANTY; without even the implied warranty of | |
14 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
15 | GNU General Public License for more details. | |
16 | ||
17 | You should have received a copy of the GNU General Public License | |
18 | along with GNU Emacs; see the file COPYING. If not, write to | |
3b7ad313 EN |
19 | the Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
20 | Boston, MA 02111-1307, USA. */ | |
9b71f02b | 21 | |
9b71f02b JB |
22 | /* |
23 | * Define symbols to identify the version of Unix this is. | |
24 | * Define all the symbols that apply correctly. | |
25 | */ | |
26 | ||
27 | /* #define UNIPLUS */ | |
28 | /* #define USG5 */ | |
29 | /* #define USG */ | |
30 | /* #define HPUX */ | |
31 | /* #define UMAX */ | |
32 | /* #define BSD4_1 */ | |
33 | #define BSD4_2 | |
34 | #define BSD4_3 | |
d1ae7d26 | 35 | #define BSD4_4 |
9b71f02b | 36 | #define BSD |
9b71f02b JB |
37 | |
38 | /* SYSTEM_TYPE should indicate the kind of system you are using. | |
39 | It sets the Lisp variable system-type. */ | |
40 | ||
8f26edca | 41 | #define SYSTEM_TYPE "dgux" |
9b71f02b JB |
42 | |
43 | /* NOMULTIPLEJOBS should be defined if your system's shell | |
44 | does not have "job control" (the ability to stop a program, | |
45 | run some other program, then continue the first one). */ | |
46 | ||
47 | /* #define NOMULTIPLEJOBS */ | |
48 | ||
49 | /* Emacs can read input using SIGIO and buffering characters itself, | |
50 | or using CBREAK mode and making C-g cause SIGINT. | |
51 | The choice is controlled by the variable interrupt_input. | |
52 | Define INTERRUPT_INPUT to make interrupt_input = 1 the default (use SIGIO) | |
53 | ||
54 | SIGIO can be used only on systems that implement it (4.2 and 4.3). | |
eb8c3be9 | 55 | CBREAK mode has two disadvantages |
9b71f02b JB |
56 | 1) At least in 4.2, it is impossible to handle the Meta key properly. |
57 | I hear that in system V this problem does not exist. | |
58 | 2) Control-G causes output to be discarded. | |
59 | I do not know whether this can be fixed in system V. | |
60 | ||
61 | Another method of doing input is planned but not implemented. | |
62 | It would have Emacs fork off a separate process | |
63 | to read the input and send it to the true Emacs process | |
64 | through a pipe. | |
9b71f02b | 65 | |
085a9cd8 | 66 | */ |
9b71f02b | 67 | |
5be71b29 | 68 | #define INTERRUPT_INPUT |
9b71f02b | 69 | |
9b71f02b JB |
70 | /* |
71 | * Define HAVE_SOCKETS if the system supports sockets. | |
72 | */ | |
73 | ||
74 | #define HAVE_SOCKETS | |
75 | ||
d1ae7d26 JB |
76 | /* |
77 | * Define HAVE_UNIX_DOMAIN if the system supports Unix | |
78 | * domain sockets. | |
79 | */ | |
085a9cd8 | 80 | |
d1ae7d26 | 81 | #define HAVE_UNIX_DOMAIN |
085a9cd8 | 82 | |
9b71f02b JB |
83 | /* |
84 | * Define HAVE_PTYS if the system supports pty devices. | |
85 | */ | |
86 | ||
87 | #define HAVE_PTYS | |
88 | ||
085a9cd8 RS |
89 | /* (Assume) we do have vfork. */ |
90 | ||
91 | #define HAVE_VFORK | |
92 | ||
9b71f02b JB |
93 | /* |
94 | * Define NONSYSTEM_DIR_LIBRARY to make Emacs emulate | |
95 | * The 4.2 opendir, etc., library functions. | |
96 | */ | |
97 | ||
98 | /* #define NONSYSTEM_DIR_LIBRARY */ | |
99 | ||
100 | /* Define this symbol if your system has the functions bcopy, etc. */ | |
101 | ||
102 | #define BSTRING | |
103 | ||
104 | /* subprocesses should be defined if you want to | |
105 | have code for asynchronous subprocesses | |
106 | (as used in M-x compile and M-x shell). | |
107 | This is generally OS dependent, and not supported | |
108 | under most USG systems. */ | |
109 | ||
110 | #define subprocesses | |
111 | ||
112 | /* If your system uses COFF (Common Object File Format) then define the | |
e2f4b44c | 113 | preprocessor symbol "COFF". |
9b71f02b | 114 | |
a1005480 RS |
115 | DGUX can use either COFF or ELF; the default is ELF. |
116 | To compile for COFF (or BCS) use the TARGET_BINARY_INTERFACE | |
117 | environment variable. */ | |
e2f4b44c | 118 | |
a1005480 RS |
119 | #if defined(_DGUXCOFF_TARGET) || defined(_DGUXBCS_TARGET) |
120 | #undef ELF | |
121 | #ifndef COFF | |
9b71f02b | 122 | #define COFF |
a1005480 RS |
123 | #endif /* COFF */ |
124 | #else /* defined(_DGUXCOFF_TARGET) || defined(_DGUXBCS_TARGET) */ | |
125 | #undef COFF | |
126 | #ifndef ELF | |
127 | #define ELF | |
128 | #endif /* ELF */ | |
129 | #endif /* defined(_DGUXCOFF_TARGET) || defined(_DGUXBCS_TARGET) */ | |
e2f4b44c RS |
130 | |
131 | #ifndef COFF /* People will probably find this apparently unreliable | |
132 | till the NFS dumping bug is fixed. */ | |
133 | ||
134 | /* It is possible to undump to ELF with DG/UX 5.4, but for revisions below | |
135 | 5.4.1 the undump MUST be done on a local file system, or the kernel will | |
136 | panic. ELF executables have the advantage of using shared libraries, | |
137 | while COFF executables will still work on 4.2x systems. */ | |
138 | ||
139 | #define UNEXEC unexelf.o | |
140 | ||
141 | /* This makes sure that all segments in the executable are undumped, | |
142 | not just text, data, and bss. In the case of Mxdb and shared | |
143 | libraries, additional information is stored in other sections. | |
144 | It does not hurt to have this defined if you don't use Mxdb or | |
145 | shared libraries. In fact, it makes no difference. */ | |
146 | ||
147 | /* Necessary for shared libraries and Mxdb debugging information. */ | |
148 | #define USG_SHARED_LIBRARIES | |
149 | #endif | |
9b71f02b JB |
150 | |
151 | /* define MAIL_USE_FLOCK if the mailer uses flock | |
152 | to interlock access to /usr/spool/mail/$USER. | |
153 | The alternative is that a lock file named | |
154 | /usr/spool/mail/$USER.lock. */ | |
155 | ||
156 | /* #define MAIL_USE_FLOCK */ | |
157 | ||
158 | /* Define CLASH_DETECTION if you want lock files to be written | |
159 | so that Emacs can tell instantly when you try to modify | |
160 | a file that someone else has modified in his Emacs. */ | |
161 | ||
162 | /* #define CLASH_DETECTION */ | |
163 | ||
164 | /* Define a replacement for the baud rate switch, since DG/UX uses a different | |
165 | from BSD. */ | |
166 | ||
167 | #define BAUD_CONVERT { 0, 110, 134, 150, 300, 600, 1200, 1800, 2400, \ | |
168 | 4800, 9600, 19200, 38400 } | |
169 | ||
9b71f02b JB |
170 | /* |
171 | * Define NLIST_STRUCT if the system has nlist.h | |
172 | */ | |
173 | ||
174 | #define NLIST_STRUCT | |
175 | ||
176 | /* | |
177 | * Make WM Interface Compliant. | |
178 | */ | |
179 | ||
180 | #define XICCC | |
181 | ||
182 | /* Here, on a separate page, add any special hacks needed | |
183 | to make Emacs work on this system. For example, | |
184 | you might define certain system call names that don't | |
185 | exist on your system, or that do different things on | |
186 | your system and must be used only through an encapsulation | |
187 | (Which you should place, by convention, in sysdep.c). */ | |
188 | \f | |
189 | /* Some compilers tend to put everything declared static | |
190 | into the initialized data area, which becomes pure after dumping Emacs. | |
191 | On these systems, you must #define static as nothing to foil this. | |
192 | Note that emacs carefully avoids static vars inside functions. */ | |
193 | ||
194 | /* #define static */ | |
195 | ||
196 | /* DG/UX SPECIFIC ADDITIONS TO TEMPLATE FOLLOW: */ | |
197 | ||
198 | /* Use the Berkeley flavors of the library routines, instead of System V. */ | |
199 | ||
200 | #define setpgrp(pid,pgrp) setpgrp2(pid,pgrp) | |
201 | #define getpgrp(pid) getpgrp2(pid) | |
202 | ||
203 | /* Act like Berkeley. */ | |
204 | ||
205 | #define _setjmp(env) sigsetjmp(env,0) | |
206 | #define _longjmp(env,val) longjmp(env,val) | |
207 | ||
208 | /* Use TERMINFO instead of termcap */ | |
209 | ||
210 | #define TERMINFO | |
211 | ||
8f26edca RS |
212 | /* |
213 | * Send signals to subprocesses using characters. | |
214 | * | |
215 | */ | |
216 | ||
217 | #define SIGNALS_VIA_CHARACTERS | |
218 | ||
9b71f02b | 219 | /* |
d1ae7d26 | 220 | * Define HAVE_TERMIOS since this is POSIX, |
085a9cd8 | 221 | * for terminal control. Prevent redundant inclusion of termio.h. |
9b71f02b JB |
222 | */ |
223 | ||
d1ae7d26 | 224 | #define HAVE_TERMIOS |
085a9cd8 | 225 | #define NO_TERMIO |
9b71f02b JB |
226 | |
227 | /* | |
228 | * Use a Berkeley style sys/wait.h. | |
229 | * This makes WIF* macros operate on structures instead of ints. | |
230 | */ | |
231 | ||
232 | #define _BSD_WAIT_FLAVOR | |
233 | ||
9b71f02b JB |
234 | /* |
235 | * Use BSD and POSIX-style signals. This is crucial! | |
236 | */ | |
237 | ||
bb292747 | 238 | /* #define SYSTEM_MALLOC */ |
dbba802a | 239 | |
9b71f02b | 240 | /* MAKING_MAKEFILE must be defined in "ymakefile" before including config.h */ |
24916110 | 241 | #ifndef NOT_C_CODE |
9b71f02b JB |
242 | |
243 | /* Make sure signal.h is included so macros below don't mess with it. */ | |
244 | /* DG/UX include files prevent multiple inclusion. */ | |
245 | ||
246 | #include <signal.h> | |
247 | ||
d1ae7d26 JB |
248 | /* but undefine the sigmask and sigpause macros since they will get |
249 | #define'd later. */ | |
250 | #undef sigmask | |
251 | #undef sigpause | |
252 | ||
9b71f02b JB |
253 | #define POSIX_SIGNALS |
254 | ||
9b71f02b | 255 | /* Define this if you use System 5 Release 4 Streams */ |
9b71f02b JB |
256 | #define open sys_open |
257 | #define close sys_close | |
258 | #define read sys_read | |
259 | #define write sys_write | |
260 | ||
1fe85c45 RS |
261 | #define INTERRUPTIBLE_OPEN |
262 | #define INTERRUPTIBLE_CLOSE | |
9b71f02b | 263 | /* can't hurt to define these, even though read/write should auto restart */ |
1fe85c45 | 264 | #define INTERRUPTIBLE_IO |
9b71f02b JB |
265 | |
266 | /* Can't use sys_signal because then etc/server.c would need sysdep.o. */ | |
d1ae7d26 | 267 | extern struct sigaction act, oact; |
9b71f02b JB |
268 | #define signal(SIG,FUNC) berk_signal(SIG,FUNC) |
269 | ||
24916110 RS |
270 | #endif /* not NOT_C_CODE */ |
271 | ||
272 | #ifndef __GNUC__ | |
273 | #error You must use GCC to compiler Emascs on DGUX | |
274 | #endif | |
d1ae7d26 | 275 | |
5be71b29 | 276 | #define ORDINARY_LINK |
d1ae7d26 | 277 | #define START_FILES pre-crt0.o |
d1ae7d26 | 278 | #define LIB_GCC /usr/lib/gcc/libgcc.a |
6cb37d97 | 279 | |
1f9ecc7b | 280 | #ifdef _M88KBCS_TARGET |
6cb37d97 RS |
281 | /* Karl Berry says: the environment |
282 | recommended by gcc (88/open, a.k.a. m88kbcs) doesn't support some system | |
283 | functions, and gcc doesn't make it easy to switch environments. */ | |
284 | #define NO_GET_LOAD_AVG | |
285 | #endif | |
e2f4b44c RS |
286 | \f |
287 | /* definitions for xmakefile production */ | |
288 | #ifdef COFF | |
085a9cd8 RS |
289 | |
290 | /* Define the following to use all of the available pty's. */ | |
291 | ||
292 | #define PTY_ITERATION \ | |
293 | for (c = 'p'; c < 't'; c++) \ | |
294 | for (i = 0; (((c == 'p') && (i < 64)) || ((c != 'p') && (i < 16))); i++) | |
295 | ||
296 | #define PTY_NAME_SPRINTF \ | |
297 | if (c == 'p') \ | |
298 | sprintf (pty_name, "/dev/pty%c%d", c, i); \ | |
299 | else \ | |
300 | sprintf (pty_name, "/dev/pty%c%x", c, i); | |
301 | ||
302 | #define PTY_TTY_NAME_SPRINTF \ | |
303 | if (c == 'p') \ | |
304 | sprintf (pty_name, "/dev/tty%c%d", c, i); \ | |
305 | else \ | |
306 | sprintf (pty_name, "/dev/tty%c%x", c, i); | |
307 | ||
085a9cd8 RS |
308 | #define C_DEBUG_SWITCH -g |
309 | ||
e2f4b44c RS |
310 | #else /* not COFF */ |
311 | ||
5be71b29 PR |
312 | /* We are generating ELF object format. This makes the system more |
313 | SVR4 like. */ | |
314 | ||
315 | #define SVR4 | |
316 | ||
4ba13117 RS |
317 | /* Pseudo-terminal support under SVR4 only loops to deal with errors. */ |
318 | ||
319 | #define PTY_ITERATION for (i = 0; i < 1; i++) | |
320 | ||
321 | /* This sets the name of the master side of the PTY. */ | |
322 | ||
323 | #define PTY_NAME_SPRINTF strcpy (pty_name, "/dev/ptmx"); | |
324 | ||
325 | /* This sets the name of the slave side of the PTY. On SysVr4, | |
326 | grantpt(3) forks a subprocess, so keep sigchld_handler() from | |
327 | intercepting that death. If any child but grantpt's should die | |
328 | within, it should be caught after sigrelse(2). */ | |
329 | ||
330 | #define PTY_TTY_NAME_SPRINTF \ | |
331 | { \ | |
332 | char *ptsname(), *ptyname; \ | |
333 | \ | |
334 | sigblock(sigmask(SIGCLD)); \ | |
335 | if (grantpt(fd) == -1) \ | |
336 | fatal("could not grant slave pty"); \ | |
337 | sigunblock(sigmask(SIGCLD)); \ | |
338 | if (unlockpt(fd) == -1) \ | |
339 | fatal("could not unlock slave pty"); \ | |
340 | if (!(ptyname = ptsname(fd))) \ | |
341 | fatal ("could not enable slave pty"); \ | |
342 | strncpy(pty_name, ptyname, sizeof(pty_name)); \ | |
343 | pty_name[sizeof(pty_name) - 1] = 0; \ | |
344 | } | |
345 | ||
346 | /* Push various streams modules onto a PTY channel. */ | |
347 | ||
348 | #define SETUP_SLAVE_PTY \ | |
349 | if (ioctl (xforkin, I_PUSH, "ptem") == -1) \ | |
350 | fatal ("ioctl I_PUSH ptem", errno); \ | |
351 | if (ioctl (xforkin, I_PUSH, "ldterm") == -1) \ | |
352 | fatal ("ioctl I_PUSH ldterm", errno); \ | |
353 | if (ioctl (xforkin, I_PUSH, "ttcompat") == -1) \ | |
354 | fatal ("ioctl I_PUSH ttcompat", errno); | |
355 | ||
4ed715c1 | 356 | #ifdef __GNUC__ |
d1ae7d26 | 357 | #define C_DEBUG_SWITCH -g -V2 -mversion-03.00 -mstandard |
4ed715c1 | 358 | #endif |
5be71b29 PR |
359 | |
360 | #endif /* ELF */ | |
dea95cc2 | 361 | |
085a9cd8 RS |
362 | /* Extra stuff which probably should be someplace else but is here out |
363 | of expediency. */ | |
651c847c | 364 | |
085a9cd8 | 365 | #define LIB_X11_LIB -lX11 |
37849f29 | 366 | #define LIB_MOTIF -lXm -lgen |
a9f7a967 RS |
367 | |
368 | /* Process groups work in the traditional BSD manner. */ | |
369 | ||
370 | #define BSD_PGRPS |