| ... | @@ -31,6 +31,7 @@ pub usingnamespace @import("linux/securebits.zig"); | ... | @@ -31,6 +31,7 @@ pub usingnamespace @import("linux/securebits.zig"); |
| 31 | | 31 | |
| 32 | const is_mips = builtin.arch.isMIPS(); | 32 | const is_mips = builtin.arch.isMIPS(); |
| 33 | const is_ppc64 = builtin.arch.isPPC64(); | 33 | const is_ppc64 = builtin.arch.isPPC64(); |
| | 34 | const is_sparc = builtin.arch.isSPARC(); |
| 34 | | 35 | |
| 35 | pub const pid_t = i32; | 36 | pub const pid_t = i32; |
| 36 | pub const fd_t = i32; | 37 | pub const fd_t = i32; |
| ... | @@ -183,16 +184,32 @@ pub usingnamespace if (is_mips) | ... | @@ -183,16 +184,32 @@ pub usingnamespace if (is_mips) |
| 183 | pub const SA_NOCLDSTOP = 1; | 184 | pub const SA_NOCLDSTOP = 1; |
| 184 | pub const SA_NOCLDWAIT = 0x10000; | 185 | pub const SA_NOCLDWAIT = 0x10000; |
| 185 | pub const SA_SIGINFO = 8; | 186 | pub const SA_SIGINFO = 8; |
| | 187 | pub const SA_RESTART = 0x10000000; |
| | 188 | pub const SA_RESETHAND = 0x80000000; |
| 186 | | 189 | |
| 187 | pub const SIG_BLOCK = 1; | 190 | pub const SIG_BLOCK = 1; |
| 188 | pub const SIG_UNBLOCK = 2; | 191 | pub const SIG_UNBLOCK = 2; |
| 189 | pub const SIG_SETMASK = 3; | 192 | pub const SIG_SETMASK = 3; |
| 190 | } | 193 | } |
| | 194 | else if (is_sparc) |
| | 195 | struct { |
| | 196 | pub const SA_NOCLDSTOP = 1; |
| | 197 | pub const SA_NOCLDWAIT = 2; |
| | 198 | pub const SA_SIGINFO = 0x200; |
| | 199 | pub const SA_RESTART = 0x2; |
| | 200 | pub const SA_RESETHAND = 0x4; |
| | 201 | |
| | 202 | pub const SIG_BLOCK = 0; |
| | 203 | pub const SIG_UNBLOCK = 1; |
| | 204 | pub const SIG_SETMASK = 2; |
| | 205 | } |
| 191 | else | 206 | else |
| 192 | struct { | 207 | struct { |
| 193 | pub const SA_NOCLDSTOP = 1; | 208 | pub const SA_NOCLDSTOP = 1; |
| 194 | pub const SA_NOCLDWAIT = 2; | 209 | pub const SA_NOCLDWAIT = 2; |
| 195 | pub const SA_SIGINFO = 4; | 210 | pub const SA_SIGINFO = 4; |
| | 211 | pub const SA_RESTART = 0x10000000; |
| | 212 | pub const SA_RESETHAND = 0x80000000; |
| 196 | | 213 | |
| 197 | pub const SIG_BLOCK = 0; | 214 | pub const SIG_BLOCK = 0; |
| 198 | pub const SIG_UNBLOCK = 1; | 215 | pub const SIG_UNBLOCK = 1; |
| ... | @@ -200,9 +217,7 @@ else | ... | @@ -200,9 +217,7 @@ else |
| 200 | }; | 217 | }; |
| 201 | | 218 | |
| 202 | pub const SA_ONSTACK = 0x08000000; | 219 | pub const SA_ONSTACK = 0x08000000; |
| 203 | pub const SA_RESTART = 0x10000000; | | |
| 204 | pub const SA_NODEFER = 0x40000000; | 220 | pub const SA_NODEFER = 0x40000000; |
| 205 | pub const SA_RESETHAND = 0x80000000; | | |
| 206 | pub const SA_RESTORER = 0x04000000; | 221 | pub const SA_RESTORER = 0x04000000; |
| 207 | | 222 | |
| 208 | pub const SIGHUP = 1; | 223 | pub const SIGHUP = 1; |