From 95928654a65a5ad8a4f221a743036d99f1bdda86 Mon Sep 17 00:00:00 2001 From: YadominJinta <1782397074@qq.com> Date: Mon, 13 Jul 2020 01:13:06 +0800 Subject: [PATCH] Fix build for target android --- lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib.rs b/lib.rs index c441271..689a43d 100644 --- a/lib.rs +++ b/lib.rs @@ -621,7 +621,7 @@ pub fn boottime() -> Result { tv_usec: 0 }; - #[cfg(target_os = "linux")] + #[cfg(any(target_os = "linux", target_os="android"))] { let mut s = String::new(); File::open("/proc/uptime")?.read_to_string(&mut s)?;