(Fx_create_frame): Move unwind_create_frame setup down.
[emacs.git] / src / s / dgux.h
blobd48d95709c82fec73946ff583eb03b0e620549cf
1 /* Definitions file for GNU Emacs running on Data General's DG/UX
2 version 4.32 upto and including 5.4.1.
3 Copyright (C) 1994, 1999, 2002, 2003, 2004,
4 2005, 2006 Free Software Foundation, Inc.
6 This file is part of GNU Emacs.
8 GNU Emacs is free software; you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation; either version 2, or (at your option)
11 any later version.
13 GNU Emacs is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 GNU General Public License for more details.
18 You should have received a copy of the GNU General Public License
19 along with GNU Emacs; see the file COPYING. If not, write to
20 the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
21 Boston, MA 02110-1301, USA. */
24 * Define symbols to identify the version of Unix this is.
25 * Define all the symbols that apply correctly.
28 /* #define UNIPLUS */
29 /* #define USG5 */
30 /* #define USG */
31 /* #define HPUX */
32 /* #define UMAX */
33 /* #define BSD4_1 */
34 #define BSD4_2
35 #define BSD4_3
36 #define BSD4_4
37 #define BSD_SYSTEM
39 /* SYSTEM_TYPE should indicate the kind of system you are using.
40 It sets the Lisp variable system-type. */
42 #define SYSTEM_TYPE "dgux"
44 /* NOMULTIPLEJOBS should be defined if your system's shell
45 does not have "job control" (the ability to stop a program,
46 run some other program, then continue the first one). */
48 /* #define NOMULTIPLEJOBS */
50 /* Emacs can read input using SIGIO and buffering characters itself,
51 or using CBREAK mode and making C-g cause SIGINT.
52 The choice is controlled by the variable interrupt_input.
53 Define INTERRUPT_INPUT to make interrupt_input = 1 the default (use SIGIO)
55 SIGIO can be used only on systems that implement it (4.2 and 4.3).
56 CBREAK mode has two disadvantages
57 1) At least in 4.2, it is impossible to handle the Meta key properly.
58 I hear that in system V this problem does not exist.
59 2) Control-G causes output to be discarded.
60 I do not know whether this can be fixed in system V.
62 Another method of doing input is planned but not implemented.
63 It would have Emacs fork off a separate process
64 to read the input and send it to the true Emacs process
65 through a pipe.
69 #define INTERRUPT_INPUT
72 * Define HAVE_SOCKETS if the system supports sockets.
75 #define HAVE_SOCKETS
78 * Define HAVE_UNIX_DOMAIN if the system supports Unix
79 * domain sockets.
82 #define HAVE_UNIX_DOMAIN
85 * Define HAVE_PTYS if the system supports pty devices.
88 #define HAVE_PTYS
91 * Define NONSYSTEM_DIR_LIBRARY to make Emacs emulate
92 * The 4.2 opendir, etc., library functions.
95 /* #define NONSYSTEM_DIR_LIBRARY */
97 /* Define this symbol if your system has the functions bcopy, etc. */
99 #define BSTRING
101 /* subprocesses should be defined if you want to
102 have code for asynchronous subprocesses
103 (as used in M-x compile and M-x shell).
104 This is generally OS dependent, and not supported
105 under most USG systems. */
107 #define subprocesses
109 /* If your system uses COFF (Common Object File Format) then define the
110 preprocessor symbol "COFF".
112 DGUX can use either COFF or ELF; the default is ELF.
113 To compile for COFF (or BCS) use the TARGET_BINARY_INTERFACE
114 environment variable. */
116 #if defined(_DGUXCOFF_TARGET) || defined(_DGUXBCS_TARGET)
117 #undef ELF
118 #ifndef COFF
119 #define COFF
120 #endif /* COFF */
121 #else /* defined(_DGUXCOFF_TARGET) || defined(_DGUXBCS_TARGET) */
122 #undef COFF
123 #ifndef ELF
124 #define ELF
125 #endif /* ELF */
126 #endif /* defined(_DGUXCOFF_TARGET) || defined(_DGUXBCS_TARGET) */
128 #ifndef COFF /* People will probably find this apparently unreliable
129 till the NFS dumping bug is fixed. */
131 /* It is possible to undump to ELF with DG/UX 5.4, but for revisions below
132 5.4.1 the undump MUST be done on a local file system, or the kernel will
133 panic. ELF executables have the advantage of using shared libraries,
134 while COFF executables will still work on 4.2x systems. */
136 #define UNEXEC unexelf.o
138 /* This makes sure that all segments in the executable are undumped,
139 not just text, data, and bss. In the case of Mxdb and shared
140 libraries, additional information is stored in other sections.
141 It does not hurt to have this defined if you don't use Mxdb or
142 shared libraries. In fact, it makes no difference. */
144 /* Necessary for shared libraries and Mxdb debugging information. */
145 #define USG_SHARED_LIBRARIES
146 #endif
148 /* define MAIL_USE_FLOCK if the mailer uses flock
149 to interlock access to /usr/spool/mail/$USER.
150 The alternative is that a lock file named
151 /usr/spool/mail/$USER.lock. */
153 /* #define MAIL_USE_FLOCK */
155 /* Define CLASH_DETECTION if you want lock files to be written
156 so that Emacs can tell instantly when you try to modify
157 a file that someone else has modified in his Emacs. */
159 /* #define CLASH_DETECTION */
161 /* Define a replacement for the baud rate switch, since DG/UX uses a different
162 from BSD. */
164 #define BAUD_CONVERT { 0, 110, 134, 150, 300, 600, 1200, 1800, 2400, \
165 4800, 9600, 19200, 38400 }
168 * Make WM Interface Compliant.
171 #define XICCC
173 /* Here, on a separate page, add any special hacks needed
174 to make Emacs work on this system. For example,
175 you might define certain system call names that don't
176 exist on your system, or that do different things on
177 your system and must be used only through an encapsulation
178 (Which you should place, by convention, in sysdep.c). */
180 /* Some compilers tend to put everything declared static
181 into the initialized data area, which becomes pure after dumping Emacs.
182 On these systems, you must #define static as nothing to foil this.
183 Note that emacs carefully avoids static vars inside functions. */
185 /* #define static */
187 /* DG/UX SPECIFIC ADDITIONS TO TEMPLATE FOLLOW: */
189 /* Use the Berkeley flavors of the library routines, instead of System V. */
191 #define setpgrp(pid,pgrp) setpgrp2(pid,pgrp)
192 #define getpgrp(pid) getpgrp2(pid)
194 /* Act like Berkeley. */
196 #define _setjmp(env) sigsetjmp(env,0)
197 #define _longjmp(env,val) longjmp(env,val)
199 /* Use TERMINFO instead of termcap */
201 #define TERMINFO
204 * Send signals to subprocesses using characters.
208 #define SIGNALS_VIA_CHARACTERS
211 * Define HAVE_TERMIOS since this is POSIX,
212 * for terminal control. Prevent redundant inclusion of termio.h.
215 #define HAVE_TERMIOS
216 #define NO_TERMIO
219 * Use a Berkeley style sys/wait.h.
220 * This makes WIF* macros operate on structures instead of ints.
223 #define _BSD_WAIT_FLAVOR
226 * Use BSD and POSIX-style signals. This is crucial!
229 /* #define SYSTEM_MALLOC */
231 /* MAKING_MAKEFILE must be defined in "ymakefile" before including config.h */
232 #ifndef NOT_C_CODE
234 /* Make sure signal.h is included so macros below don't mess with it. */
235 /* DG/UX include files prevent multiple inclusion. */
237 #include <signal.h>
239 /* but undefine the sigmask and sigpause macros since they will get
240 #define'd later. */
241 #undef sigmask
242 #undef sigpause
244 #define POSIX_SIGNALS
246 #ifndef NO_DGUX_SIGNAL_REDEF
247 /* Can't use sys_signal because then etc/server.c would need sysdep.o. */
248 extern struct sigaction act, oact;
249 #define signal(SIG,FUNC) berk_signal(SIG,FUNC)
250 #endif
252 #endif /* not NOT_C_CODE */
254 #ifndef __GNUC__
255 #error You must use GCC to compiler Emascs on DGUX
256 #endif
258 #define ORDINARY_LINK
259 #define START_FILES pre-crt0.o
260 #define LIB_GCC /usr/lib/gcc/libgcc.a
262 #ifdef _M88KBCS_TARGET
263 /* Karl Berry says: the environment
264 recommended by gcc (88/open, a.k.a. m88kbcs) doesn't support some system
265 functions, and gcc doesn't make it easy to switch environments. */
266 #define NO_GET_LOAD_AVG
267 #endif
269 /* definitions for xmakefile production */
270 #ifdef COFF
272 /* Define the following to use all of the available pty's. */
274 #define PTY_ITERATION \
275 for (c = 'p'; c < 't'; c++) \
276 for (i = 0; (((c == 'p') && (i < 64)) || ((c != 'p') && (i < 16))); i++)
278 #define PTY_NAME_SPRINTF \
279 if (c == 'p') \
280 sprintf (pty_name, "/dev/pty%c%d", c, i); \
281 else \
282 sprintf (pty_name, "/dev/pty%c%x", c, i);
284 #define PTY_TTY_NAME_SPRINTF \
285 if (c == 'p') \
286 sprintf (pty_name, "/dev/tty%c%d", c, i); \
287 else \
288 sprintf (pty_name, "/dev/tty%c%x", c, i);
290 #define C_DEBUG_SWITCH -g
292 #else /* not COFF */
294 /* We are generating ELF object format. This makes the system more
295 SVR4 like. */
297 #define SVR4
299 /* Pseudo-terminal support under SVR4 only loops to deal with errors. */
301 #define PTY_ITERATION for (i = 0; i < 1; i++)
303 /* This sets the name of the master side of the PTY. */
305 #define PTY_NAME_SPRINTF strcpy (pty_name, "/dev/ptmx");
307 /* This sets the name of the slave side of the PTY. On SysVr4,
308 grantpt(3) forks a subprocess, so keep sigchld_handler() from
309 intercepting that death. If any child but grantpt's should die
310 within, it should be caught after sigrelse(2). */
312 #define PTY_TTY_NAME_SPRINTF \
314 char *ptsname(), *ptyname; \
316 sigblock(sigmask(SIGCLD)); \
317 if (grantpt(fd) == -1) \
318 fatal("could not grant slave pty"); \
319 sigunblock(sigmask(SIGCLD)); \
320 if (unlockpt(fd) == -1) \
321 fatal("could not unlock slave pty"); \
322 if (!(ptyname = ptsname(fd))) \
323 fatal ("could not enable slave pty"); \
324 strncpy(pty_name, ptyname, sizeof(pty_name)); \
325 pty_name[sizeof(pty_name) - 1] = 0; \
328 /* Push various streams modules onto a PTY channel. */
330 #define SETUP_SLAVE_PTY \
331 if (ioctl (xforkin, I_PUSH, "ptem") == -1) \
332 fatal ("ioctl I_PUSH ptem", errno); \
333 if (ioctl (xforkin, I_PUSH, "ldterm") == -1) \
334 fatal ("ioctl I_PUSH ldterm", errno); \
335 if (ioctl (xforkin, I_PUSH, "ttcompat") == -1) \
336 fatal ("ioctl I_PUSH ttcompat", errno);
338 #ifdef __GNUC__
339 #define C_DEBUG_SWITCH -g -V2 -mversion-03.00 -mstandard
340 #endif
342 #endif /* ELF */
344 /* Extra stuff which probably should be someplace else but is here out
345 of expediency. */
347 #define LIB_X11_LIB -lX11
348 #define LIB_MOTIF -lXm -lgen
350 /* Process groups work in the traditional BSD manner. */
352 #define BSD_PGRPS
354 /* arch-tag: 1b6d117d-82d2-4480-a6d0-3f7a8360f658
355 (do not change this comment) */