Mercurial > emacs
annotate src/s/dgux4.h @ 71909:c1f41b1e2d66
(Antinews): Mention redisplay function.
The kbd macro existed, but was not documented, before 22.x.
Function pos-visible-in-window-p is not new in 22.x, just enhanced.
author | Kim F. Storm <storm@cua.dk> |
---|---|
date | Fri, 14 Jul 2006 23:32:14 +0000 |
parents | 3bd95f4f2941 |
children | e90d04cd455a c5406394f567 |
rev | line source |
---|---|
18097 | 1 /* Definitions file for GNU Emacs running on Data General's DG/UX |
2 Release 4.10 and above. | |
68651
3bd95f4f2941
Update years in copyright notice; nfc.
Thien-Thi Nguyen <ttn@gnuvola.org>
parents:
64769
diff
changeset
|
3 Copyright (C) 1996, 2002, 2003, 2004, 2005, |
3bd95f4f2941
Update years in copyright notice; nfc.
Thien-Thi Nguyen <ttn@gnuvola.org>
parents:
64769
diff
changeset
|
4 2006 Free Software Foundation, Inc. |
18097 | 5 |
6 This file is part of GNU Emacs. | |
7 | |
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. | |
12 | |
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. | |
17 | |
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 | |
64092 | 20 the Free Software Foundation, 51 Franklin Street, Fifth Floor, |
21 Boston, MA 02110-1301, USA. */ | |
18097 | 22 |
23 /* This file was written by Roderick Schertler <roderick@ibcinc.com>, | |
24 contact me if you have problems with or comments about running Emacs | |
25 on dgux. | |
26 | |
27 A number of things in the older dgux*.h files don't make sense to me, | |
28 but since I'm relying on memory and I don't have any older dgux | |
29 systems installed on which to test changes I'm undoing or fixing them | |
30 here rather than fixing them at the source. */ | |
31 | |
32 /* In dgux.h it says "Can't use sys_signal because then etc/server.c | |
33 would need sysdep.o." and then it #defines signal() to be | |
34 berk_signal(), but emacsserver.c does `#undef signal' anyway, so that | |
35 doesn't make sense. | |
36 | |
37 Further, sys_signal() in sysdep.c already had a special case for | |
38 #ifdef DGUX, it called berk_signal() explicitly. I've removed that | |
39 special case because it also didn't make sense: All versions of dgux | |
40 which the dgux*.h headers take into account have POSIX signals | |
41 (POSIX_SIGNALS is #defined in dgux.h). The comments in sys_signal() | |
42 even acknowledged this (saying that the special berk_signal() case | |
43 wasn't really necessary), they said that sys_signal() was using | |
44 berk_signal() instead of sigaction() for efficiency. Since both give | |
45 reliable signals neither has to be invoked within the handler. If | |
46 the efficiency that the comments were talking about is the overhead | |
47 of setting up the sigaction struct rather than just passing the | |
48 function pointer in (which is the only efficiency I can think of) | |
49 then that's a needless optimization, the Emacs sources do better | |
50 without the special case. | |
51 | |
52 The following definition will prevent dgux.h from re-defining | |
53 signal(). I can't just say `#undef signal' after including dgux.h | |
54 because signal() is already a macro, defined in <sys/signal.h>, and | |
55 the original definition would be lost. */ | |
56 #define NO_DGUX_SIGNAL_REDEF | |
57 | |
20002
e89847e2df84
Fix name of include file to match 1996-08-24 renaming.
Karl Heuer <kwzh@gnu.org>
parents:
18097
diff
changeset
|
58 #include "dgux5-4-3.h" |
18097 | 59 |
60 #define LIBS_DEBUG /* nothing, -lg doesn't exist */ | |
20289 | 61 #define LIBS_SYSTEM -lsocket -lnsl |
18097 | 62 |
63 #ifndef NOT_C_CODE | |
64 | |
65 /* dgux.h defines _setjmp() to be sigsetjmp(), but it defines _longjmp | |
66 to be longjmp() rather than siglongjmp(). Further, it doesn't define | |
67 jmp_buf, so sigsetjmp() is being called with a jmp_buf rather than a | |
68 sigjmp_buf, and the buffer is then passed to vanilla longjmp(). This | |
69 provides a more complete emulation of the Berkeley semantics. */ | |
70 | |
71 #include <setjmp.h> | |
72 #undef jmp_buf | |
73 #undef _setjmp | |
74 #undef setjmp | |
75 #undef _longjmp | |
76 #undef longjmp | |
77 #define jmp_buf sigjmp_buf | |
78 #define _setjmp(env) sigsetjmp(env, 0) | |
79 #define setjmp(env) sigsetjmp(env, 1) | |
80 #define _longjmp siglongjmp | |
81 #define longjmp siglongjmp | |
82 | |
83 /* The BAUD_CONVERT definition in dgux.h is wrong with this version | |
84 of dgux, but I'm not sure when it changed. | |
85 | |
86 With the current system Emacs' standard handling of ospeed and | |
87 baud_rate don't work. The baud values (B9600 and so on) returned by | |
88 cfgetospeed() aren't compatible with those used by ospeed. speed_t, | |
89 the type returned by cfgetospeed(), is unsigned long and speed_t | |
90 values are large. Further, it isn't possible to get at both the | |
91 SysV3 (ospeed) and POSIX (cfgetospeed()) values through symbolic | |
92 constants simultaneously because they both use the same names | |
93 (B9600). To get both baud_rate and ospeed right at the same time | |
94 it's necessary to hardcode the values for one set of values, here I'm | |
95 hardcoding ospeed. */ | |
96 #undef BAUD_CONVERT | |
97 #define INIT_BAUD_RATE() \ | |
98 struct termios sg; \ | |
99 \ | |
100 tcgetattr (input_fd, &sg); \ | |
101 switch (cfgetospeed (&sg)) { \ | |
102 case B50: baud_rate = 50; ospeed = 0x1; break; \ | |
103 case B75: baud_rate = 75; ospeed = 0x2; break; \ | |
104 case B110: baud_rate = 110; ospeed = 0x3; break; \ | |
105 case B134: baud_rate = 134; ospeed = 0x4; break; \ | |
106 case B150: baud_rate = 150; ospeed = 0x5; break; \ | |
107 case B200: baud_rate = 200; ospeed = 0x6; break; \ | |
108 case B300: baud_rate = 300; ospeed = 0x7; break; \ | |
109 case B600: baud_rate = 600; ospeed = 0x8; break; \ | |
110 default: \ | |
111 case B1200: baud_rate = 1200; ospeed = 0x9; break; \ | |
112 case B1800: baud_rate = 1800; ospeed = 0xa; break; \ | |
113 case B2400: baud_rate = 2400; ospeed = 0xb; break; \ | |
114 case B4800: baud_rate = 4800; ospeed = 0xc; break; \ | |
115 case B9600: baud_rate = 9600; ospeed = 0xd; break; \ | |
116 case B19200: baud_rate = 19200; ospeed = 0xe; break; \ | |
117 case B38400: baud_rate = 38400; ospeed = 0xf; break; \ | |
118 } \ | |
119 return; | |
120 | |
23695
a9640ecf5ab4
(BROKEN_FIONREAD): #undef commented out.
Karl Heuer <kwzh@gnu.org>
parents:
20289
diff
changeset
|
121 |
a9640ecf5ab4
(BROKEN_FIONREAD): #undef commented out.
Karl Heuer <kwzh@gnu.org>
parents:
20289
diff
changeset
|
122 #if 0 /* Ehud Karni <ehud@unix.simonwiesel.co.il> says that the problem |
a9640ecf5ab4
(BROKEN_FIONREAD): #undef commented out.
Karl Heuer <kwzh@gnu.org>
parents:
20289
diff
changeset
|
123 still exists on m88k-dg-dguxR4.11MU04 and i586-dg-dguxR4.11MU04. */ |
18097 | 124 /* The `stop on tty output' problem which occurs when using |
125 INTERRUPT_INPUT and when Emacs is invoked under X11 using a job | |
126 control shell (csh, ksh, etc.) in the background doesn't look to be | |
127 present in R4.11. (At least, I can't reproduce it using jsh, csh, | |
128 ksh or zsh.) */ | |
129 #undef BROKEN_FIONREAD | |
130 #define INTERRUPT_INPUT | |
23695
a9640ecf5ab4
(BROKEN_FIONREAD): #undef commented out.
Karl Heuer <kwzh@gnu.org>
parents:
20289
diff
changeset
|
131 #endif /* 0 - never */ |
18097 | 132 |
133 /* In R4.11 (or maybe R4.10, I don't have a system with that version | |
134 loaded) some of the internal stdio semantics were changed. One I | |
135 found while working on MH is that _cnt has to be 0 before _filbuf() | |
136 is called. Another is that (_ptr - _base) doesn't indicate how many | |
137 characters are waiting to be sent. I can't spot a good way to get | |
138 that info from the FILE internals. */ | |
139 #define PENDING_OUTPUT_COUNT(FILE) (1) | |
140 | |
141 #endif /* NOT_C_CODE */ | |
52401 | 142 |
143 /* arch-tag: c7013e7b-6e2e-44f2-ba61-90b6d5e2ea45 | |
144 (do not change this comment) */ |