about summary refs log tree commit diff
path: root/library/std/src/sys/pal/unix
diff options
context:
space:
mode:
Diffstat (limited to 'library/std/src/sys/pal/unix')
-rw-r--r--library/std/src/sys/pal/unix/fd.rs1
-rw-r--r--library/std/src/sys/pal/unix/stack_overflow.rs8
2 files changed, 6 insertions, 3 deletions
diff --git a/library/std/src/sys/pal/unix/fd.rs b/library/std/src/sys/pal/unix/fd.rs
index 8ec2a08966e..eb873759ecb 100644
--- a/library/std/src/sys/pal/unix/fd.rs
+++ b/library/std/src/sys/pal/unix/fd.rs
@@ -75,6 +75,7 @@ const fn max_iov() -> usize {
     target_os = "horizon",
     target_os = "vita",
     target_vendor = "apple",
+    target_os = "cygwin",
 )))]
 const fn max_iov() -> usize {
     16 // The minimum value required by POSIX.
diff --git a/library/std/src/sys/pal/unix/stack_overflow.rs b/library/std/src/sys/pal/unix/stack_overflow.rs
index 5a639d0545b..463f18800a6 100644
--- a/library/std/src/sys/pal/unix/stack_overflow.rs
+++ b/library/std/src/sys/pal/unix/stack_overflow.rs
@@ -316,7 +316,8 @@ mod imp {
         target_os = "netbsd",
         target_os = "hurd",
         target_os = "linux",
-        target_os = "l4re"
+        target_os = "l4re",
+        target_os = "cygwin"
     ))]
     unsafe fn get_stack_start() -> Option<*mut libc::c_void> {
         let mut ret = None;
@@ -371,7 +372,7 @@ mod imp {
             // this way someone on any unix-y OS can check that all these compile
             if cfg!(all(target_os = "linux", not(target_env = "musl"))) {
                 install_main_guard_linux(page_size)
-            } else if cfg!(all(target_os = "linux", target_env = "musl")) {
+            } else if cfg!(any(all(target_os = "linux", target_env = "musl"), target_os = "cygwin")) {
                 install_main_guard_linux_musl(page_size)
             } else if cfg!(target_os = "freebsd") {
                 install_main_guard_freebsd(page_size)
@@ -511,7 +512,8 @@ mod imp {
         target_os = "hurd",
         target_os = "linux",
         target_os = "netbsd",
-        target_os = "l4re"
+        target_os = "l4re",
+        target_os = "cygwin"
     ))]
     // FIXME: I am probably not unsafe.
     unsafe fn current_guard() -> Option<Range<usize>> {