summaryrefslogtreecommitdiff
path: root/shells/scsh/patches/patch-ag
blob: ba602adf2d028ffe905f572bf90ab58000e23f7e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
$NetBSD: patch-ag,v 1.3 2002/06/06 21:54:39 cjep Exp $

--- scsh/bsd/signals1.c.orig	Thu Sep 12 07:01:30 1996
+++ scsh/bsd/signals1.c
@@ -5,6 +5,10 @@
 /* Make sure our exports match up w/the implementation: */
 #include "../signals1.h"
 
+#if defined(__NetBSD__)
+#include <sys/param.h>
+#endif
+
 /* This table converts Unix signal numbers to S48/scsh interrupt numbers.
 ** If the signal doesn't have an interrupt number, the entry is -1.
 ** (Only asynchronous signals have interrupt numbers.)
@@ -45,10 +49,50 @@
 	scshint_winch,	/* SIGWINCH */
 	scshint_info,	/* SIGINFO */
 	scshint_usr1,	/* SIGUSR1 */
-	scshint_usr2	/* SIGUSR2 */
+	scshint_usr2,	/* SIGUSR2 */
+#if defined(__NetBSD__) && defined(__NetBSD_Version__) 
+#if (__NetBSD_Version__ >= 105290000) /* XXX Need to refine this */
+        scshint_pwr,    /* SIGPWR */
+        -1,	/* SIGRTMIN + 0 */
+        -1,	/* SIGRTMIN + 1 */
+        -1,	/* SIGRTMIN + 2 */
+        -1,	/* SIGRTMIN + 3 */
+        -1,	/* SIGRTMIN + 4 */
+        -1,	/* SIGRTMIN + 5 */
+        -1,	/* SIGRTMIN + 6 */
+        -1,	/* SIGRTMIN + 7 */
+        -1,	/* SIGRTMIN + 8 */
+        -1,	/* SIGRTMIN + 9 */
+        -1,	/* SIGRTMIN + 10 */
+        -1,	/* SIGRTMIN + 11 */
+        -1,	/* SIGRTMIN + 12 */
+        -1,	/* SIGRTMIN + 13 */
+        -1,	/* SIGRTMIN + 14 */
+        -1,	/* SIGRTMIN + 15 */
+        -1,	/* SIGRTMIN + 16 */
+        -1,	/* SIGRTMIN + 17 */
+        -1,	/* SIGRTMIN + 18 */
+        -1,	/* SIGRTMIN + 19 */
+        -1,	/* SIGRTMIN + 20 */
+        -1,	/* SIGRTMIN + 21 */
+        -1,	/* SIGRTMIN + 22 */
+        -1,	/* SIGRTMIN + 23 */
+        -1,	/* SIGRTMIN + 24 */
+        -1,	/* SIGRTMIN + 25 */
+        -1,	/* SIGRTMIN + 26 */
+        -1,	/* SIGRTMIN + 27 */
+        -1,	/* SIGRTMIN + 28 */
+        -1,	/* SIGRTMIN + 29 */
+        -1 	/* SIGRTMIN + 30 */
+#elif (__NetBSD_Version__ >= 103080000)
+        scshint_pwr    /* SIGPWR */
+#endif
+#endif
+
+
         };
 
-const int max_sig = 31; /* SIGUSR2 */
+const int max_sig = (sizeof(sig2int)/sizeof(int)) - 1;
 
 /*
 scshint_alarm