summaryrefslogtreecommitdiffstats
path: root/vendor/ahash/build.rs
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 12:19:13 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-17 12:19:13 +0000
commit218caa410aa38c29984be31a5229b9fa717560ee (patch)
treec54bd55eeb6e4c508940a30e94c0032fbd45d677 /vendor/ahash/build.rs
parentReleasing progress-linux version 1.67.1+dfsg1-1~progress7.99u1. (diff)
downloadrustc-218caa410aa38c29984be31a5229b9fa717560ee.tar.xz
rustc-218caa410aa38c29984be31a5229b9fa717560ee.zip
Merging upstream version 1.68.2+dfsg1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'vendor/ahash/build.rs')
-rw-r--r--vendor/ahash/build.rs30
1 files changed, 4 insertions, 26 deletions
diff --git a/vendor/ahash/build.rs b/vendor/ahash/build.rs
index 8be4964e5..0c5b76929 100644
--- a/vendor/ahash/build.rs
+++ b/vendor/ahash/build.rs
@@ -4,32 +4,11 @@ use std::env;
fn main() {
println!("cargo:rerun-if-changed=build.rs");
- if let Some(channel) = version_check::Channel::read() {
- if channel.supports_features() {
- println!("cargo:rustc-cfg=feature=\"specialize\"");
- println!("cargo:rustc-cfg=feature=\"stdsimd\"");
- }
+ if let Some(true) = version_check::supports_feature("specialize") {
+ println!("cargo:rustc-cfg=feature=\"specialize\"");
}
- let os = env::var("CARGO_CFG_TARGET_OS").expect("CARGO_CFG_TARGET_OS was not set");
- if os.eq_ignore_ascii_case("linux")
- || os.eq_ignore_ascii_case("android")
- || os.eq_ignore_ascii_case("windows")
- || os.eq_ignore_ascii_case("macos")
- || os.eq_ignore_ascii_case("ios")
- || os.eq_ignore_ascii_case("freebsd")
- || os.eq_ignore_ascii_case("openbsd")
- || os.eq_ignore_ascii_case("dragonfly")
- || os.eq_ignore_ascii_case("solaris")
- || os.eq_ignore_ascii_case("illumos")
- || os.eq_ignore_ascii_case("fuchsia")
- || os.eq_ignore_ascii_case("redox")
- || os.eq_ignore_ascii_case("cloudabi")
- || os.eq_ignore_ascii_case("haiku")
- || os.eq_ignore_ascii_case("vxworks")
- || os.eq_ignore_ascii_case("emscripten")
- || os.eq_ignore_ascii_case("wasi")
- {
- println!("cargo:rustc-cfg=feature=\"runtime-rng\"");
+ if let Some(true) = version_check::supports_feature("stdsimd") {
+ println!("cargo:rustc-cfg=feature=\"stdsimd\"");
}
let arch = env::var("CARGO_CFG_TARGET_ARCH").expect("CARGO_CFG_TARGET_ARCH was not set");
if arch.eq_ignore_ascii_case("x86_64")
@@ -41,5 +20,4 @@ fn main() {
{
println!("cargo:rustc-cfg=feature=\"folded_multiply\"");
}
-
}