From ab1a10517498d86474f7e2385160cb25c0add531 Mon Sep 17 00:00:00 2001 From: Fenrir Date: Tue, 24 Jan 2017 19:25:43 -0700 Subject: [PATCH] ctr-libc: remove conditional dependency on std I'd thought that it would be necessary for implementing features such as the std::os::raw types in ctr-std, but I do not believe that that is the case. --- ctr-libc/src/lib.rs | 15 +-------------- ctr-std/Cargo.toml | 1 - ctr-std/Xargo.toml | 1 - ctru-rs/Xargo.toml | 1 - ctru-sys/Cargo.toml | 2 +- 5 files changed, 2 insertions(+), 18 deletions(-) diff --git a/ctr-libc/src/lib.rs b/ctr-libc/src/lib.rs index 729a38d..50ead9d 100644 --- a/ctr-libc/src/lib.rs +++ b/ctr-libc/src/lib.rs @@ -10,20 +10,7 @@ #![allow(bad_style, overflowing_literals, improper_ctypes, non_camel_case_types)] -// Attributes needed when building as part of the standard library -#![cfg_attr(stdbuild, feature(no_std, core, core_slice_ext, staged_api, custom_attribute, cfg_target_vendor))] -#![cfg_attr(stdbuild, feature(link_cfg))] -#![cfg_attr(stdbuild, no_std)] -#![cfg_attr(stdbuild, staged_api)] -#![cfg_attr(stdbuild, allow(warnings))] -#![cfg_attr(stdbuild, unstable(feature = "libc", - reason = "use `libc` from crates.io", - issue = "27783"))] - -#![cfg_attr(not(feature = "use_std"), no_std)] - -#[cfg(all(not(stdbuild), not(dox), feature = "use_std"))] -extern crate std as core; +#![no_std] mod constants; mod functions; diff --git a/ctr-std/Cargo.toml b/ctr-std/Cargo.toml index 25193cc..d4394a8 100644 --- a/ctr-std/Cargo.toml +++ b/ctr-std/Cargo.toml @@ -8,7 +8,6 @@ git = "https://github.com/rust-lang-nursery/compiler-builtins" [dependencies.ctr-libc] path = "../ctr-libc" -default-features = false [dependencies.alloc_system] version = "0.1.1" diff --git a/ctr-std/Xargo.toml b/ctr-std/Xargo.toml index 3bc68c1..dc3fd74 100644 --- a/ctr-std/Xargo.toml +++ b/ctr-std/Xargo.toml @@ -2,5 +2,4 @@ [dependencies.ctr-libc] path = "../ctr-libc" -default-features = false stage = 1 diff --git a/ctru-rs/Xargo.toml b/ctru-rs/Xargo.toml index d7e415c..43d0173 100644 --- a/ctru-rs/Xargo.toml +++ b/ctru-rs/Xargo.toml @@ -2,7 +2,6 @@ [dependencies.ctr-libc] path = "../ctr-libc" -default-features = false stage = 1 [dependencies.std] diff --git a/ctru-sys/Cargo.toml b/ctru-sys/Cargo.toml index fa204ee..99e347b 100644 --- a/ctru-sys/Cargo.toml +++ b/ctru-sys/Cargo.toml @@ -5,4 +5,4 @@ authors = ["Ronald Kinard "] license = "https://en.wikipedia.org/wiki/Zlib_License" [dependencies] -ctr-libc = { path = "../ctr-libc", default-features = false } +ctr-libc = { path = "../ctr-libc" }