mirror of
https://github.com/huggingface/text-generation-inference.git
synced 2025-06-19 15:52:08 +00:00
use std::env::const::ARCH
This commit is contained in:
parent
fcbf2fc1ac
commit
69a5804e51
@ -1,4 +1,5 @@
|
||||
use std::env;
|
||||
use std::env::consts::ARCH;
|
||||
use std::path::{absolute, PathBuf};
|
||||
|
||||
use cxx_build::CFG;
|
||||
@ -126,10 +127,7 @@ fn main() {
|
||||
});
|
||||
|
||||
// NCCL is slightly trickier because it might not have a pkgconfig installed
|
||||
let nccl_library_path = NCCL_ROOT_DIR.unwrap_or(&format!(
|
||||
"/usr/local/{}-linux-gnu",
|
||||
env::var("CARGO_CFG_TARGET_ARCH").unwrap()
|
||||
));
|
||||
let nccl_library_path = NCCL_ROOT_DIR.unwrap_or(&format!("/usr/local/{}-linux-gnu", ARCH));
|
||||
println!(r"cargo:rustc-link-search=native={}", nccl_library_path);
|
||||
println!("cargo:rustc-link-lib=dylib=nccl");
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user