fix: Correct broken hipblas build

This commit is contained in:
Nathan Smyth 2025-04-30 22:21:12 +10:00
parent ddbc7961c5
commit 76facb3b63

View file

@ -178,7 +178,7 @@ fn main() {
} }
if cfg!(feature = "hipblas") { if cfg!(feature = "hipblas") {
config.define("GGML_HIPBLAS", "ON"); config.define("GGML_HIP", "ON");
config.define("CMAKE_C_COMPILER", "hipcc"); config.define("CMAKE_C_COMPILER", "hipcc");
config.define("CMAKE_CXX_COMPILER", "hipcc"); config.define("CMAKE_CXX_COMPILER", "hipcc");
println!("cargo:rerun-if-env-changed=AMDGPU_TARGETS"); println!("cargo:rerun-if-env-changed=AMDGPU_TARGETS");
@ -272,6 +272,10 @@ fn main() {
println!("cargo:rustc-link-lib=static=ggml-vulkan"); println!("cargo:rustc-link-lib=static=ggml-vulkan");
} }
if cfg!(feature = "hipblas") {
println!("cargo:rustc-link-lib=static=ggml-hip");
}
if cfg!(feature = "metal") { if cfg!(feature = "metal") {
println!("cargo:rustc-link-lib=static=ggml-metal"); println!("cargo:rustc-link-lib=static=ggml-metal");
} }