Support Android

I'll send a PR after https://github.com/rust-lang/libc/pull/1622 is merged and released
This commit is contained in:
Yuji Yamamoto
2019-12-19 11:08:43 +09:00
committed by YAMAMOTO Yuji
parent 704c34283f
commit 0df0a1cccb
7 changed files with 36 additions and 9 deletions

View File

@ -743,7 +743,10 @@ pub unsafe fn get_fault_info(siginfo: *const c_void, ucontext: *mut c_void) -> F
}
}
#[cfg(all(target_os = "linux", target_arch = "aarch64"))]
#[cfg(all(
any(target_os = "linux", target_os = "android"),
target_arch = "aarch64"
))]
/// Get fault info from siginfo and ucontext.
pub unsafe fn get_fault_info(siginfo: *const c_void, ucontext: *mut c_void) -> FaultInfo {
#[allow(dead_code)]
@ -810,7 +813,10 @@ pub unsafe fn get_fault_info(siginfo: *const c_void, ucontext: *mut c_void) -> F
}
}
#[cfg(all(target_os = "linux", target_arch = "x86_64"))]
#[cfg(all(
any(target_os = "linux", target_os = "android"),
target_arch = "x86_64"
))]
/// Get fault info from siginfo and ucontext.
pub unsafe fn get_fault_info(siginfo: *const c_void, ucontext: *mut c_void) -> FaultInfo {
use libc::{