0
|
1 /* Definitions file for GNU Emacs running on AT&T's System V Release 4
|
|
2 Copyright (C) 1987, 1990 Free Software Foundation, Inc.
|
|
3
|
|
4 This file is part of GNU Emacs.
|
|
5
|
|
6 GNU Emacs is free software; you can redistribute it and/or modify
|
|
7 it under the terms of the GNU General Public License as published by
|
|
8 the Free Software Foundation; either version 2, or (at your option)
|
|
9 any later version.
|
|
10
|
|
11 GNU Emacs is distributed in the hope that it will be useful,
|
|
12 but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
14 GNU General Public License for more details.
|
|
15
|
|
16 You should have received a copy of the GNU General Public License
|
|
17 along with XEmacs; see the file COPYING. If not, write to
|
|
18 the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
|
19 Boston, MA 02111-1307, USA. */
|
|
20
|
|
21 /* Synched up with: FSF 19.31. */
|
|
22
|
|
23 /* This file written by James Van Artsdalen of Dell Computer Corporation.
|
|
24 * james@bigtex.cactus.org. Subsequently improved for Dell 2.2 by Eric
|
|
25 * S. Raymond <esr@snark.thyrsus.com>.
|
|
26 */
|
|
27
|
|
28 /* Use the SysVr3 file for at least base configuration. */
|
|
29
|
|
30 #define DONT_DEFINE_NO_REMAP /* `static' hack not needed */
|
|
31 #include "usg5-3.h"
|
|
32
|
|
33 #define USG5_4
|
|
34
|
|
35 #define LIBS_SYSTEM -lsocket -lnsl -lelf
|
|
36 #define ORDINARY_LINK
|
|
37
|
|
38 #if 0
|
|
39 #ifdef ORDINARY_LINK
|
|
40 #define LIB_STANDARD -lc /usr/ucblib/libucb.a
|
|
41 #else
|
|
42 #define START_FILES pre-crt0.o /usr/ccs/lib/crt1.o /usr/ccs/lib/crti.o /usr/ccs/lib/values-Xt.o
|
|
43 #define LIB_STANDARD -lc /usr/ucblib/libucb.a /usr/ccs/lib/crtn.o
|
|
44 #endif
|
|
45 #else
|
|
46
|
|
47 #ifdef ORDINARY_LINK
|
|
48 #define LIB_STANDARD
|
|
49 #else
|
|
50 #define START_FILES pre-crt0.o /usr/ccs/lib/crt1.o /usr/ccs/lib/crti.o /usr/ccs/lib/values-Xt.o
|
|
51 #define LIB_STANDARD -lc /usr/ccs/lib/crtn.o
|
|
52 #endif
|
|
53 #endif
|
|
54
|
|
55 /* there are no -lg libraries on this system, and no libPW */
|
|
56
|
|
57 #define LIBS_DEBUG
|
|
58
|
|
59 /* No <sioctl.h> */
|
|
60
|
|
61 #define NO_SIOCTL_H
|
|
62
|
|
63 /* Undump with ELF */
|
|
64
|
|
65 #undef COFF
|
|
66
|
|
67 #define UNEXEC unexelf.o
|
|
68
|
|
69 /* Get <sys/ttold.h> to get struct
|
|
70 * tchars. But get <termio.h> first to make sure ttold.h doesn't
|
|
71 * interfere.
|
|
72 */
|
|
73
|
|
74 #ifndef NOT_C_CODE
|
|
75 #include <sys/wait.h>
|
|
76 #endif
|
|
77
|
|
78 #ifdef emacs
|
|
79 #include <sys/filio.h>
|
|
80 #include <termio.h>
|
|
81 #include <sys/ttold.h>
|
|
82 #include <signal.h>
|
|
83 #include <sys/stream.h>
|
|
84 #include <sys/stropts.h>
|
|
85 #include <sys/termios.h>
|
|
86 #endif
|
|
87
|
|
88 #undef BROKEN_SIGIO
|
|
89
|
|
90 /* Some SVr4s don't define NSIG in sys/signal.h for ANSI environments;
|
|
91 * instead, there's a system variable _sys_nsig. Unfortunately, we need the
|
|
92 * constant to dimension an array. So wire in the appropriate value here.
|
|
93 */
|
|
94
|
|
95 #ifndef NSIG
|
|
96 #define NSIG 32
|
|
97 #endif
|
|
98
|
|
99 /* We need bss_end from emacs.c for undumping */
|
|
100
|
|
101 #ifndef USG_SHARED_LIBRARIES
|
|
102 #define USG_SHARED_LIBRARIES
|
|
103 #endif
|
|
104
|
|
105 #define HAVE_PTYS
|
|
106 #undef BROKEN_TIOCGWINSZ
|
|
107 #undef BROKEN_TIOCGETC
|
|
108
|
|
109 /* TIOCGPGRP is broken in SysVr4, so we can't send signals to PTY
|
|
110 subprocesses the usual way. But TIOCSIGNAL does work for PTYs, and
|
|
111 this is all we need. */
|
|
112
|
|
113 #define TIOCSIGSEND TIOCSIGNAL
|
|
114
|
|
115 /* This change means that we don't loop through allocate_pty too many
|
|
116 times in the (rare) event of a failure. */
|
|
117
|
|
118 #undef FIRST_PTY_LETTER
|
|
119 #define FIRST_PTY_LETTER 'z'
|
|
120
|
|
121 /* This sets the name of the master side of the PTY. */
|
|
122
|
|
123 #define PTY_NAME_SPRINTF strcpy (pty_name, "/dev/ptmx");
|
|
124
|
|
125 /* This sets the name of the slave side of the PTY. On SysVr4,
|
|
126 grantpt(3) forks a subprocess, so keep sigchld_handler() from
|
|
127 intercepting that death. If any child but grantpt's should die
|
|
128 within, it should be caught after EMACS_UNBLOCK_SIGNAL. */
|
|
129
|
|
130 /* XEmacs change */
|
|
131 #ifndef NOT_C_CODE
|
|
132 # if !__STDC__ && !defined(STDC_HEADERS)
|
|
133 char *ptsname ();
|
|
134 # endif
|
|
135 #endif
|
|
136
|
|
137 #define PTY_TTY_NAME_SPRINTF \
|
|
138 { \
|
|
139 char *ptyname; \
|
|
140 \
|
|
141 EMACS_BLOCK_SIGCHLD; \
|
|
142 if (grantpt (fd) == -1) \
|
|
143 { close (fd); return -1; } \
|
|
144 EMACS_UNBLOCK_SIGCHLD; \
|
|
145 if (unlockpt (fd) == -1) \
|
|
146 { close (fd); return -1; } \
|
|
147 if (!(ptyname = ptsname (fd))) \
|
|
148 { close (fd); return -1; } \
|
|
149 strncpy (pty_name, ptyname, sizeof (pty_name)); \
|
|
150 pty_name[sizeof (pty_name) - 1] = 0; \
|
|
151 }
|
|
152
|
|
153 /* Push various streams modules onto a PTY channel. */
|
|
154
|
|
155 #define SETUP_SLAVE_PTY \
|
|
156 if (ioctl (xforkin, I_PUSH, "ptem") == -1) \
|
|
157 fatal ("ioctl I_PUSH ptem: errno %d\n", errno); \
|
|
158 if (ioctl (xforkin, I_PUSH, "ldterm") == -1) \
|
|
159 fatal ("ioctl I_PUSH ldterm: errno %d\n", errno); \
|
|
160 if (ioctl (xforkin, I_PUSH, "ttcompat") == -1) \
|
|
161 fatal ("ioctl I_PUSH ttcompat: errno %d\n", errno);
|
|
162
|
|
163 /* Undo the SVr3 X11 library definition */
|
|
164 #undef LIB_X11_LIB
|
|
165
|
|
166 /* The definition of this in s-usg5-3.h is not needed in 5.4. */
|
|
167 /* liblnsl_s should never be used. The _s suffix implies a shared
|
|
168 library, as opposed to a DLL. Share libraries were used in SVR3, and are
|
|
169 available only in order to allow SVR3 binaries to run. They should not be
|
|
170 linked in to new binaries. -- caraway!pinkas@caraway.intel.com. */
|
|
171 #undef LIBX10_SYSTEM
|
|
172 #undef LIBX11_SYSTEM
|
|
173
|
|
174 /* Tell x11term.c and keyboard.c we have the system V streams feature. */
|
|
175 #define SYSV_STREAMS
|
153
|
176 /* On Some SysV System , w3 freeze. If freeze your xemacs , Add below definition */
|
|
177 /* This definition added by Shogo Fujii(shogo@bsd1.kbnes.nec.co.jp) */
|
|
178 #define PROCESS_IO_BLOCKING
|