Remove rustc_cfg dependency
This commit is contained in:
Generated
-30
@@ -132,7 +132,6 @@ dependencies = [
|
||||
"redox-path",
|
||||
"redox_syscall",
|
||||
"rmm",
|
||||
"rustc-cfg",
|
||||
"rustc-demangle",
|
||||
"sbi-rt",
|
||||
"slab",
|
||||
@@ -226,15 +225,6 @@ dependencies = [
|
||||
name = "rmm"
|
||||
version = "0.1.0"
|
||||
|
||||
[[package]]
|
||||
name = "rustc-cfg"
|
||||
version = "0.5.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "9ddf7a5e441e8003a5a88aab97f1c6113043ddde252d789ef9dea3871b78633a"
|
||||
dependencies = [
|
||||
"thiserror",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "rustc-demangle"
|
||||
version = "0.1.26"
|
||||
@@ -341,26 +331,6 @@ dependencies = [
|
||||
"unicode-ident",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "thiserror"
|
||||
version = "1.0.69"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "b6aaf5339b578ea85b50e080feb250a3e8ae8cfcdff9a461c9ec2904bc923f52"
|
||||
dependencies = [
|
||||
"thiserror-impl",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "thiserror-impl"
|
||||
version = "1.0.69"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "4fee6c4efc90059e10f81e6d42c60a18f76588c3d74cb83a0b242a2b6c7504c1"
|
||||
dependencies = [
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
"syn",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "toml"
|
||||
version = "0.8.23"
|
||||
|
||||
@@ -6,7 +6,6 @@ edition = "2024"
|
||||
|
||||
[build-dependencies]
|
||||
cc = "1.0"
|
||||
rustc-cfg = "0.5"
|
||||
toml = "0.8"
|
||||
|
||||
[dependencies]
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
use rustc_cfg::Cfg;
|
||||
use std::{env, path::Path, process::Command};
|
||||
use toml::Table;
|
||||
|
||||
@@ -53,10 +52,9 @@ fn main() {
|
||||
println!("cargo::rustc-check-cfg=cfg(dtb)");
|
||||
|
||||
let out_dir = env::var("OUT_DIR").unwrap();
|
||||
let cfg = Cfg::of(env::var("TARGET").unwrap().as_str()).unwrap();
|
||||
let arch_str = cfg.target_arch.as_str();
|
||||
let arch_str = env::var("CARGO_CFG_TARGET_ARCH").unwrap();
|
||||
|
||||
match arch_str {
|
||||
match &*arch_str {
|
||||
"aarch64" => {
|
||||
println!("cargo::rustc-cfg=dtb");
|
||||
}
|
||||
@@ -96,5 +94,5 @@ fn main() {
|
||||
_ => (),
|
||||
}
|
||||
|
||||
let _ = parse_kconfig(arch_str);
|
||||
let _ = parse_kconfig(&*arch_str);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user