Use rustc-check-cfg (#3682)

This commit is contained in:
Mads Marquart 2024-05-06 07:11:57 +02:00 committed by GitHub
parent 7f8771a362
commit 16fd2baba0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 22 additions and 4 deletions

View file

@ -21,4 +21,19 @@ fn main() {
wayland_platform: { all(feature = "wayland", free_unix, not(redox)) },
orbital_platform: { redox },
}
println!("cargo:rustc-check-cfg=cfg(android_platform)");
println!("cargo:rustc-check-cfg=cfg(web_platform)");
println!("cargo:rustc-check-cfg=cfg(macos_platform)");
println!("cargo:rustc-check-cfg=cfg(ios_platform)");
println!("cargo:rustc-check-cfg=cfg(windows_platform)");
println!("cargo:rustc-check-cfg=cfg(apple)");
println!("cargo:rustc-check-cfg=cfg(free_unix)");
println!("cargo:rustc-check-cfg=cfg(redox)");
println!("cargo:rustc-check-cfg=cfg(x11_platform)");
println!("cargo:rustc-check-cfg=cfg(wayland_platform)");
println!("cargo:rustc-check-cfg=cfg(orbital_platform)");
println!("cargo:rustc-check-cfg=cfg(unreleased_changelogs)");
}