annotate src/s/sol2.h @ 0:376386a54a3c r19-14

Import from CVS: tag r19-14
author cvs
date Mon, 13 Aug 2007 08:45:50 +0200
parents
children 8fc7fe29b841
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
1 /* Synched up with: FSF 19.31. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
2
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
3 #include "usg5-4-2.h" /* XEmacs change from 5-4 to 5-4-2 */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
4
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
5 #define SOLARIS2
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
6
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
7 /* SIGIO seems to be working under Solaris and it makes ^G work better... */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
8 #undef BROKEN_SIGIO
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
9
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
10 /* eggert@twinsun.com said these work in Solaris.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
11 Perhaps they work in all kinds of SVR4, but this is more conservative. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
12 #undef BROKEN_TIOCGETC
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
13 #undef BROKEN_TIOCGWINSZ
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
14
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
15 /* This triggers a conditional in xfaces.c. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
16 #define XOS_NEEDS_TIME_H
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
17
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
18 #define POSIX
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
19
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
20 /* FSF uses LD_SWITCH_X_SITE_AUX in the following definitions to deal with
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
21 the -R flags. While the intention is good, it doesn't seem to work that
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
22 well -- Solaris is just too damn screwy. So we go ahead and let
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
23 configure have special checks for Solaris. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
24
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
25 /* Here is how to find X Windows. The -R option says where
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
26 to find X windows at run time. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
27 #ifdef __GNUC__
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
28 #define LD_SWITCH_SYSTEM -Xlinker -R/usr/openwin/lib
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
29 #elif defined (__SUNPRO_C) && (__SUNPRO_C >= 0x400)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
30 /* XEmacs: <Georg.Nikodym@canada.sun.com> says you need to turn off
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
31 the incremental linker with Sunpro C 4, or dynodump won't work. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
32 #define LD_SWITCH_SYSTEM -xildoff -R/usr/openwin/lib
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
33 #else /* not GCC or Sunpro C 4.0 */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
34 #define LD_SWITCH_SYSTEM -R/usr/openwin/lib
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
35 #endif
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
36
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
37 /* XEmacs change -- Sun CC needs this to default to ANSI */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
38 #ifdef __SUNPRO_C
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
39 #define C_SWITCH_SYSTEM -Xa
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
40 #endif /* __SUNPRO_C */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
41
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
42 #ifndef NOT_C_CODE
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
43 /* The standard Solaris library nsl has this function in it which is
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
44 supposed to only be in the BSD compat stuff. Yuck. Of course,
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
45 there isn't a prototype for it other than in /usr/ucbinclude. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
46 int gethostname (char *, int);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
47
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
48 /* XEmacs: Solaris include files miss this. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
49 struct timeval;
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
50 int utimes (char *file, struct timeval *tvp);
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
51
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
52 /* XEmacs addition: to this to avoid having problems when we later
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
53 define INT_MAX etc. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
54 #include <limits.h>
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
55 #endif
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
56
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
57 /* XEmacs change -- removed flags to force K & R compilation */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
58
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
59 /*
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
60 * XEmacs change -- some Motif packages need -lgen to get regex and regcmp
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
61 */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
62
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
63 #undef LIBS_SYSTEM
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
64 #define LIBS_SYSTEM -lsocket -lnsl -lkvm -lelf -lgen -ldl
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
65
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
66 /* XEmacs change -- Mark Borges says this is needed. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
67 #define LIBS_TERMCAP -ltermlib
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
68
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
69 /* #### XEmacs change: until we've gotten the Energize builds converted
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
70 over to use configure instead of ymakefile, we still need this.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
71 */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
72 #if defined (NOT_C_CODE) && defined (ENERGIZE)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
73
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
74 # define LIB_INTL -L/usr/openwin/lib -lintl -lw
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
75 # define LIBS_DEBUG
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
76 # undef LIBS_SYSTEM
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
77 # define LIBS_SYSTEM -lsocket -lnsl -lintl -lelf -lkvm -lgen -ldl
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
78 # define START_FILES
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
79 # define LD_CMD $(CC)
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
80
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
81 #endif
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
82
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
83 /* SYSTEM_MALLOC must be defined if dbx/RTC is going to be used. dbx/RTC does
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
84 not work with a static definition of malloc(). */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
85 /* We want to be able to test out ralloc.c. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
86 /* #define SYSTEM_MALLOC */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
87
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
88 /* XEmacs: there used to be a special definition of
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
89 PTY_TTY_NAME_SPRINTF here that was identical to the
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
90 other SYSV R4 definitions except that it didn't
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
91 block SIGCHLD around the call to grantpt(). This
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
92 is *not* in 19.29 and is almost certainly incorrect.
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
93 */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
94
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
95 /* XEmacs change from Georg.Nikodym@Canada.Sun.COM. */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
96 #ifdef UNEXEC
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
97 #undef UNEXEC
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
98 #endif
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
99 #define UNEXEC unexsol2.o
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
100
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
101 /* XEmacs: Solaris has sigsetjmp but using it leads to core dumps at
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
102 least under 2.4 */
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
103 #undef _setjmp
376386a54a3c Import from CVS: tag r19-14
cvs
parents:
diff changeset
104 #define _setjmp setjmp