Auto merge of #1470 - semarie:openbsd-sparc64, r=gnzlbg
add support for sparc64 on OpenBSD
This commit is contained in:
commit
dab1050e40
@ -12,3 +12,5 @@ cfg_if! {
|
|||||||
pub const _ALIGNBYTES: usize = 8 - 1;
|
pub const _ALIGNBYTES: usize = 8 - 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub const _MAX_PAGE_SHIFT: u32 = 12;
|
||||||
|
@ -1297,8 +1297,9 @@ pub const IFF_LINK1: ::c_int = 0x2000; // per link layer defined bit
|
|||||||
pub const IFF_LINK2: ::c_int = 0x4000; // per link layer defined bit
|
pub const IFF_LINK2: ::c_int = 0x4000; // per link layer defined bit
|
||||||
pub const IFF_MULTICAST: ::c_int = 0x8000; // supports multicast
|
pub const IFF_MULTICAST: ::c_int = 0x8000; // supports multicast
|
||||||
|
|
||||||
pub const PTHREAD_STACK_MIN : ::size_t = 4096;
|
pub const PTHREAD_STACK_MIN: ::size_t = (1_usize << _MAX_PAGE_SHIFT);
|
||||||
pub const SIGSTKSZ : ::size_t = 28672;
|
pub const MINSIGSTKSZ: ::size_t = (3_usize << _MAX_PAGE_SHIFT);
|
||||||
|
pub const SIGSTKSZ: ::size_t = MINSIGSTKSZ + (1_usize << _MAX_PAGE_SHIFT) * 4;
|
||||||
|
|
||||||
pub const PT_FIRSTMACH: ::c_int = 32;
|
pub const PT_FIRSTMACH: ::c_int = 32;
|
||||||
|
|
||||||
@ -1437,6 +1438,9 @@ cfg_if! {
|
|||||||
} else if #[cfg(target_arch = "aarch64")] {
|
} else if #[cfg(target_arch = "aarch64")] {
|
||||||
mod aarch64;
|
mod aarch64;
|
||||||
pub use self::aarch64::*;
|
pub use self::aarch64::*;
|
||||||
|
} else if #[cfg(target_arch = "sparc64")] {
|
||||||
|
mod sparc64;
|
||||||
|
pub use self::sparc64::*;
|
||||||
} else {
|
} else {
|
||||||
// Unknown target_arch
|
// Unknown target_arch
|
||||||
}
|
}
|
||||||
|
8
src/unix/bsd/netbsdlike/openbsd/sparc64.rs
Normal file
8
src/unix/bsd/netbsdlike/openbsd/sparc64.rs
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
pub type c_long = i64;
|
||||||
|
pub type c_ulong = u64;
|
||||||
|
pub type c_char = i8;
|
||||||
|
|
||||||
|
#[doc(hidden)]
|
||||||
|
pub const _ALIGNBYTES: usize = 0xf;
|
||||||
|
|
||||||
|
pub const _MAX_PAGE_SHIFT: u32 = 13;
|
@ -12,3 +12,5 @@ cfg_if! {
|
|||||||
pub const _ALIGNBYTES: usize = 4 - 1;
|
pub const _ALIGNBYTES: usize = 4 - 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub const _MAX_PAGE_SHIFT: u32 = 12;
|
||||||
|
@ -15,6 +15,8 @@ cfg_if! {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub const _MAX_PAGE_SHIFT: u32 = 12;
|
||||||
|
|
||||||
pub const PT_STEP: ::c_int = PT_FIRSTMACH + 0;
|
pub const PT_STEP: ::c_int = PT_FIRSTMACH + 0;
|
||||||
pub const PT_GETREGS: ::c_int = PT_FIRSTMACH + 1;
|
pub const PT_GETREGS: ::c_int = PT_FIRSTMACH + 1;
|
||||||
pub const PT_SETREGS: ::c_int = PT_FIRSTMACH + 2;
|
pub const PT_SETREGS: ::c_int = PT_FIRSTMACH + 2;
|
||||||
|
Loading…
Reference in New Issue
Block a user