summaryrefslogtreecommitdiff
path: root/build.rs
diff options
context:
space:
mode:
authorAaron Hill <aa1ronham@gmail.com>2019-10-28 21:09:30 -0400
committerAaron Hill <aa1ronham@gmail.com>2019-10-28 21:10:03 -0400
commitb0ba2de7676af63ba4c13d7184b3f630735e7e7b (patch)
tree01705b4575a99407f9496d5bacf4e9c68acf9315 /build.rs
parent457d65439610ae70b38e05ac83dde1419670727a (diff)
downloadrust-libc-b0ba2de7676af63ba4c13d7184b3f630735e7e7b.tar.gz
Add Linux test
Diffstat (limited to 'build.rs')
-rw-r--r--build.rs5
1 files changed, 5 insertions, 0 deletions
diff --git a/build.rs b/build.rs
index d5bcb5253a..fb1aae9be4 100644
--- a/build.rs
+++ b/build.rs
@@ -7,6 +7,7 @@ fn main() {
rustc_minor_version().expect("Failed to get rustc version");
let rustc_dep_of_std = env::var("CARGO_FEATURE_RUSTC_DEP_OF_STD").is_ok();
let align_cargo_feature = env::var("CARGO_FEATURE_ALIGN").is_ok();
+ let const_extern_fn_cargo_feature = env::var("CARGO_FEATURE_CONST_EXTERN_FN").is_ok();
let libc_ci = env::var("LIBC_CI").is_ok();
if env::var("CARGO_FEATURE_USE_STD").is_ok() {
@@ -72,6 +73,10 @@ fn main() {
if rustc_dep_of_std {
println!("cargo:rustc-cfg=libc_thread_local");
}
+
+ if const_extern_fn_cargo_feature {
+ println!("cargo:rustc-cfg=libc_const_extern_fn");
+ }
}
fn rustc_minor_version() -> Option<u32> {