summaryrefslogtreecommitdiffstats
path: root/vendor/rustix/src/lib.rs
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/rustix/src/lib.rs')
-rw-r--r--vendor/rustix/src/lib.rs34
1 files changed, 25 insertions, 9 deletions
diff --git a/vendor/rustix/src/lib.rs b/vendor/rustix/src/lib.rs
index a23006f9c..03f37d96e 100644
--- a/vendor/rustix/src/lib.rs
+++ b/vendor/rustix/src/lib.rs
@@ -94,7 +94,7 @@
//! [I/O-safe]: https://github.com/rust-lang/rfcs/blob/master/text/3128-io-safety.md
//! [`Result`]: https://doc.rust-lang.org/stable/std/result/enum.Result.html
//! [`Arg`]: https://docs.rs/rustix/*/rustix/path/trait.Arg.html
-//! [support for externally defined flags]: https://docs.rs/bitflags/latest/bitflags/#externally-defined-flags
+//! [support for externally defined flags]: https://docs.rs/bitflags/*/bitflags/#externally-defined-flags
#![deny(missing_docs)]
#![allow(stable_features)]
@@ -115,13 +115,17 @@
)]
#![cfg_attr(asm_experimental_arch, feature(asm_experimental_arch))]
#![cfg_attr(not(feature = "all-apis"), allow(dead_code))]
-// It is common in linux and libc APIs for types to vary between platforms.
+// It is common in Linux and libc APIs for types to vary between platforms.
#![allow(clippy::unnecessary_cast)]
-// It is common in linux and libc APIs for types to vary between platforms.
+// It is common in Linux and libc APIs for types to vary between platforms.
#![allow(clippy::useless_conversion)]
// Redox and WASI have enough differences that it isn't worth precisely
-// conditionalizing all the `use`s for them.
-#![cfg_attr(any(target_os = "redox", target_os = "wasi"), allow(unused_imports))]
+// conditionalizing all the `use`s for them. Similar for if we don't have
+// "all-apis".
+#![cfg_attr(
+ any(target_os = "redox", target_os = "wasi", not(feature = "all-apis")),
+ allow(unused_imports)
+)]
#[cfg(all(feature = "alloc", not(feature = "rustc-dep-of-std")))]
extern crate alloc;
@@ -202,7 +206,7 @@ pub mod io;
#[cfg_attr(doc_cfg, doc(cfg(feature = "io_uring")))]
pub mod io_uring;
pub mod ioctl;
-#[cfg(not(any(windows, target_os = "espidf", target_os = "wasi")))]
+#[cfg(not(any(windows, target_os = "espidf", target_os = "vita", target_os = "wasi")))]
#[cfg(feature = "mm")]
#[cfg_attr(doc_cfg, doc(cfg(feature = "mm")))]
pub mod mm;
@@ -246,6 +250,16 @@ pub mod pty;
#[cfg(feature = "rand")]
#[cfg_attr(doc_cfg, doc(cfg(feature = "rand")))]
pub mod rand;
+#[cfg(not(any(
+ windows,
+ target_os = "android",
+ target_os = "espidf",
+ target_os = "vita",
+ target_os = "wasi"
+)))]
+#[cfg(feature = "shm")]
+#[cfg_attr(doc_cfg, doc(cfg(feature = "shm")))]
+pub mod shm;
#[cfg(not(windows))]
#[cfg(feature = "stdio")]
#[cfg_attr(doc_cfg, doc(cfg(feature = "stdio")))]
@@ -254,7 +268,7 @@ pub mod stdio;
#[cfg(not(any(windows, target_os = "wasi")))]
#[cfg_attr(doc_cfg, doc(cfg(feature = "system")))]
pub mod system;
-#[cfg(not(windows))]
+#[cfg(not(any(windows, target_os = "vita")))]
#[cfg(feature = "termios")]
#[cfg_attr(doc_cfg, doc(cfg(feature = "termios")))]
pub mod termios;
@@ -326,7 +340,8 @@ mod clockid;
feature = "runtime",
feature = "termios",
feature = "thread",
- all(bsd, feature = "event")
+ all(bsd, feature = "event"),
+ all(linux_kernel, feature = "net")
))]
mod pid;
#[cfg(any(feature = "process", feature = "thread"))]
@@ -369,6 +384,7 @@ mod timespec;
feature = "time",
target_arch = "x86",
)
- )
+ ),
+ all(linux_kernel, feature = "net")
))]
mod ugid;