link cuda when cuda feature is on

This commit is contained in:
hyiip 2025-02-19 02:55:46 +08:00
parent 3c20758cce
commit 3d33a73458

View file

@ -266,6 +266,10 @@ fn main() {
println!("cargo:rustc-link-lib=static=ggml-metal"); println!("cargo:rustc-link-lib=static=ggml-metal");
} }
if cfg!(feature = "cuda") {
println!("cargo:rustc-link-lib=static=ggml-cuda");
}
println!( println!(
"cargo:WHISPER_CPP_VERSION={}", "cargo:WHISPER_CPP_VERSION={}",
get_whisper_cpp_version(&whisper_root) get_whisper_cpp_version(&whisper_root)