From a9fd9de3ef4c66b8394f563171941a0f7529fe4f Mon Sep 17 00:00:00 2001 From: Alan Somers Date: Sun, 8 Sep 2024 08:44:16 -0600 Subject: [PATCH] Use cfg_aliases 0.2.1 With 0.2.1, there's no need to manually write rustc-check-cfg statements. --- Cargo.toml | 2 +- build.rs | 9 +-------- 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index e9398f5f24..3166649ee7 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -85,7 +85,7 @@ caps = "0.5.3" sysctl = "0.4" [build-dependencies] -cfg_aliases = "0.2" +cfg_aliases = "0.2.1" [[test]] name = "test" diff --git a/build.rs b/build.rs index 226a32cccb..6586cee48e 100644 --- a/build.rs +++ b/build.rs @@ -27,14 +27,7 @@ fn main() { solarish: { any(illumos, solaris) }, } - // Below are Nix's custom cfg values that we need to let the compiler know - println!("cargo:rustc-check-cfg=cfg(apple_targets)"); - println!("cargo:rustc-check-cfg=cfg(bsd)"); - println!("cargo:rustc-check-cfg=cfg(bsd_without_apple)"); - println!("cargo:rustc-check-cfg=cfg(linux_android)"); - println!("cargo:rustc-check-cfg=cfg(freebsdlike)"); - println!("cargo:rustc-check-cfg=cfg(netbsdlike)"); - println!("cargo:rustc-check-cfg=cfg(solarish)"); + // Below are custom cfg values set during some CI steps. println!("cargo:rustc-check-cfg=cfg(fbsd14)"); println!("cargo:rustc-check-cfg=cfg(qemu)"); }