Expand description
Rust friendly bindings to the various *nix system functions.
Modules are structured according to the C header file that they would be defined in.
Re-exports§
pub use libc;
Modules§
- dir
- env
- Environment variables
- errno
- fcntl
- features
- Feature tests for OS functionality
- ifaddrs
- Query network interface addresses
- kmod
- Load and unload kernel modules.
- mount
- Mount file systems
- mqueue
- Posix Message Queue functions
- net
- Functionality involving network interfaces
- poll
- Wait for events to trigger on specific file descriptors
- pty
- Create master and slave virtual pseudo-terminals (PTYs)
- sched
- Execution scheduling
- sys
- Mostly platform-specific functionality
- time
- ucontext
- unistd
- Safe wrappers around functions found in libc “unistd.h” header
Macros§
- cmsg_
space - Create a buffer large enough for storing some control messages as returned
by
recvmsg
. - ioctl_
none - Generates a wrapper function for an ioctl that passes no data to the kernel.
- ioctl_
none_ bad - Generates a wrapper function for a “bad” ioctl that passes no data to the kernel.
- ioctl_
read - Generates a wrapper function for an ioctl that reads data from the kernel.
- ioctl_
read_ bad - Generates a wrapper function for a “bad” ioctl that reads data from the kernel.
- ioctl_
read_ buf - Generates a wrapper function for an ioctl that reads an array of elements from the kernel.
- ioctl_
readwrite - Generates a wrapper function for an ioctl that reads and writes data to the kernel.
- ioctl_
readwrite_ bad - Generates a wrapper function for a “bad” ioctl that reads and writes data to the kernel.
- ioctl_
readwrite_ buf - Generates a wrapper function for an ioctl that reads and writes an array of elements to the kernel.
- ioctl_
write_ buf - Generates a wrapper function for an ioctl that writes an array of elements to the kernel.
- ioctl_
write_ int - Generates a wrapper function for a ioctl that writes an integer to the kernel.
- ioctl_
write_ int_ bad - Generates a wrapper function for a “bad” ioctl that writes an integer to the kernel.
- ioctl_
write_ ptr - Generates a wrapper function for an ioctl that writes data through a pointer to the kernel.
- ioctl_
write_ ptr_ bad - Generates a wrapper function for a “bad” ioctl that writes data through a pointer to the kernel.
- request_
code_ none - Generate an ioctl request code for a command that passes no data.
- request_
code_ read - Generate an ioctl request code for a command that reads.
- request_
code_ readwrite - Generate an ioctl request code for a command that reads and writes.
- request_
code_ write - Generate an ioctl request code for a command that writes.
Traits§
- NixPath
- Common trait used to represent file system paths by many Nix functions.