aboutsummaryrefslogtreecommitdiff
path: root/build.rs
diff options
context:
space:
mode:
authorGravatar Jorge Aparicio <jorge@japaric.io> 2017-06-28 22:35:45 -0500
committerGravatar Jorge Aparicio <jorge@japaric.io> 2017-06-30 12:33:38 -0500
commit75c1148cd9f5fe7e10ce0c7e1e691185dd92c060 (patch)
treef34c5446e77931cfa85f32ab415a442bee634772 /build.rs
parent04283fa386201982cf2132f7be177383a685c9e5 (diff)
downloadcortex-m-75c1148cd9f5fe7e10ce0c7e1e691185dd92c060.tar.gz
cortex-m-75c1148cd9f5fe7e10ce0c7e1e691185dd92c060.tar.zst
cortex-m-75c1148cd9f5fe7e10ce0c7e1e691185dd92c060.zip
make the FPU API available only to targets that have a FPU
closes #49
Diffstat (limited to 'build.rs')
-rw-r--r--build.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/build.rs b/build.rs
index 1f6d605..4d5a706 100644
--- a/build.rs
+++ b/build.rs
@@ -11,4 +11,8 @@ fn main() {
println!("cargo:rustc-cfg=armv7m");
//println!("cargo:rustc-cfg=armv7em");
}
+
+ if target.ends_with("eabihf") {
+ println!("cargo:rustc-cfg=has_fpu");
+ }
}