Skip to content

Commit a8628c3

Browse files
authored
Merge pull request #4171 from sunshowers/sigrt
[solaris/illumos] add SIGRTMIN and SIGRTMAX
2 parents d76b3c8 + a8aaadf commit a8628c3

File tree

4 files changed

+15
-1
lines changed

4 files changed

+15
-1
lines changed

libc-test/build.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,8 @@ fn do_cc() {
4242
|| target.contains("l4re")
4343
|| target.contains("android")
4444
|| target.contains("emscripten")
45+
|| target.contains("solaris")
46+
|| target.contains("illumos")
4547
{
4648
cc::Build::new().file("src/sigrt.c").compile("sigrt");
4749
}

libc-test/semver/solarish.txt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@ LIO_WAIT
1616
LIO_WRITE
1717
PIPE_BUF
1818
SIGEV_PORT
19+
SIGRTMAX
20+
SIGRTMIN
1921
_POSIX_VDISABLE
2022
_ST_FSTYPSZ
2123
aio_cancel

libc-test/test/sigrt.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,9 @@
44
target_os = "linux",
55
target_os = "l4re",
66
target_os = "android",
7-
target_os = "emscripten"
7+
target_os = "emscripten",
8+
target_os = "solaris",
9+
target_os = "illumos",
810
))]
911
mod t {
1012
use libc;

src/unix/solarish/mod.rs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2542,6 +2542,14 @@ f! {
25422542
}
25432543

25442544
safe_f! {
2545+
pub fn SIGRTMAX() -> c_int {
2546+
unsafe { crate::sysconf(_SC_SIGRT_MAX) as c_int }
2547+
}
2548+
2549+
pub fn SIGRTMIN() -> c_int {
2550+
unsafe { crate::sysconf(_SC_SIGRT_MIN) as c_int }
2551+
}
2552+
25452553
pub {const} fn WIFEXITED(status: c_int) -> bool {
25462554
(status & 0xFF) == 0
25472555
}

0 commit comments

Comments
 (0)