2 * CDE - Common Desktop Environment
4 * Copyright (c) 1993-2012, The Open Group. All rights reserved.
6 * These libraries and programs are free software; you can
7 * redistribute them and/or modify them under the terms of the GNU
8 * Lesser General Public License as published by the Free Software
9 * Foundation; either version 2 of the License, or (at your option)
12 * These libraries and programs are distributed in the hope that
13 * they will be useful, but WITHOUT ANY WARRANTY; without even the
14 * implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
15 * PURPOSE. See the GNU Lesser General Public License for more
18 * You should have received a copy of the GNU Lesser General Public
19 * License along with these libraries and programs; if not, write
20 * to the Free Software Foundation, Inc., 51 Franklin Street, Fifth
21 * Floor, Boston, MA 02110-1301 USA
24 * $TOG: TermPrimOSDepI.h /main/4 1998/03/16 14:41:55 mgreess $";
27 * (c) Copyright 1993, 1994, 1996 Hewlett-Packard Company *
28 * (c) Copyright 1993, 1994, 1996 International Business Machines Corp. *
29 * (c) Copyright 1993, 1994, 1996 Sun Microsystems, Inc. *
30 * (c) Copyright 1993, 1994, 1996 Novell, Inc. *
31 * (c) Copyright 1996 Digital Equipment Corporation. *
32 * (c) Copyright 1996 FUJITSU LIMITED. *
33 * (c) Copyright 1996 Hitachi. *
35 /******************************************************************************
37 this is a list of OS dependent defines that are available...
39 XOR_CAPS_LOCK xor caps lock and shift so that lock+shift
40 acts as a noop for alpha keys
41 NO_MESSAGE_CATALOG enables the message catalog code
42 USE_TIOCCONS use TIOCCONS iocto for -C option
43 USE_SRIOCSREDIR use SRIOCSREDIR ioctl for -C option
44 SETENV_LINES_AND_COLS set $LINES and $COLUMNS
45 HAS_SETRESUID os supports setresuid(2) - first choice
46 HAS_SETEUID os supports seteuid(2) - second choice
47 HAS_SETREUID os supports setreuid(2) - second choice
48 USE_STREAMS use streams as opposed to ptys - first choice
49 USE_STREAMS_TTCOMPAT use ttcompat streams mod
50 USE_STREAMS_BUFMOD use bofmod streams mod
51 USE_PTYS use ptys - second choice
52 USE_CSWIDTH use the csWidth resource to initialize
53 multi-byte processing in ldterm
54 USE_SETCSMAP use setcsmap() for multi-byte processing
55 USE_SUN_WCWIDTH_PATCH use SUN wcwidth() workaround
56 USE_TIOCBREAK use TIOCBREAK ioctl() to send RS232 break
57 USE_TCSBRK use TCBRK ioctl() to send RS232 break
58 USE_TCSBREAK use TCBREAK ioctl() to send RS232 break
59 USE_TCSENDBREAK use tiocbreak() to send RS232 break
61 ******************************************************************************/
63 #ifndef _Dt_TermPrimOSDepI_h
64 #define _Dt_TermPrimOSDepI_h
66 #ifdef ALPHA_ARCHITECTURE
67 # define USE_TIOCCONS /* use tioccons for -C */
68 # define HAS_SETEUID /* seteuid available */
69 # define HAS_SETREUID /* setreuid available */
70 # define USE_PTYS /* use ptys */
71 # define USE_TCSBRK /* use TCSBRK ioctl() */
72 #endif /* ALPHA_ARCHITECTURE */
74 #ifdef HP_ARCHITECTURE
75 # define XOR_CAPS_LOCK /* xor caps lock and shift */
76 # define USE_TIOCCONS /* use tioccons for -C */
77 # define SETENV_LINES_AND_COLS /* set $LINES and $COLUMNS */
78 # define HAS_SETRESUID /* setresuid available */
80 # if OSMAJORVERSION > 9
81 # define USE_STREAMS /* use streams */
82 # define USE_CSWIDTH /* use the csWidth resource to */
83 /* initialize multi-byte processing */
85 # define USE_TCSENDBREAK /* use tiocbreak() */
86 # else /* OSMAJORVERSION > 9 */
87 # define USE_PTYS /* use ptys */
88 # define USE_TIOCBREAK /* use TIOCBREAK ioctl() */
89 # endif /* OSMAJORVERSION > 9 */
90 #endif /* HP_ARCHITECTURE */
92 #ifdef LINUX_ARCHITECTURE
93 # define USE_TIOCCONS /* use tioccons for -C */
94 # define HAS_SETEUID /* seteuid available */
95 # define HAS_SETREUID /* setreuid available */
96 # define USE_TCSENDBREAK /* use tiocbreak() */
97 #endif /* LINUX_ARCHITECTURE */
100 # define HAS_SETEUID /* seteuid available */
101 # define HAS_SETREUID /* setreuid available */
102 # define USE_TCSENDBREAK /* use tiocbreak() */
103 #endif /* CSRG_BASED */
105 #ifdef SUN_ARCHITECTURE
106 # define XOR_CAPS_LOCK /* xor caps lock and shift */
107 # define USE_SRIOCSREDIR /* use SRIOCSREDIR ioctl for -C */
108 # define USE_STREAMS /* use streams */
109 # define USE_STREAMS_TTCOMPAT /* use ttcompat streams mod */
110 # define USE_STREAMS_BUFMOD /* use bofmod streams mod */
111 # define USE_TCSENDBREAK /* use tiocbreak() */
112 # if (_XOPEN_VERSION == 3)
113 # define USE_SUN_WCWIDTH_PATCH
114 # define wcwidth(w) sun_wcwidth(w)
115 # endif /* (_XOPEN_VERSION == 3) */
116 #endif /* SUN_ARCHITECTURE */
118 #ifdef IBM_ARCHITECTURE
119 /* this seems to be #define'ed in the world of imake... */
120 # define USE_TIOCCONS /* use tioccons for -C */
121 # define HAS_SETEUID /* seteuid available */
122 # define HAS_SETREUID /* setreuid available */
123 # define USE_PTYS /* use ptys */
124 # define USE_SETCSMAP /* use setcsmap() for multi-byte*/
125 # define USE_TCSENDBREAK /* use tiocbreak() */
126 #endif /* IBM_ARCHITECTURE */
128 #ifdef USL_ARCHITECTURE
129 # define XOR_CAPS_LOCK /* xor caps lock and shift */
130 # define USE_STREAMS /* use streams */
131 # define USE_STREAMS_TTCOMPAT /* use ttcompat streams mod */
132 # define USE_TCSENDBREAK /* use tiocbreak() */
133 #endif /* USL_ARCHITECTURE */
135 #ifdef UXP_ARCHITECTURE
136 # define XOR_CAPS_LOCK /* xor caps lock and shift */
137 # define USE_STREAMS /* use streams */
138 # define USE_STREAMS_TTCOMPAT /* use ttcompat streams mod */
139 # define USE_TCSENDBREAK /* use tiocbreak() */
140 #endif /* UXP_ARCHITECTURE */
142 #endif /* _Dt_TermPrimOSDepI_h */
143 /* DON'T ADD ANYTHING AFTER THIS #endif... */