Skip to content

Commit 9c56176

Browse files
committed
Auto merge of #949 - humenda:master, r=alexcrichton
redefine pthread_t for l4re-uclibc
2 parents 787420a + aa6afb9 commit 9c56176

File tree

5 files changed

+11
-2
lines changed

5 files changed

+11
-2
lines changed

src/unix/uclibc/mips/mod.rs

+2
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
pub type pthread_t = ::c_ulong;
2+
13
pub const SFD_CLOEXEC: ::c_int = 0x080000;
24

35
pub const NCCS: usize = 32;

src/unix/uclibc/mod.rs

-1
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ pub type id_t = ::c_uint;
1111
pub type useconds_t = u32;
1212
pub type dev_t = u64;
1313
pub type socklen_t = u32;
14-
pub type pthread_t = ::c_ulong;
1514
pub type mode_t = u32;
1615
pub type ino64_t = u64;
1716
pub type off64_t = i64;

src/unix/uclibc/x86_64/l4re.rs

+1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
/// libc and hence we should provide them here.
55
66
pub type l4_umword_t = ::c_ulong; // Unsigned machine word.
7+
pub type pthread_t = *mut ::c_void;
78

89
s! {
910
/// CPU sets.

src/unix/uclibc/x86_64/mod.rs

+4-1
Original file line numberDiff line numberDiff line change
@@ -352,6 +352,9 @@ cfg_if! {
352352
if #[cfg(target_os = "l4re")] {
353353
mod l4re;
354354
pub use self::l4re::*;
355-
} else { }
355+
} else {
356+
mod other;
357+
pub use other::*;
358+
}
356359
}
357360

src/unix/uclibc/x86_64/other.rs

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
// Thestyle checker discourages the use of #[cfg], so this has to go into a
2+
// separate module
3+
pub type pthread_t = ::c_ulong;
4+

0 commit comments

Comments
 (0)