From c9e26c865d945548ad93069573d8be1cacf9ed35 Mon Sep 17 00:00:00 2001 From: Johnathan Sharratt Date: Thu, 26 May 2022 14:34:30 +0200 Subject: [PATCH] Modifications needed to compile wasm64-wasi --- src/lib.rs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/src/lib.rs b/src/lib.rs index b155f08..3e68a21 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -36,7 +36,7 @@ pub enum Stream { } /// returns true if this is a tty -#[cfg(all(unix, not(target_arch = "wasm32")))] +#[cfg(all(unix, not(any(target_arch = "wasm32", target_arch = "wasm64"))))] pub fn is(stream: Stream) -> bool { extern crate libc; @@ -154,7 +154,11 @@ unsafe fn msys_tty_on(fd: DWORD) -> bool { } /// returns true if this is a tty -#[cfg(any(target_arch = "wasm32", target_env = "sgx"))] +#[cfg(not(any( + all(unix, not(any(target_arch = "wasm32", target_arch = "wasm64"))), + target_os = "hermit", + windows +)))] pub fn is(_stream: Stream) -> bool { false }