Improve sysconf.h on Linux
I copied the constants and definitions from musl which we can presume is correct. Relibc is missing some features which affects our sysconf as well, such as constants in limits.h or a working resources.h.
This commit is contained in:
@@ -4,3 +4,8 @@ pub const HOST_NAME_MAX: usize = 64;
|
||||
pub const PASS_MAX: usize = 128;
|
||||
pub const PATH_MAX: usize = 4096;
|
||||
pub const NGROUPS_MAX: usize = 65536;
|
||||
|
||||
// TODO: 4096 for most architectures as determined by a quick grep of musl's source; need a better
|
||||
// way to determine it for other archs or to hard code a value.
|
||||
#[cfg(target_os = "linux")]
|
||||
pub const PAGE_SIZE: usize = 4096;
|
||||
|
||||
Reference in New Issue
Block a user