Skip to content

Commit

Permalink
Use cfg_aliases 0.2.1 (#2490)
Browse files Browse the repository at this point in the history
With 0.2.1, there's no need to manually write rustc-check-cfg statements.
  • Loading branch information
asomers authored Sep 9, 2024
1 parent eb3209a commit 277013b
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 9 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down
9 changes: 1 addition & 8 deletions build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -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)");
}

0 comments on commit 277013b

Please sign in to comment.