diff --git a/examples/hello.rs b/examples/hello.rs deleted file mode 100644 index 0ca9c76..0000000 --- a/examples/hello.rs +++ /dev/null @@ -1,21 +0,0 @@ -// Copyright 2014 The syscall.rs Project Developers. See the -// COPYRIGHT file at the top-level directory of this distribution. -// -// Licensed under the Apache License, Version 2.0 or the MIT license -// , at your -// option. This file may not be copied, modified, or distributed -// except according to those terms. - -#[macro_use] -extern crate sc; - -fn write(fd: usize, buf: &[u8]) { - unsafe { - syscall!(WRITE, fd, buf.as_ptr(), buf.len()); - } -} - -fn main() { - write(1, "Hello, world!\n".as_bytes()); -} diff --git a/src/lib.rs b/src/lib.rs index 4a586f6..0406fb3 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -24,15 +24,7 @@ #![allow(deprecated)] // llvm_asm! #![deny(warnings)] #![no_std] -#![cfg_attr(any( - target_arch = "arm", - target_arch = "mips", - target_arch = "mips64", - target_arch = "powerpc", - target_arch = "powerpc64", - target_arch = "sparc64", - target_arch = "x86" -), feature(llvm_asm))] +#![cfg(any(target_arch = "aarch64", target_arch = "riscv64", target_arch = "x86_64"))] #[cfg(test)] extern crate std; diff --git a/tests/test.rs b/tests/test.rs index ca8859b..ab90035 100644 --- a/tests/test.rs +++ b/tests/test.rs @@ -7,6 +7,8 @@ // option. This file may not be copied, modified, or distributed // except according to those terms. +#![cfg(any(target_arch = "aarch64", target_arch = "riscv64", target_arch = "x86_64"))] + #[macro_use] extern crate sc;