Skip to content

Commit f8da228

Browse files
committed
Merge pull request rust-lang#143 from Mokosha/AddPowerPCSupport
Preliminary PowerPC Support
2 parents aea17ed + 2cf9e82 commit f8da228

File tree

3 files changed

+26
-1
lines changed

3 files changed

+26
-1
lines changed

src/unix/notbsd/linux/other/b32/mod.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,9 @@ cfg_if! {
8686
} else if #[cfg(target_arch = "arm")] {
8787
mod arm;
8888
pub use self::arm::*;
89+
} else if #[cfg(target_arch = "powerpc")] {
90+
mod powerpc;
91+
pub use self::powerpc::*;
8992
} else {
9093
// ...
9194
}
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
pub type c_char = u8;
2+
pub type wchar_t = i32;
3+
4+
pub const O_DIRECT: ::c_int = 0x20000;
5+
pub const O_DIRECTORY: ::c_int = 0x4000;
6+
pub const O_NOFOLLOW: ::c_int = 0x8000;
7+
8+
pub const MAP_LOCKED: ::c_int = 0x00080;
9+
pub const MAP_NORESERVE: ::c_int = 0x00040;
10+
11+
pub const EDEADLOCK: ::c_int = 58;
12+
13+
pub const SO_PEERCRED: ::c_int = 21;
14+
pub const SO_RCVLOWAT: ::c_int = 16;
15+
pub const SO_SNDLOWAT: ::c_int = 17;
16+
pub const SO_RCVTIMEO: ::c_int = 18;
17+
pub const SO_SNDTIMEO: ::c_int = 19;
18+
19+
pub const FIOCLEX: ::c_ulong = 0x20006601;
20+
pub const FIONBIO: ::c_ulong = 0x8004667e;

src/unix/notbsd/linux/other/mod.rs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -429,7 +429,9 @@ extern {
429429
}
430430

431431
cfg_if! {
432-
if #[cfg(any(target_arch = "x86", target_arch = "arm"))] {
432+
if #[cfg(any(target_arch = "x86",
433+
target_arch = "arm",
434+
target_arch = "powerpc"))] {
433435
mod b32;
434436
pub use self::b32::*;
435437
} else if #[cfg(any(target_arch = "x86_64",

0 commit comments

Comments
 (0)