File tree Expand file tree Collapse file tree 4 files changed +7
-2
lines changed
src/unix/linux_like/linux Expand file tree Collapse file tree 4 files changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -4305,6 +4305,11 @@ fn test_linux(target: &str) {
43054305 if old_musl && name == "RLIM_NLIMITS" {
43064306 return true ;
43074307 }
4308+ // FIXME: Does not exist on non-x86 architectures, slated for removal
4309+ // in libc in 1.0
4310+ if ppc64 && name == "MAP_32BIT" {
4311+ return true ;
4312+ }
43084313 }
43094314 match name {
43104315 // These constants are not available if gnu headers have been included
Original file line number Diff line number Diff line change @@ -191,7 +191,6 @@ pub const O_NDELAY: c_int = 0x800;
191191pub const MADV_SOFT_OFFLINE : c_int = 101 ;
192192pub const MAP_LOCKED : c_int = 0x02000 ;
193193pub const MAP_NORESERVE : c_int = 0x04000 ;
194- pub const MAP_32BIT : c_int = 0x0040 ;
195194pub const MAP_ANON : c_int = 0x0020 ;
196195pub const MAP_ANONYMOUS : c_int = 0x0020 ;
197196pub const MAP_DENYWRITE : c_int = 0x0800 ;
Original file line number Diff line number Diff line change 7272}
7373
7474pub const MADV_SOFT_OFFLINE : c_int = 101 ;
75+ #[ deprecated( since = "0.2.175" , note = "Linux does not define MAP_32BIT on any architectures \
76+ other than x86 and x86_64, this constant will be removed in the future") ]
7577pub const MAP_32BIT : c_int = 0x0040 ;
7678pub const O_APPEND : c_int = 1024 ;
7779pub const O_DIRECT : c_int = 0x20000 ;
Original file line number Diff line number Diff line change @@ -441,7 +441,6 @@ pub const SYS_set_mempolicy_home_node: c_long = 450;
441441pub const SYS_fadvise : c_long = SYS_fadvise64 ;
442442
443443pub const MADV_SOFT_OFFLINE : c_int = 101 ;
444- pub const MAP_32BIT : c_int = 0x0040 ;
445444pub const O_APPEND : c_int = 1024 ;
446445pub const O_DIRECT : c_int = 0x4000 ;
447446pub const O_DIRECTORY : c_int = 0x10000 ;
You can’t perform that action at this time.
0 commit comments