summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPietro Albini <pietro.albini@ferrous-systems.com>2023-03-08 09:28:12 +0100
committerPietro Albini <pietro.albini@ferrous-systems.com>2023-03-08 09:28:12 +0100
commitd63eedc3a3fe078e0aa32ba5a329f10d2e63c18d (patch)
tree9d056dd64c10b1b8e40e79948e841e25f1cae64e
parentb9a49d442bdeeac8cac3bb097f5e224e7623e037 (diff)
downloadrust-libc-d63eedc3a3fe078e0aa32ba5a329f10d2e63c18d.tar.gz
compatibility with rust 1.13.0
-rw-r--r--build.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/build.rs b/build.rs
index 43a5d890d1..e60672a761 100644
--- a/build.rs
+++ b/build.rs
@@ -5,7 +5,7 @@ use std::str;
// List of cfgs this build script is allowed to set. The list is needed to support check-cfg, as we
// need to know all the possible cfgs that this script will set. If you need to set another cfg
// make sure to add it to this list as well.
-const ALLOWED_CFGS: &[&str] = &[
+const ALLOWED_CFGS: &'static [&'static str] = &[
"freebsd10",
"freebsd11",
"freebsd12",
@@ -30,7 +30,7 @@ const ALLOWED_CFGS: &[&str] = &[
];
// Extra values to allow for check-cfg.
-const CHECK_CFG_EXTRA: &[(&str, &[&str])] = &[
+const CHECK_CFG_EXTRA: &'static [(&'static str, &'static [&'static str])] = &[
("target_os", &["switch", "aix", "ohos"]),
("target_env", &["illumos", "wasi", "aix", "ohos"]),
("target_arch", &["loongarch64"]),
@@ -158,7 +158,7 @@ fn main() {
for cfg in ALLOWED_CFGS {
println!("cargo:rustc-check-cfg=values({})", cfg);
}
- for (name, values) in CHECK_CFG_EXTRA {
+ for &(name, values) in CHECK_CFG_EXTRA {
let values = values.join("\",\"");
println!("cargo:rustc-check-cfg=values({},\"{}\")", name, values);
}