1167465Smp/* $Header: /p/tcsh/cvsroot/tcsh/sh.init.c,v 3.63 2006/08/23 01:49:32 mitr Exp $ */
259243Sobrien/*
359243Sobrien * sh.init.c: Function and signal tables
459243Sobrien */
559243Sobrien/*-
659243Sobrien * Copyright (c) 1980, 1991 The Regents of the University of California.
759243Sobrien * All rights reserved.
859243Sobrien *
959243Sobrien * Redistribution and use in source and binary forms, with or without
1059243Sobrien * modification, are permitted provided that the following conditions
1159243Sobrien * are met:
1259243Sobrien * 1. Redistributions of source code must retain the above copyright
1359243Sobrien *    notice, this list of conditions and the following disclaimer.
1459243Sobrien * 2. Redistributions in binary form must reproduce the above copyright
1559243Sobrien *    notice, this list of conditions and the following disclaimer in the
1659243Sobrien *    documentation and/or other materials provided with the distribution.
17100616Smp * 3. Neither the name of the University nor the names of its contributors
1859243Sobrien *    may be used to endorse or promote products derived from this software
1959243Sobrien *    without specific prior written permission.
2059243Sobrien *
2159243Sobrien * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
2259243Sobrien * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
2359243Sobrien * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
2459243Sobrien * ARE DISCLAIMED.  IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
2559243Sobrien * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
2659243Sobrien * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
2759243Sobrien * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
2859243Sobrien * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
2959243Sobrien * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
3059243Sobrien * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
3159243Sobrien * SUCH DAMAGE.
3259243Sobrien */
3359243Sobrien#include "sh.h"
3459243Sobrien
35167465SmpRCSID("$tcsh: sh.init.c,v 3.63 2006/08/23 01:49:32 mitr Exp $")
3659243Sobrien
3759243Sobrien#include "ed.h"
3859243Sobrien#include "tw.h"
3959243Sobrien
4059243Sobrien/*
4159243Sobrien * C shell
4259243Sobrien */
4359243Sobrien
44167465Smp#define	INF INT_MAX
4559243Sobrien
46167465Smpconst struct biltins bfunc[] = {
4759243Sobrien    { ":",		dozip,		0,	INF	},
4859243Sobrien    { "@",		dolet,		0,	INF	},
4959243Sobrien    { "alias",		doalias,	0,	INF	},
5059243Sobrien    { "alloc",		showall,	0,	1	},
5159243Sobrien#if defined(_CX_UX)
5259243Sobrien    { "att",		doatt,		0,	INF	},
5359243Sobrien#endif /* _CX_UX */
5459243Sobrien    { "bg",		dobg,		0,	INF	},
5559243Sobrien    { "bindkey",	dobindkey,	0,	8	},
5659243Sobrien    { "break",		dobreak,	0,	0	},
5759243Sobrien    { "breaksw",	doswbrk,	0,	0	},
58131962Smp#ifdef _OSD_POSIX
59131962Smp    { "bs2cmd",		dobs2cmd,	1,	INF	},
60131962Smp#endif /* OBSOLETE */
6159243Sobrien    { "builtins",	dobuiltins,	0,	0	},
6259243Sobrien#ifdef KAI
6359243Sobrien    { "bye",		goodbye,	0,	0	},
6459243Sobrien#endif /* KAI */
6559243Sobrien    { "case",		dozip,		0,	1	},
6659243Sobrien    { "cd",		dochngd,	0,	INF	},
6759243Sobrien    { "chdir",		dochngd,	0,	INF	},
6859243Sobrien    { "complete",	docomplete,	0,	INF	},
6959243Sobrien    { "continue",	docontin,	0,	0	},
7059243Sobrien    { "default",	dozip,		0,	0	},
7159243Sobrien    { "dirs",		dodirs,		0,	INF	},
7259243Sobrien#if defined(_CRAY) && !defined(_CRAYMPP)
7359243Sobrien    { "dmmode",		dodmmode,	0,	1	},
7459243Sobrien#endif /* _CRAY && !_CRAYMPP */
7559243Sobrien    { "echo",		doecho,		0,	INF	},
7659243Sobrien    { "echotc",		doechotc,	0,	INF	},
7759243Sobrien    { "else",		doelse,		0,	INF	},
7859243Sobrien    { "end",		doend,		0,	0	},
7959243Sobrien    { "endif",		dozip,		0,	0	},
8059243Sobrien    { "endsw",		dozip,		0,	0	},
8159243Sobrien    { "eval",		doeval,		0,	INF	},
8259243Sobrien    { "exec",		execash,	1,	INF	},
8359243Sobrien    { "exit",		doexit,		0,	INF	},
8459243Sobrien    { "fg",		dofg,		0,	INF	},
8559243Sobrien    { "filetest",	dofiletest,	2,	INF	},
8659243Sobrien    { "foreach",	doforeach,	3,	INF	},
8759243Sobrien#ifdef TCF
8859243Sobrien    { "getspath",	dogetspath,	0,	0	},
8959243Sobrien    { "getxvers",	dogetxvers,	0,	0	},
9059243Sobrien#endif /* TCF */
9159243Sobrien    { "glob",		doglob,		0,	INF	},
9259243Sobrien    { "goto",		dogoto,		1,	1	},
9359243Sobrien    { "hashstat",	hashstat,	0,	0	},
9459243Sobrien    { "history",	dohist,		0,	2	},
9559243Sobrien    { "hup",		dohup,		0,	INF	},
9659243Sobrien    { "if",		doif,		1,	INF	},
9759243Sobrien#ifdef apollo
9859243Sobrien    { "inlib", 		doinlib,	1,	INF	},
9959243Sobrien#endif /* apollo */
10059243Sobrien    { "jobs",		dojobs,		0,	1	},
10159243Sobrien    { "kill",		dokill,		1,	INF	},
10259243Sobrien#ifndef HAVENOLIMIT
10359243Sobrien    { "limit",		dolimit,	0,	3	},
10459243Sobrien#endif /* !HAVENOLIMIT */
10559243Sobrien#ifdef OBSOLETE
10659243Sobrien    { "linedit",	doecho,		0,	INF	},
10759243Sobrien#endif /* OBSOLETE */
10859243Sobrien#if !defined(HAVENOUTMP) && !defined(KAI)
10959243Sobrien    { "log",		dolog,		0,	0	},
11059243Sobrien#endif /* !HAVENOUTMP && !KAI */
11159243Sobrien    { "login",		dologin,	0,	1	},
11259243Sobrien    { "logout",		dologout,	0,	0	},
11359243Sobrien    { "ls-F",		dolist,		0,	INF	},
11459243Sobrien#ifdef TCF
11559243Sobrien    { "migrate",	domigrate,	1,	INF	},
11659243Sobrien#endif /* TCF */
11759243Sobrien#ifdef NEWGRP
118131962Smp    { "newgrp",		donewgrp,	0,	2	},
11959243Sobrien#endif /* NEWGRP */
12059243Sobrien    { "nice",		donice,		0,	INF	},
12159243Sobrien    { "nohup",		donohup,	0,	INF	},
12259243Sobrien    { "notify",		donotify,	0,	INF	},
12359243Sobrien    { "onintr",		doonintr,	0,	2	},
12459243Sobrien    { "popd",		dopopd,		0,	INF	},
12559243Sobrien    { "printenv",	doprintenv,	0,	1	},
12659243Sobrien    { "pushd",		dopushd,	0,	INF	},
12759243Sobrien    { "rehash",		dohash,		0,	3	},
12859243Sobrien    { "repeat",		dorepeat,	2,	INF	},
12959243Sobrien#ifdef apollo
13059243Sobrien    { "rootnode",	dorootnode,	1,	1	},
13159243Sobrien#endif /* apollo */
13259243Sobrien    { "sched",		dosched,	0,	INF	},
13359243Sobrien    { "set",		doset,		0,	INF	},
13459243Sobrien    { "setenv",		dosetenv,	0,	2	},
13559243Sobrien#ifdef MACH
13659243Sobrien    { "setpath",	dosetpath,	0,	INF	},
13759243Sobrien#endif	/* MACH */
13859243Sobrien#ifdef TCF
13959243Sobrien    { "setspath",	dosetspath,	1,	INF	},
14059243Sobrien#endif /* TCF */
14159243Sobrien    { "settc",		dosettc,	2,	2	},
14259243Sobrien    { "setty", 		dosetty,	0,      INF	},
14359243Sobrien#ifdef TCF
14459243Sobrien    { "setxvers",	dosetxvers,	0,	1	},
14559243Sobrien#endif /* TCF */
14659243Sobrien    { "shift",		shift,		0,	1	},
14759243Sobrien    { "source",		dosource,	1,	INF	},
14859243Sobrien    { "stop",		dostop,		1,	INF	},
14959243Sobrien    { "suspend",	dosuspend,	0,	0	},
15059243Sobrien    { "switch",		doswitch,	1,	INF	},
15159243Sobrien    { "telltc",		dotelltc,	0,	INF	},
152145479Smp#ifndef WINNT_NATIVE
153145479Smp    { "termname",	dotermname,	0,  	1       },
154145479Smp#endif
15559243Sobrien    { "time",		dotime,		0,	INF	},
15659243Sobrien#if defined(_CX_UX)
15759243Sobrien    { "ucb",		doucb,		0,	INF	},
15859243Sobrien#endif /* _CX_UX */
15959243Sobrien    { "umask",		doumask,	0,	1	},
16059243Sobrien    { "unalias",	unalias,	1,	INF	},
16159243Sobrien    { "uncomplete",	douncomplete,	1,	INF	},
16259243Sobrien    { "unhash",		dounhash,	0,	0	},
16359243Sobrien#if defined(masscomp) || defined(_CX_UX)
16459243Sobrien    { "universe",	douniverse,	0,	INF	},
16559243Sobrien#endif /* masscomp || _CX_UX */
16659243Sobrien#ifndef HAVENOLIMIT
16759243Sobrien    { "unlimit",	dounlimit,	0,	INF	},
16859243Sobrien#endif /* !HAVENOLIMIT */
16959243Sobrien    { "unset",		unset,		1,	INF	},
17059243Sobrien    { "unsetenv",	dounsetenv,	1,	INF	},
17159243Sobrien#ifdef apollo
17259243Sobrien    { "ver",		dover,		0,	INF	},
17359243Sobrien#endif /* apollo */
17459243Sobrien    { "wait",		dowait,		0,	0	},
17559243Sobrien#ifdef WARP
17659243Sobrien    { "warp",		dowarp,		0,	2	},
17759243Sobrien#endif /* WARP */
17859243Sobrien#if !defined(HAVENOUTMP) && defined(KAI)
17959243Sobrien    { "watchlog",	dolog,		0,	0	},
18059243Sobrien#endif /* !HAVENOUTMP && KAI */
18159243Sobrien    { "where",		dowhere,	1,	INF	},
18259243Sobrien    { "which",		dowhich,	1,	INF	},
18359243Sobrien    { "while",		dowhile,	1,	INF	}
18459243Sobrien};
18559243Sobrienint nbfunc = sizeof bfunc / sizeof *bfunc;
18659243Sobrien
18759243Sobrienstruct srch srchn[] = {
18859243Sobrien    { "@",		TC_LET		},
18959243Sobrien    { "break",		TC_BREAK	},
19059243Sobrien    { "breaksw",	TC_BRKSW	},
19159243Sobrien    { "case",		TC_CASE		},
19259243Sobrien    { "default", 	TC_DEFAULT	},
19359243Sobrien    { "else",		TC_ELSE		},
19459243Sobrien    { "end",		TC_END		},
19559243Sobrien    { "endif",		TC_ENDIF	},
19659243Sobrien    { "endsw",		TC_ENDSW	},
19759243Sobrien    { "exit",		TC_EXIT		},
19859243Sobrien    { "foreach", 	TC_FOREACH	},
19959243Sobrien    { "goto",		TC_GOTO		},
20059243Sobrien    { "if",		TC_IF		},
20159243Sobrien    { "label",		TC_LABEL	},
20259243Sobrien    { "set",		TC_SET		},
20359243Sobrien    { "switch",		TC_SWITCH	},
20459243Sobrien    { "while",		TC_WHILE	}
20559243Sobrien};
20659243Sobrienint nsrchn = sizeof srchn / sizeof *srchn;
20759243Sobrien
20859243Sobrien
20959243Sobrien/*
21059243Sobrien * Note: For some machines, (hpux eg.)
21159243Sobrien * NSIG = number of signals + 1...
21259243Sobrien * so we define 33 or 65 (POSIX) signals for
21359243Sobrien * everybody
21459243Sobrien */
21559243Sobrien
21659243Sobrien/* We define NUMSIG to avoid changing NSIG or MAXSIG */
217145479Smp#if defined(POSIX) && !defined(__CYGWIN__)
21859243Sobrien# define NUMSIG 65
21959243Sobrien#else /* !POSIX */
22059243Sobrien# define NUMSIG 33
22159243Sobrien#endif /* POSIX */
22259243Sobrien
22359243Sobrienint	nsig = NUMSIG - 1;	/* This should be the number of real signals */
22459243Sobrien				/* not counting signal 0 */
225145479Smpstruct mesg mesg[NUMSIG];	/* Arrays start at [0] so we initialize from */
22659243Sobrien				/* 0 to 32 or 64, the max real signal number */
22759243Sobrien
22859243Sobrienvoid
229167465Smpmesginit(void)
23059243Sobrien{
23159243Sobrien
23259243Sobrien#ifdef NLS_CATALOGS
23359243Sobrien    int i;
23459243Sobrien
23559243Sobrien    for (i = 0; i < NUMSIG; i++) {
236167465Smp        xfree((char *)(intptr_t)mesg[i].pname);
23759243Sobrien	mesg[i].pname = NULL;
23859243Sobrien    }
23959243Sobrien#endif /* NLS_CATALOGS */
24059243Sobrien
24159243Sobrien#if defined(SIGNULL) || defined(DECOSF1)
24259243Sobrien# ifndef SIGNULL
24359243Sobrien#  define SIGNULL 0
24459243Sobrien# endif /* !SIGNULL */
24559243Sobrien    if (mesg[SIGNULL].pname == NULL) {
24659243Sobrien	mesg[SIGNULL].iname = "NULL";
24759243Sobrien	mesg[SIGNULL].pname = CSAVS(2, 1, "Null signal");
24859243Sobrien    }
24959243Sobrien#endif /* SIGNULL || DECOSF1 */
25059243Sobrien
25159243Sobrien#ifdef SIGHUP
25259243Sobrien    if (mesg[SIGHUP].pname == NULL) {
25359243Sobrien	mesg[SIGHUP].iname = "HUP";
25459243Sobrien	mesg[SIGHUP].pname = CSAVS(2, 2, "Hangup");
25559243Sobrien    }
25659243Sobrien#endif /* SIGHUP */
25759243Sobrien
25859243Sobrien#ifdef SIGINT
25959243Sobrien    if (mesg[SIGINT].pname == NULL) {
26059243Sobrien	mesg[SIGINT].iname = "INT";
26159243Sobrien	mesg[SIGINT].pname = CSAVS(2, 3, "Interrupt");
26259243Sobrien    }
26359243Sobrien#endif /* SIGINT */
26459243Sobrien
26559243Sobrien#ifdef SIGQUIT
26659243Sobrien    if (mesg[SIGQUIT].pname == NULL) {
26759243Sobrien	mesg[SIGQUIT].iname = "QUIT";
26859243Sobrien	mesg[SIGQUIT].pname = CSAVS(2, 4, "Quit");
26959243Sobrien    }
27059243Sobrien#endif /* SIGQUIT */
27159243Sobrien
27259243Sobrien#ifdef SIGILL
27359243Sobrien    if (mesg[SIGILL].pname == NULL) {
27459243Sobrien	mesg[SIGILL].iname = "ILL";
27559243Sobrien	mesg[SIGILL].pname = CSAVS(2, 5, "Illegal instruction");
27659243Sobrien    }
27759243Sobrien#endif /* SIGILL */
27859243Sobrien
27959243Sobrien#ifdef SIGTRAP
28059243Sobrien    if (mesg[SIGTRAP].pname == NULL) {
28159243Sobrien	mesg[SIGTRAP].iname = "TRAP";
28259243Sobrien	mesg[SIGTRAP].pname = CSAVS(2, 6, "Trace/BPT trap");
28359243Sobrien    }
28459243Sobrien#endif /* SIGTRAP */
28559243Sobrien
28659243Sobrien#ifdef SIGABRT
28759243Sobrien    if (mesg[SIGABRT].pname == NULL) {
28859243Sobrien	mesg[SIGABRT].iname = "ABRT";
28959243Sobrien	mesg[SIGABRT].pname = CSAVS(2, 7, "Abort");
29059243Sobrien    }
29159243Sobrien#endif /* SIGABRT */
29259243Sobrien
29359243Sobrien#ifdef SIGIOT
29459243Sobrien    if (mesg[SIGIOT].pname == NULL) {
29559243Sobrien	mesg[SIGIOT].iname = "IOT";
29659243Sobrien	mesg[SIGIOT].pname = CSAVS(2, 8, "IOT trap");
29759243Sobrien    }
29859243Sobrien#endif /* SIGIOT */
29959243Sobrien
30059243Sobrien#ifdef SIGDANGER
30159243Sobrien    /* aiws */
30259243Sobrien    if (mesg[SIGDANGER].pname == NULL) {
30359243Sobrien	mesg[SIGDANGER].iname = "DANGER";
30459243Sobrien	mesg[SIGDANGER].pname = CSAVS(2, 9, "System Crash Imminent");
30559243Sobrien    }
30659243Sobrien#endif /* SIGDANGER */
30759243Sobrien
30859243Sobrien#ifdef SIGERR
30959243Sobrien    /* _CRAY */
31059243Sobrien    if (mesg[SIGERR].pname == NULL) {
31159243Sobrien	mesg[SIGERR].iname = "ERR";
31259243Sobrien	mesg[SIGERR].pname = CSAVS(2, 10, "Error exit");
31359243Sobrien    }
31459243Sobrien#endif /* SIGERR */
31559243Sobrien
31659243Sobrien#ifdef SIGEMT
31759243Sobrien    if (mesg[SIGEMT].pname == NULL) {
31859243Sobrien	mesg[SIGEMT].iname = "EMT";
31959243Sobrien	mesg[SIGEMT].pname = CSAVS(2, 11, "EMT trap");
32059243Sobrien    }
32159243Sobrien#endif /* SIGEMT */
32259243Sobrien
32359243Sobrien#ifdef SIGFPE
32459243Sobrien    if (mesg[SIGFPE].pname == NULL) {
32559243Sobrien	mesg[SIGFPE].iname = "FPE";
32659243Sobrien	mesg[SIGFPE].pname = CSAVS(2, 12, "Floating exception");
32759243Sobrien    }
32859243Sobrien#endif /* SIGFPE */
32959243Sobrien
33059243Sobrien#ifdef SIGKILL
33159243Sobrien    if (mesg[SIGKILL].pname == NULL) {
33259243Sobrien	mesg[SIGKILL].iname = "KILL";
33359243Sobrien	mesg[SIGKILL].pname = CSAVS(2, 13, "Killed");
33459243Sobrien    }
33559243Sobrien#endif /* SIGKILL */
33659243Sobrien
33759243Sobrien#ifdef SIGUSR1
33859243Sobrien    if (mesg[SIGUSR1].pname == NULL) {
33959243Sobrien	mesg[SIGUSR1].iname = "USR1";
34059243Sobrien	mesg[SIGUSR1].pname = CSAVS(2, 14, "User signal 1");
34159243Sobrien    }
34259243Sobrien#endif /* SIGUSR1 */
34359243Sobrien
34459243Sobrien#ifdef SIGUSR2
34559243Sobrien    if (mesg[SIGUSR2].pname == NULL) {
34659243Sobrien	mesg[SIGUSR2].iname = "USR2";
34759243Sobrien	mesg[SIGUSR2].pname = CSAVS(2, 15, "User signal 2");
34859243Sobrien    }
34959243Sobrien#endif /* SIGUSR2 */
35059243Sobrien
35159243Sobrien#ifdef SIGSEGV
35259243Sobrien    if (mesg[SIGSEGV].pname == NULL) {
35359243Sobrien	mesg[SIGSEGV].iname = "SEGV";
35459243Sobrien	mesg[SIGSEGV].pname = CSAVS(2, 16, "Segmentation fault");
35559243Sobrien    }
35659243Sobrien#endif /* SIGSEGV */
35759243Sobrien
35859243Sobrien#ifdef SIGBUS
35959243Sobrien    if (mesg[SIGBUS].pname == NULL) {
36059243Sobrien	mesg[SIGBUS].iname = "BUS";
36159243Sobrien	mesg[SIGBUS].pname = CSAVS(2, 17, "Bus error");
36259243Sobrien    }
36359243Sobrien#endif /* SIGBUS */
36459243Sobrien
36559243Sobrien#ifdef SIGPRE
36659243Sobrien    /* _CRAY || IBMAIX */
36759243Sobrien    if (mesg[SIGPRE].pname == NULL) {
36859243Sobrien	mesg[SIGPRE].iname = "PRE";
36959243Sobrien	mesg[SIGPRE].pname = CSAVS(2, 18, "Program range error");
37059243Sobrien    }
37159243Sobrien#endif /* SIGPRE */
37259243Sobrien
37359243Sobrien#ifdef SIGORE
37459243Sobrien    /* _CRAY */
37559243Sobrien    if (mesg[SIGORE].pname == NULL) {
37659243Sobrien	mesg[SIGORE].iname = "ORE";
37759243Sobrien	mesg[SIGORE].pname = CSAVS(2, 19, "Operand range error");
37859243Sobrien    }
37959243Sobrien#endif /* SIGORE */
38059243Sobrien
38159243Sobrien#ifdef SIGSYS
38259243Sobrien    if (mesg[SIGSYS].pname == NULL) {
38359243Sobrien	mesg[SIGSYS].iname = "SYS";
38459243Sobrien	mesg[SIGSYS].pname = CSAVS(2, 20, "Bad system call");
38559243Sobrien    }
38659243Sobrien#endif /* SIGSYS */
38759243Sobrien
38859243Sobrien#ifdef SIGPIPE
38959243Sobrien    if (mesg[SIGPIPE].pname == NULL) {
39059243Sobrien	mesg[SIGPIPE].iname = "PIPE";
39159243Sobrien	mesg[SIGPIPE].pname = CSAVS(2, 21, "Broken pipe");
39259243Sobrien    }
39359243Sobrien#endif /* SIGPIPE */
39459243Sobrien
39559243Sobrien#ifdef SIGALRM
39659243Sobrien    if (mesg[SIGALRM].pname == NULL) {
39759243Sobrien	mesg[SIGALRM].iname = "ALRM";
39859243Sobrien	mesg[SIGALRM].pname = CSAVS(2, 22, "Alarm clock");
39959243Sobrien    }
40059243Sobrien#endif /* SIGALRM */
40159243Sobrien
40259243Sobrien#ifdef SIGTERM
40359243Sobrien    if (mesg[SIGTERM].pname == NULL) {
40459243Sobrien	mesg[SIGTERM].iname = "TERM";
40559243Sobrien	mesg[SIGTERM].pname = CSAVS(2, 23, "Terminated");
40659243Sobrien    }
40759243Sobrien#endif /* SIGTERM */
40859243Sobrien
40959243Sobrien/* SIGCLD vs SIGCHLD */
41059243Sobrien#if !defined(SIGCHLD) || defined(SOLARIS2) || defined(apollo) || defined(__EMX__)
41159243Sobrien    /* If we don't define SIGCHLD, or our OS prefers SIGCLD to SIGCHLD, */
41259243Sobrien    /* check for SIGCLD */
41359243Sobrien# ifdef SIGCLD
41459243Sobrien    if (mesg[SIGCLD].pname == NULL) {
41559243Sobrien	mesg[SIGCLD].iname = "CLD";
41659243Sobrien#  ifdef BSDJOBS
41759243Sobrien	mesg[SIGCLD].pname = CSAVS(2, 24, "Child status change");
41859243Sobrien#  else /* !BSDJOBS */
41959243Sobrien	mesg[SIGCLD].pname = CSAVS(2, 25, "Death of child");
42059243Sobrien#  endif /* BSDJOBS */
42159243Sobrien    }
42259243Sobrien# endif /* SIGCLD */
42359243Sobrien#else /* !(!SIGCHLD || SOLARIS2 || apollo || __EMX__) */
42459243Sobrien    /* We probably define SIGCHLD */
42559243Sobrien# ifdef SIGCHLD
42659243Sobrien    if (mesg[SIGCHLD].pname == NULL) {
42759243Sobrien	mesg[SIGCHLD].iname = "CHLD";
42859243Sobrien#  ifdef BSDJOBS
42959243Sobrien	mesg[SIGCHLD].pname = CSAVS(2, 27, "Child stopped or exited");
43059243Sobrien#  else /* !BSDJOBS */
43159243Sobrien	mesg[SIGCHLD].pname = CSAVS(2, 28, "Child exited");
43259243Sobrien#  endif /* BSDJOBS */
43359243Sobrien    }
43459243Sobrien# endif /* SIGCHLD */
43559243Sobrien#endif /* !SIGCHLD || SOLARIS2 || apollo || __EMX__ */
43659243Sobrien
43759243Sobrien#ifdef SIGAPOLLO
43859243Sobrien    /* apollo */
43959243Sobrien    if (mesg[SIGAPOLLO].pname == NULL) {
44059243Sobrien	mesg[SIGAPOLLO].iname = "APOLLO";
44159243Sobrien	mesg[SIGAPOLLO].pname = CSAVS(2, 26, "Apollo-specific fault");
44259243Sobrien    }
44359243Sobrien#endif /* SIGAPOLLO */
44459243Sobrien
44559243Sobrien#ifdef SIGPWR
44659243Sobrien    if (mesg[SIGPWR].pname == NULL) {
44759243Sobrien	mesg[SIGPWR].iname = "PWR";
44859243Sobrien	mesg[SIGPWR].pname = CSAVS(2, 29, "Power failure");
44959243Sobrien    }
45059243Sobrien#endif /* SIGPWR */
45159243Sobrien
45259243Sobrien#ifdef SIGLOST
45359243Sobrien    if (mesg[SIGLOST].pname == NULL) {
45459243Sobrien	mesg[SIGLOST].iname = "LOST";
45559243Sobrien	mesg[SIGLOST].pname = CSAVS(2, 30, "Resource Lost");
45659243Sobrien    }
45759243Sobrien#endif /* SIGLOST */
45859243Sobrien
45959243Sobrien#ifdef SIGBREAK
46059243Sobrien    /* __EMX__ */
46159243Sobrien    if (mesg[SIGBREAK].pname == NULL) {
46259243Sobrien	mesg[SIGBREAK].iname = "BREAK";
46359243Sobrien	mesg[SIGBREAK].pname = CSAVS(2, 31, "Break (Ctrl-Break)");
46459243Sobrien    }
46559243Sobrien#endif /* SIGBREAK */
46659243Sobrien
46759243Sobrien#ifdef SIGIO
46859243Sobrien# if !defined(SIGPOLL) || SIGPOLL != SIGIO
46959243Sobrien    if (mesg[SIGIO].pname == NULL) {
47059243Sobrien	mesg[SIGIO].iname = "IO";
47159243Sobrien#  ifdef cray
47259243Sobrien	mesg[SIGIO].pname = CSAVS(2, 32, "Input/output possible signal");
47359243Sobrien#  else /* !cray */
47459243Sobrien	mesg[SIGIO].pname = CSAVS(2, 33, "Asynchronous I/O (select)");
47559243Sobrien#  endif /* cray */
47659243Sobrien    }
47759243Sobrien# endif /* !SIGPOLL || SIGPOLL != SIGIO */
47859243Sobrien#endif /* SIGIO */
47959243Sobrien
48059243Sobrien#ifdef SIGURG
48159243Sobrien    if (mesg[SIGURG].pname == NULL) {
48259243Sobrien	mesg[SIGURG].iname = "URG";
48359243Sobrien	mesg[SIGURG].pname = CSAVS(2, 34, "Urgent condition on I/O channel");
48459243Sobrien    }
48559243Sobrien#endif /* SIGURG */
48659243Sobrien
48759243Sobrien#ifdef SIGMT
48859243Sobrien    /* cray */
48959243Sobrien    if (mesg[SIGMT].pname == NULL) {
49059243Sobrien	mesg[SIGMT].iname = "MT";
49159243Sobrien	mesg[SIGMT].pname = CSAVS(2, 35, "Multitasking wake-up");
49259243Sobrien    }
49359243Sobrien#endif /* SIGMT */
49459243Sobrien
49559243Sobrien#ifdef SIGMTKILL
49659243Sobrien    /* cray */
49759243Sobrien    if (mesg[SIGMTKILL].pname == NULL) {
49859243Sobrien	mesg[SIGMTKILL].iname = "MTKILL";
49959243Sobrien	mesg[SIGMTKILL].pname = CSAVS(2, 36, "Multitasking kill");
50059243Sobrien    }
50159243Sobrien#endif /* SIGMTKILL */
50259243Sobrien
50359243Sobrien#ifdef SIGBUFIO
50459243Sobrien    /* _CRAYCOM */
50559243Sobrien    if (mesg[SIGBUFIO].pname == NULL) {
50659243Sobrien	mesg[SIGBUFIO].iname = "BUFIO";
50759243Sobrien	mesg[SIGBUFIO].pname = CSAVS(2, 37,
50859243Sobrien				    "Fortran asynchronous I/O completion");
50959243Sobrien    }
51059243Sobrien#endif /* SIGBUFIO */
51159243Sobrien
51259243Sobrien#ifdef SIGRECOVERY
51359243Sobrien    /* _CRAYCOM */
51459243Sobrien    if (mesg[SIGRECOVERY].pname == NULL) {
51559243Sobrien	mesg[SIGRECOVERY].iname = "RECOVERY";
51659243Sobrien	mesg[SIGRECOVERY].pname = CSAVS(2, 38, "Recovery");
51759243Sobrien    }
51859243Sobrien#endif /* SIGRECOVERY */
51959243Sobrien
52059243Sobrien#ifdef SIGUME
52159243Sobrien    /* _CRAYCOM */
52259243Sobrien    if (mesg[SIGUME].pname == NULL) {
52359243Sobrien	mesg[SIGUME].iname = "UME";
52459243Sobrien	mesg[SIGUME].pname = CSAVS(2, 39, "Uncorrectable memory error");
52559243Sobrien    }
52659243Sobrien#endif /* SIGUME */
52759243Sobrien
52859243Sobrien#ifdef SIGCPULIM
52959243Sobrien    /* _CRAYCOM */
53059243Sobrien    if (mesg[SIGCPULIM].pname == NULL) {
53159243Sobrien	mesg[SIGCPULIM].iname = "CPULIM";
53259243Sobrien	mesg[SIGCPULIM].pname = CSAVS(2, 40, "CPU time limit exceeded");
53359243Sobrien    }
53459243Sobrien#endif /* SIGCPULIM */
53559243Sobrien
53659243Sobrien#ifdef SIGSHUTDN
53759243Sobrien    /* _CRAYCOM */
53859243Sobrien    if (mesg[SIGSHUTDN].pname == NULL) {
53959243Sobrien	mesg[SIGSHUTDN].iname = "SHUTDN";
54059243Sobrien	mesg[SIGSHUTDN].pname = CSAVS(2, 41, "System shutdown imminent");
54159243Sobrien    }
54259243Sobrien#endif /* SIGSHUTDN */
54359243Sobrien
54459243Sobrien#ifdef SIGNOWAK
54559243Sobrien    /* _CRAYCOM */
54659243Sobrien    if (mesg[SIGNOWAK].pname == NULL) {
54759243Sobrien	mesg[SIGNOWAK].iname = "NOWAK";
54859243Sobrien	mesg[SIGNOWAK].pname = CSAVS(2, 42,
54959243Sobrien				    "Micro-tasking group-no wakeup flag set");
55059243Sobrien    }
55159243Sobrien#endif /* SIGNOWAK */
55259243Sobrien
55359243Sobrien#ifdef SIGTHERR
55459243Sobrien    /* _CRAYCOM */
55559243Sobrien    if (mesg[SIGTHERR].pname == NULL) {
55659243Sobrien	mesg[SIGTHERR].iname = "THERR";
55759243Sobrien	mesg[SIGTHERR].pname = CSAVS(2, 43,
55859243Sobrien			    "Thread error - (use cord -T for detailed info)");
55959243Sobrien    }
56059243Sobrien#endif /* SIGTHERR */
56159243Sobrien
56259243Sobrien#ifdef SIGRPE
56359243Sobrien    /* cray */
56459243Sobrien    if (mesg[SIGRPE].pname == NULL) {
56559243Sobrien	mesg[SIGRPE].pname = CSAVS(2, 44, "CRAY Y-MP register parity error");
56659243Sobrien	mesg[SIGRPE].iname = "RPE";
56759243Sobrien    }
56859243Sobrien#endif /* SIGRPE */
56959243Sobrien
57059243Sobrien#ifdef SIGINFO
57159243Sobrien    if (mesg[SIGINFO].pname == NULL) {
57259243Sobrien	mesg[SIGINFO].iname = "INFO";
57359243Sobrien	mesg[SIGINFO].pname = CSAVS(2, 45, "Information request");
57459243Sobrien    }
57559243Sobrien#endif /* SIGINFO */
57659243Sobrien
57759243Sobrien#ifdef SIGSTOP
57859243Sobrien    if (mesg[SIGSTOP].pname == NULL) {
57959243Sobrien	mesg[SIGSTOP].iname = "STOP";
58059243Sobrien# ifdef SUSPENDED
58159243Sobrien	mesg[SIGSTOP].pname = CSAVS(2, 46, "Suspended (signal)");
58259243Sobrien# else /* !SUSPENDED */
58359243Sobrien	mesg[SIGSTOP].pname = CSAVS(2, 47, "Stopped (signal)");
58459243Sobrien# endif /* SUSPENDED */
58559243Sobrien    }
58659243Sobrien#endif /* SIGSTOP */
58759243Sobrien
58859243Sobrien#ifdef SIGTSTP
58959243Sobrien    if (mesg[SIGTSTP].pname == NULL) {
59059243Sobrien	mesg[SIGTSTP].iname = "TSTP";
59159243Sobrien# ifdef SUSPENDED
59259243Sobrien	mesg[SIGTSTP].pname = CSAVS(2, 48, "Suspended");
59359243Sobrien# else /* !SUSPENDED */
59459243Sobrien	mesg[SIGTSTP].pname = CSAVS(2, 49, "Stopped");
59559243Sobrien# endif /* SUSPENDED */
59659243Sobrien    }
59759243Sobrien#endif /* SIGTSTP */
59859243Sobrien
59959243Sobrien#ifdef SIGCONT
60059243Sobrien    if (mesg[SIGCONT].pname == NULL) {
60159243Sobrien	mesg[SIGCONT].iname = "CONT";
60259243Sobrien	mesg[SIGCONT].pname = CSAVS(2, 50, "Continued");
60359243Sobrien    }
60459243Sobrien#endif /* SIGCONT */
60559243Sobrien
60659243Sobrien#ifdef SIGTTIN
60759243Sobrien    if (mesg[SIGTTIN].pname == NULL) {
60859243Sobrien	mesg[SIGTTIN].iname = "TTIN";
60959243Sobrien# ifdef SUSPENDED
61059243Sobrien	mesg[SIGTTIN].pname = CSAVS(2, 51, "Suspended (tty input)");
61159243Sobrien# else /* !SUSPENDED */
61259243Sobrien	mesg[SIGTTIN].pname = CSAVS(2, 52, "Stopped (tty input)");
61359243Sobrien# endif /* SUSPENDED */
61459243Sobrien    }
61559243Sobrien#endif /* SIGTTIN */
61659243Sobrien
61759243Sobrien#ifdef SIGTTOU
61859243Sobrien    if (mesg[SIGTTOU].pname == NULL) {
61959243Sobrien	mesg[SIGTTOU].iname = "TTOU";
62059243Sobrien# ifdef SUSPENDED
62159243Sobrien	mesg[SIGTTOU].pname = CSAVS(2, 53, "Suspended (tty output)");
62259243Sobrien# else /* SUSPENDED */
62359243Sobrien	mesg[SIGTTOU].pname = CSAVS(2, 54, "Stopped (tty output)");
62459243Sobrien# endif /* SUSPENDED */
62559243Sobrien    }
62659243Sobrien#endif /* SIGTTOU */
62759243Sobrien
62859243Sobrien#ifdef SIGWIND
62959243Sobrien    /* UNIXPC */
63059243Sobrien    if (mesg[SIGWIND].pname == NULL) {
63159243Sobrien	mesg[SIGWIND].iname = "WIND";
63259243Sobrien	mesg[SIGWIND].pname = CSAVS(2, 55, "Window status changed");
63359243Sobrien    }
63459243Sobrien#endif /* SIGWIND */
63559243Sobrien
63659243Sobrien#ifdef SIGWINDOW
63759243Sobrien    if (mesg[SIGWINDOW].pname == NULL) {
63859243Sobrien	mesg[SIGWINDOW].iname = "WINDOW";
63959243Sobrien	mesg[SIGWINDOW].pname = CSAVS(2, 56, "Window size changed");
64059243Sobrien    }
64159243Sobrien#endif /* SIGWINDOW */
64259243Sobrien
64359243Sobrien#ifdef SIGWINCH
64459243Sobrien    if (mesg[SIGWINCH].pname == NULL) {
64559243Sobrien	mesg[SIGWINCH].iname = "WINCH";
64659243Sobrien	mesg[SIGWINCH].pname = CSAVS(2, 56, "Window size changed");
64759243Sobrien    }
64859243Sobrien#endif /* SIGWINCH */
64959243Sobrien
65059243Sobrien#ifdef SIGPHONE
65159243Sobrien    /* UNIXPC */
65259243Sobrien    if (mesg[SIGPHONE].pname == NULL) {
65359243Sobrien	mesg[SIGPHONE].iname = "PHONE";
65459243Sobrien	mesg[SIGPHONE].pname = CSAVS(2, 57, "Phone status changed");
65559243Sobrien    }
65659243Sobrien# endif /* SIGPHONE */
65759243Sobrien
65859243Sobrien#ifdef SIGXCPU
65959243Sobrien    if (mesg[SIGXCPU].pname == NULL) {
66059243Sobrien	mesg[SIGXCPU].iname = "XCPU";
66159243Sobrien	mesg[SIGXCPU].pname = CSAVS(2, 58, "Cputime limit exceeded");
66259243Sobrien    }
66359243Sobrien#endif /* SIGXCPU */
66459243Sobrien
66559243Sobrien#ifdef SIGXFSZ
66659243Sobrien    if (mesg[SIGXFSZ].pname == NULL) {
66759243Sobrien	mesg[SIGXFSZ].iname = "XFSZ";
66859243Sobrien	mesg[SIGXFSZ].pname = CSAVS(2, 59, "Filesize limit exceeded");
66959243Sobrien    }
67059243Sobrien#endif /* SIGXFSZ */
67159243Sobrien
67259243Sobrien#ifdef SIGVTALRM
67359243Sobrien    if (mesg[SIGVTALRM].pname == NULL) {
67459243Sobrien	mesg[SIGVTALRM].iname = "VTALRM";
67559243Sobrien	mesg[SIGVTALRM].pname = CSAVS(2, 60, "Virtual time alarm");
67659243Sobrien    }
67759243Sobrien#endif /* SIGVTALRM */
67859243Sobrien
67959243Sobrien#ifdef SIGPROF
68059243Sobrien    if (mesg[SIGPROF].pname == NULL) {
68159243Sobrien	mesg[SIGPROF].iname = "PROF";
68259243Sobrien	mesg[SIGPROF].pname = CSAVS(2, 61, "Profiling time alarm");
68359243Sobrien    }
68459243Sobrien#endif /* SIGPROF */
68559243Sobrien
68659243Sobrien#ifdef SIGDIL
68759243Sobrien    /* hpux */
68859243Sobrien    if (mesg[SIGDIL].pname == NULL) {
68959243Sobrien	mesg[SIGDIL].iname = "DIL";
69059243Sobrien	mesg[SIGDIL].pname = CSAVS(2, 62, "DIL signal");
69159243Sobrien    }
69259243Sobrien#endif /* SIGDIL */
69359243Sobrien
69459243Sobrien#ifdef SIGPOLL
69559243Sobrien    if (mesg[SIGPOLL].pname == NULL) {
69659243Sobrien	mesg[SIGPOLL].iname = "POLL";
69759243Sobrien	mesg[SIGPOLL].pname = CSAVS(2, 63, "Pollable event occured");
69859243Sobrien    }
69959243Sobrien#endif /* SIGPOLL */
70059243Sobrien
70159243Sobrien#ifdef SIGWAITING
70259243Sobrien    /* solaris */
70359243Sobrien    if (mesg[SIGWAITING].pname == NULL) {
70459243Sobrien	mesg[SIGWAITING].iname = "WAITING";
70559243Sobrien	mesg[SIGWAITING].pname = CSAVS(2, 64, "Process's lwps are blocked");
70659243Sobrien    }
70759243Sobrien#endif /* SIGWAITING */
70859243Sobrien
70959243Sobrien#ifdef SIGLWP
71059243Sobrien    /* solaris */
71159243Sobrien    if (mesg[SIGLWP].pname == NULL) {
71259243Sobrien	mesg[SIGLWP].iname = "LWP";
71359243Sobrien	mesg[SIGLWP].pname = CSAVS(2, 65, "Special LWP signal");
71459243Sobrien    }
71559243Sobrien#endif /* SIGLWP */
71659243Sobrien
71759243Sobrien#ifdef SIGFREEZE
71859243Sobrien    /* solaris */
71959243Sobrien    if (mesg[SIGFREEZE].pname == NULL) {
72059243Sobrien	mesg[SIGFREEZE].iname = "FREEZE";
72159243Sobrien	mesg[SIGFREEZE].pname = CSAVS(2, 66, "Special CPR Signal");
72259243Sobrien    }
72359243Sobrien#endif /* SIGFREEZE */
72459243Sobrien
72559243Sobrien#ifdef SIGTHAW
72659243Sobrien    /* solaris */
72759243Sobrien    if (mesg[SIGTHAW].pname == NULL) {
72859243Sobrien	mesg[SIGTHAW].iname = "THAW";
72959243Sobrien	mesg[SIGTHAW].pname = CSAVS(2, 67, "Special CPR Signal");
73059243Sobrien    }
73159243Sobrien#endif /* SIGTHAW */
73259243Sobrien
73359243Sobrien#ifdef SIGCANCEL
73459243Sobrien    /* solaris */
73559243Sobrien    if (mesg[SIGCANCEL].pname == NULL) {
73659243Sobrien	mesg[SIGCANCEL].iname = "CANCEL";
73759243Sobrien	mesg[SIGCANCEL].pname = CSAVS(2, 109,
73859243Sobrien	    "Thread cancellation signal used by libthread");
73959243Sobrien    }
74059243Sobrien#endif /* SIGCANCEL */
74159243Sobrien
74259243Sobrien/*
74359243Sobrien * Careful, some OS's (HP/UX 10.0) define these as -1
74459243Sobrien */
74559243Sobrien#ifdef SIGRTMIN
74659243Sobrien    /*
74759243Sobrien     * Cannot do this at compile time; Solaris2 uses _sysconf for these
74859243Sobrien     */
74959243Sobrien    if (SIGRTMIN > 0 && SIGRTMIN < NUMSIG) {
75059243Sobrien	if (mesg[SIGRTMIN].pname == NULL) {
75159243Sobrien	    mesg[SIGRTMIN].iname = "RTMIN";
75259243Sobrien	    mesg[SIGRTMIN].pname = CSAVS(2, 68, "First Realtime Signal");
75359243Sobrien	}
75459243Sobrien
755167465Smp	if (SIGRTMIN + 1 < SIGRTMAX && SIGRTMIN + 1 < NUMSIG &&
756167465Smp	    mesg[SIGRTMIN+1].pname == NULL) {
75759243Sobrien	    mesg[SIGRTMIN+1].iname = "RTMIN+1";
75859243Sobrien	    mesg[SIGRTMIN+1].pname = CSAVS(2, 69, "Second Realtime Signal");
75959243Sobrien	}
76059243Sobrien
761167465Smp	if (SIGRTMIN + 2 < SIGRTMAX && SIGRTMIN + 2 < NUMSIG &&
762167465Smp	    mesg[SIGRTMIN+2].pname == NULL) {
76359243Sobrien	    mesg[SIGRTMIN+2].iname = "RTMIN+2";
76459243Sobrien	    mesg[SIGRTMIN+2].pname = CSAVS(2, 70, "Third Realtime Signal");
76559243Sobrien	}
76659243Sobrien
767167465Smp	if (SIGRTMIN + 3 < SIGRTMAX && SIGRTMIN + 3 < NUMSIG &&
768167465Smp	    mesg[SIGRTMIN+3].pname == NULL) {
76959243Sobrien	    mesg[SIGRTMIN+3].iname = "RTMIN+3";
77059243Sobrien	    mesg[SIGRTMIN+3].pname = CSAVS(2, 71, "Fourth Realtime Signal");
77159243Sobrien	}
77259243Sobrien    }
77359243Sobrien#endif /* SIGRTMIN */
77459243Sobrien
77559243Sobrien#ifdef SIGRTMAX
77659243Sobrien    /*
77759243Sobrien     * Cannot do this at compile time; Solaris2 uses _sysconf for these
77859243Sobrien     */
779167465Smp    if (SIGRTMAX > 0 && SIGRTMAX < NUMSIG) {
780167465Smp	if (SIGRTMAX - 3 > SIGRTMIN && mesg[SIGRTMAX-3].pname == NULL) {
78159243Sobrien	    mesg[SIGRTMAX-3].iname = "RTMAX-3";
78259243Sobrien	    mesg[SIGRTMAX-3].pname = CSAVS(2, 72,
78359243Sobrien					   "Fourth Last Realtime Signal");
78459243Sobrien	}
78559243Sobrien
786167465Smp	if (SIGRTMAX - 2 > SIGRTMIN && mesg[SIGRTMAX-2].pname == NULL) {
78759243Sobrien	    mesg[SIGRTMAX-2].iname = "RTMAX-2";
78859243Sobrien	    mesg[SIGRTMAX-2].pname = CSAVS(2, 73,
78959243Sobrien					   "Third Last Realtime Signal");
79059243Sobrien	}
79159243Sobrien
792167465Smp	if (SIGRTMAX - 1 > SIGRTMIN && mesg[SIGRTMAX-1].pname == NULL) {
79359243Sobrien	    mesg[SIGRTMAX-1].iname = "RTMAX-1";
79459243Sobrien	    mesg[SIGRTMAX-1].pname = CSAVS(2, 74,
79559243Sobrien					   "Second Last Realtime Signal");
79659243Sobrien	}
79759243Sobrien
798167465Smp	if (SIGRTMAX > SIGRTMIN && mesg[SIGRTMAX].pname == NULL) {
79959243Sobrien	    mesg[SIGRTMAX].iname = "RTMAX";
80059243Sobrien	    mesg[SIGRTMAX].pname = CSAVS(2, 75,
80159243Sobrien					 "Last Realtime Signal");
80259243Sobrien	}
80359243Sobrien    }
80459243Sobrien#endif /* SIGRTMAX */
80559243Sobrien
80659243Sobrien
80759243Sobrien#ifdef SIGAIO
80859243Sobrien    /* aiws */
80959243Sobrien    if (mesg[SIGAIO].pname == NULL) {
81059243Sobrien	mesg[SIGAIO].iname = "AIO";
81159243Sobrien	mesg[SIGAIO].pname = CSAVS(2, 76, "LAN Asyncronous I/O");
81259243Sobrien    }
81359243Sobrien#endif /* SIGAIO */
81459243Sobrien
81559243Sobrien#ifdef SIGPTY
81659243Sobrien    /* aiws */
81759243Sobrien    if (mesg[SIGPTY].pname == NULL) {
81859243Sobrien	mesg[SIGPTY].iname = "PTY";
81959243Sobrien	mesg[SIGPTY].pname = CSAVS(2, 77, "PTY read/write availability");
82059243Sobrien    }
82159243Sobrien#endif /* SIGPTY */
82259243Sobrien
82359243Sobrien#ifdef SIGIOINT
82459243Sobrien    /* aiws */
82559243Sobrien    if (mesg[SIGIOINT].pname == NULL) {
82659243Sobrien	mesg[SIGIOINT].iname = "IOINT";
82759243Sobrien	mesg[SIGIOINT].pname = CSAVS(2, 78, "I/O intervention required");
82859243Sobrien    }
82959243Sobrien#endif /* SIGIOINT */
83059243Sobrien
83159243Sobrien#ifdef SIGGRANT
83259243Sobrien    /* aiws */
83359243Sobrien    if (mesg[SIGGRANT].pname == NULL) {
83459243Sobrien	mesg[SIGGRANT].iname = "GRANT";
83559243Sobrien	mesg[SIGGRANT].pname = CSAVS(2, 79, "HFT monitor mode granted");
83659243Sobrien    }
83759243Sobrien#endif /* SIGGRANT */
83859243Sobrien
83959243Sobrien#ifdef SIGRETRACT
84059243Sobrien    /* aiws */
84159243Sobrien    if (mesg[SIGRETRACT].pname == NULL) {
84259243Sobrien	mesg[SIGRETRACT].iname = "RETRACT";
84359243Sobrien	mesg[SIGRETRACT].pname = CSAVS(2, 80,
84459243Sobrien				  "HFT monitor mode should be relinguished");
84559243Sobrien    }
84659243Sobrien#endif /* SIGRETRACT */
84759243Sobrien
84859243Sobrien#ifdef SIGSOUND
84959243Sobrien    /* aiws */
85059243Sobrien    if (mesg[SIGSOUND].pname == NULL) {
85159243Sobrien	mesg[SIGSOUND].iname = "SOUND";
85259243Sobrien	mesg[SIGSOUND].pname = CSAVS(2, 81, "HFT sound control has completed");
85359243Sobrien    }
85459243Sobrien#endif /* SIGSOUND */
85559243Sobrien
85659243Sobrien#ifdef SIGSMSG
85759243Sobrien    /* aiws */
85859243Sobrien    if (mesg[SIGSMSG].pname == NULL) {
85959243Sobrien	mesg[SIGSMSG].iname = "SMSG";
86059243Sobrien	mesg[SIGSMSG].pname = CSAVS(2, 82, "Data in HFT ring buffer");
86159243Sobrien    }
86259243Sobrien#endif /* SIGMSG */
86359243Sobrien
86459243Sobrien#ifdef SIGMIGRATE
86559243Sobrien    /* IBMAIX */
86659243Sobrien    if (mesg[SIGMIGRATE].pname == NULL) {
86759243Sobrien	mesg[SIGMIGRATE].iname = "MIGRATE";
86859243Sobrien	mesg[SIGMIGRATE].pname = CSAVS(2, 83, "Migrate process");
86959243Sobrien    }
87059243Sobrien#endif /* SIGMIGRATE */
87159243Sobrien
87259243Sobrien#ifdef SIGSAK
87359243Sobrien    /* IBMAIX */
87459243Sobrien    if (mesg[SIGSAK].pname == NULL) {
87559243Sobrien	mesg[SIGSAK].iname = "SAK";
87659243Sobrien	mesg[SIGSAK].pname = CSAVS(2, 84, "Secure attention key");
87759243Sobrien    }
87859243Sobrien#endif /* SIGSAK */
87959243Sobrien
88059243Sobrien#ifdef SIGRESCHED
88159243Sobrien    /* CX/UX */
88259243Sobrien    if (mesg[SIGRESCHED].pname == NULL) {
88359243Sobrien	mesg[SIGRESCHED].iname = "RESCHED";
88459243Sobrien	mesg[SIGRESCHED].pname = CSAVS(2, 85, "Reschedule");
88559243Sobrien    }
88659243Sobrien#endif /* SIGRESCHED */
88759243Sobrien
88859243Sobrien#ifdef SIGDEBUG
88959243Sobrien    /* VMS_POSIX */
89059243Sobrien    if (mesg[SIGDEBUG].pname == NULL) {
89159243Sobrien	mesg[SIGDEBUG].iname = "DEBUG";
89259243Sobrien	mesg[SIGDEBUG].pname = CSAVS(2, 86, "Signaling SS$_DEBUG");
89359243Sobrien    }
89459243Sobrien#endif /* SIGDEBUG */
89559243Sobrien
89659243Sobrien#ifdef SIGPRIO
89759243Sobrien    /* Lynx */
89859243Sobrien    if (mesg[SIGPRIO].pname == NULL) {
89959243Sobrien	mesg[SIGPRIO].iname = "PRIO";
90059243Sobrien	mesg[SIGPRIO].pname = CSAVS(2, 87, "Priority changed");
90159243Sobrien    }
90259243Sobrien#endif /* SIGPRIO */
90359243Sobrien
90459243Sobrien#ifdef SIGDLK
90559243Sobrien    /* cray */
90659243Sobrien    if (mesg[SIGDLK].pname == NULL) {
90759243Sobrien	mesg[SIGDLK].iname = "DLK";
90859243Sobrien	mesg[SIGDLK].pname = CSAVS(2, 88, "True deadlock detected");
90959243Sobrien    }
91059243Sobrien#endif /* SIGDLK */
91159243Sobrien
91259243Sobrien#ifdef SIGTINT
91359243Sobrien    /* masscomp */
91459243Sobrien    if (mesg[SIGTINT].pname == NULL) {
91559243Sobrien	mesg[SIGTINT].iname = "TINT";
91659243Sobrien	mesg[SIGTINT].pname = CSAVS(2, 89, "New input character");
91759243Sobrien    }
91859243Sobrien#endif /* SIGTINT */
91959243Sobrien
92059243Sobrien#ifdef SIGSTKFLT
92159243Sobrien    if (mesg[SIGSTKFLT].pname == NULL) {
92259243Sobrien	mesg[SIGSTKFLT].iname = "STKFLT";
92359243Sobrien	mesg[SIGSTKFLT].pname = CSAVS(2, 90, "Stack limit exceeded");
92459243Sobrien    }
92559243Sobrien#endif /* SIGSTKFLT */
92659243Sobrien
92759243Sobrien#ifdef SIGUNUSED
92859243Sobrien    if (mesg[SIGUNUSED].pname == NULL) {
92959243Sobrien	mesg[SIGUNUSED].iname = "UNUSED";
93059243Sobrien	mesg[SIGUNUSED].pname = CSAVS(2, 91, "Unused signal");
93159243Sobrien    }
93259243Sobrien#endif /* SIGUNUSED */
93359243Sobrien
93459243Sobrien#ifdef SIGOVLY
93559243Sobrien    /* SX-4 */
93659243Sobrien    if (mesg[SIGOVLY].pname == NULL) {
93759243Sobrien	mesg[SIGOVLY].iname = "OVLY";
93859243Sobrien	mesg[SIGOVLY].pname = CSAVS(2, 92, "LM overlay");
93959243Sobrien    }
94059243Sobrien#endif /* SIGOVLY */
94159243Sobrien
94259243Sobrien#ifdef SIGFRZ
94359243Sobrien    /* SX-4 */
94459243Sobrien    if (mesg[SIGFRZ].pname == NULL) {
94559243Sobrien	mesg[SIGFRZ].iname = "FRZ";
94659243Sobrien	mesg[SIGFRZ].pname = CSAVS(2, 93, "system freeze");
94759243Sobrien    }
94859243Sobrien#endif /* SIGFRZ */
94959243Sobrien
95059243Sobrien#ifdef SIGDFRZ
95159243Sobrien    /* SX-4 */
95259243Sobrien    if (mesg[SIGDFRZ].pname == NULL) {
95359243Sobrien	mesg[SIGDFRZ].iname = "DFRZ";
95459243Sobrien	mesg[SIGDFRZ].pname = CSAVS(2, 94, "system defreeze");
95559243Sobrien    }
95659243Sobrien#endif /* SIGDFRZ */
95759243Sobrien
95859243Sobrien#ifdef SIGDEAD
95959243Sobrien    /* SX-4 */
96059243Sobrien    if (mesg[SIGDEAD].pname == NULL) {
96159243Sobrien	mesg[SIGDEAD].iname = "DEAD";
96259243Sobrien	mesg[SIGDEAD].pname = CSAVS(2, 95, "dead lock");
96359243Sobrien    }
96459243Sobrien#endif /* SIGDEAD */
96559243Sobrien
96659243Sobrien#ifdef SIGXMEM
96759243Sobrien    /* SX-4 */
96859243Sobrien    if (mesg[SIGXMEM].pname == NULL) {
96959243Sobrien	mesg[SIGXMEM].iname = "XMEM";
97059243Sobrien	mesg[SIGXMEM].pname = CSAVS(2, 96, "exceeded memory size limit");
97159243Sobrien    }
97259243Sobrien#endif /* SIGXMEM */
97359243Sobrien
97459243Sobrien#ifdef SIGXDSZ
97559243Sobrien    /* SX-4 */
97659243Sobrien    if (mesg[SIGXDSZ].pname == NULL) {
97759243Sobrien	mesg[SIGXDSZ].iname = "XDSZ";
97859243Sobrien	mesg[SIGXDSZ].pname = CSAVS(2, 97, "exceeded data size limit");
97959243Sobrien    }
98059243Sobrien#endif /* SIGXDSZ */
98159243Sobrien
98259243Sobrien#ifdef SIGMEM32
98359243Sobrien    /* SX-4 */
98459243Sobrien    if (mesg[SIGMEM32].pname == NULL) {
98559243Sobrien	mesg[SIGMEM32].iname = "MEM32";
98659243Sobrien	mesg[SIGMEM32].pname = CSAVS(2, 98, "exceeded memory size limit of 32KB");
98759243Sobrien    }
98859243Sobrien#endif /* SIGMEM32 */
98959243Sobrien
99059243Sobrien#ifdef SIGNMEM
99159243Sobrien    /* SX-4 */
99259243Sobrien    if (mesg[SIGNMEM].pname == NULL) {
99359243Sobrien	mesg[SIGNMEM].iname = "NMEM";
99459243Sobrien	mesg[SIGNMEM].pname = CSAVS(2, 99, "exce error for no memory");
99559243Sobrien    }
99659243Sobrien#endif /* SIGNMEM */
99759243Sobrien
99859243Sobrien#ifdef SIGCHKP
99959243Sobrien    /* SX-4 */
100059243Sobrien    if (mesg[SIGCHKP].pname == NULL) {
100159243Sobrien	mesg[SIGCHKP].iname = "CHKP";
100259243Sobrien	mesg[SIGCHKP].pname = CSAVS(2, 100, "check point start");
100359243Sobrien    }
100459243Sobrien#endif /* SIGCHKP */
100559243Sobrien
100659243Sobrien#ifdef SIGKCHKP
100759243Sobrien#if 0
100859243Sobrien    /* SX-4 */
100959243Sobrien    if (mesg[SIGKCHKP].pname == NULL) {
101059243Sobrien	mesg[SIGKCHKP].iname = "KCHKP";
101159243Sobrien	mesg[SIGKCHKP].pname = CSAVS(2, 101, "check point start of kernel");
101259243Sobrien    }
101359243Sobrien#endif
101459243Sobrien#endif /* SIGKCHKP */
101559243Sobrien
101659243Sobrien#ifdef SIGRSTA
101759243Sobrien    /* SX-4 */
101859243Sobrien    if (mesg[SIGRSTA].pname == NULL) {
101959243Sobrien	mesg[SIGRSTA].iname = "RSTA";
102059243Sobrien	mesg[SIGRSTA].pname = CSAVS(2, 102, "restart start");
102159243Sobrien    }
102259243Sobrien#endif /* SIGRSTA */
102359243Sobrien
102459243Sobrien#ifdef SIGKRSTA
102559243Sobrien#if 0
102659243Sobrien    /* SX-4 */
102759243Sobrien    if (mesg[SIGKRSTA].pname == NULL) {
102859243Sobrien	mesg[SIGKRSTA].iname = "KRSTA";
102959243Sobrien	mesg[SIGKRSTA].pname = CSAVS(2, 103, "restart of kernel");
103059243Sobrien    }
103159243Sobrien#endif
103259243Sobrien#endif /* SIGKRSTA */
103359243Sobrien
103459243Sobrien#ifdef SIGXXMU
103559243Sobrien    /* SX-4 */
103659243Sobrien    if (mesg[SIGXXMU].pname == NULL) {
103759243Sobrien	mesg[SIGXXMU].iname = "XXMU";
103859243Sobrien	mesg[SIGXXMU].pname = CSAVS(2, 104, "exeeded XMU size limit");
103959243Sobrien    }
104059243Sobrien#endif /* SIGXXMU */
104159243Sobrien
104259243Sobrien#ifdef SIGXRLG0
104359243Sobrien    /* SX-4 */
104459243Sobrien    if (mesg[SIGXRLG0].pname == NULL) {
104559243Sobrien	mesg[SIGXRLG0].iname = "XRLG0";
104659243Sobrien	mesg[SIGXRLG0].pname = CSAVS(2, 105, "exeeded RLG0 limit");
104759243Sobrien    }
104859243Sobrien#endif /* SIGXRLG0 */
104959243Sobrien
105059243Sobrien#ifdef SIGXRLG1
105159243Sobrien    /* SX-4 */
105259243Sobrien    if (mesg[SIGXRLG1].pname == NULL) {
105359243Sobrien	mesg[SIGXRLG1].iname = "XRLG1";
105459243Sobrien	mesg[SIGXRLG1].pname = CSAVS(2, 106, "exeeded RLG1 limit");
105559243Sobrien    }
105659243Sobrien#endif /* SIGXRLG1 */
105759243Sobrien
105859243Sobrien#ifdef SIGXRLG2
105959243Sobrien    /* SX-4 */
106059243Sobrien    if (mesg[SIGXRLG2].pname == NULL) {
106159243Sobrien	mesg[SIGXRLG2].iname = "XRLG2";
106259243Sobrien	mesg[SIGXRLG2].pname = CSAVS(2, 107, "exeeded RLG2 limit");
106359243Sobrien    }
106459243Sobrien#endif /* SIGXRLG2 */
106559243Sobrien
106659243Sobrien#ifdef SIGXRLG3
106759243Sobrien    /* SX-4 */
106859243Sobrien    if (mesg[SIGXRLG3].pname == NULL) {
106959243Sobrien	mesg[SIGXRLG3].iname = "XRLG3";
107059243Sobrien	mesg[SIGXRLG3].pname = CSAVS(2, 108, "exeeded RLG3 limit");
107159243Sobrien    }
107259243Sobrien#endif /* SIGXRLG3 */
107359243Sobrien}
1074