diff options
author | 2018-04-06 16:27:08 +0200 | |
---|---|---|
committer | 2018-04-09 00:51:42 +0200 | |
commit | a460a9a554d4f34ae7f04ed26384e7d9753125fa (patch) | |
tree | 019557be91091b3e91da406fdb8d81b15adb5a8d /cortex-m-rt | |
parent | aa9c16d736f42b470beb2624cb4cbf931aaec294 (diff) | |
download | cortex-m-a460a9a554d4f34ae7f04ed26384e7d9753125fa.tar.gz cortex-m-a460a9a554d4f34ae7f04ed26384e7d9753125fa.tar.zst cortex-m-a460a9a554d4f34ae7f04ed26384e7d9753125fa.zip |
drop support of older nightlies
Minor version has been bumped to v0.4.0 so we can stop supporting them
This also drop the chrono dependency, which some people have been running into problems with.
closes #60
Diffstat (limited to 'cortex-m-rt')
-rw-r--r-- | cortex-m-rt/Cargo.toml | 4 | ||||
-rw-r--r-- | cortex-m-rt/build.rs | 19 | ||||
-rw-r--r-- | cortex-m-rt/src/lang_items.rs | 11 |
3 files changed, 0 insertions, 34 deletions
diff --git a/cortex-m-rt/Cargo.toml b/cortex-m-rt/Cargo.toml index 5086034..45f0b07 100644 --- a/cortex-m-rt/Cargo.toml +++ b/cortex-m-rt/Cargo.toml @@ -16,7 +16,3 @@ r0 = "0.2.1" [features] # provides a panic_fmt implementation that calls the abort instruction (`udf 0xfe`) abort-on-panic = [] - -[build-dependencies] -rustc_version = "0.2.1" -chrono = "0.4.0" diff --git a/cortex-m-rt/build.rs b/cortex-m-rt/build.rs index c1028c4..1d0160c 100644 --- a/cortex-m-rt/build.rs +++ b/cortex-m-rt/build.rs @@ -1,28 +1,9 @@ -extern crate chrono; -extern crate rustc_version; - use std::env; use std::fs::File; use std::io::Write; use std::path::PathBuf; -use chrono::NaiveDate; - fn main() { - let meta = rustc_version::version_meta().unwrap(); - let commit_date = meta.commit_date.unwrap().parse::<NaiveDate>().unwrap(); - if meta.channel == rustc_version::Channel::Dev - || commit_date > NaiveDate::from_ymd(2017, 12, 26) - { - println!("cargo:rustc-cfg=has_termination_lang") - } - - // newest nightlies don't need 'extern crate compiler_builtins' - if commit_date < NaiveDate::from_ymd(2018, 04, 07) - { - println!("cargo:rustc-cfg=needs_cb") - } - let target = env::var("TARGET").unwrap(); has_fpu(&target); diff --git a/cortex-m-rt/src/lang_items.rs b/cortex-m-rt/src/lang_items.rs index f3750a0..7d7a598 100644 --- a/cortex-m-rt/src/lang_items.rs +++ b/cortex-m-rt/src/lang_items.rs @@ -24,7 +24,6 @@ unsafe extern "C" fn panic_fmt(_: ::core::fmt::Arguments, _: &'static str, _: u3 // The final piece is that the entry point of our program, the reset handler, // has to call `rustc_main`. That's covered by the `reset_handler` function in // root of this crate. -#[cfg(has_termination_lang)] #[lang = "start"] extern "C" fn start<T>(main: fn() -> T, _argc: isize, _argv: *const *const u8) -> isize where @@ -35,21 +34,11 @@ where 0 } -#[cfg(not(has_termination_lang))] -#[lang = "start"] -extern "C" fn start(main: fn(), _argc: isize, _argv: *const *const u8) -> isize { - main(); - - 0 -} - #[lang = "termination"] -#[cfg(has_termination_lang)] pub trait Termination { fn report(self) -> i32; } -#[cfg(has_termination_lang)] impl Termination for () { fn report(self) -> i32 { 0 |