Fix build with Mach-O

Signed-off-by: Adrien Gallouët <angt@huggingface.co>
This commit is contained in:
Adrien Gallouët 2025-02-20 13:44:41 +01:00
parent d41183a0b4
commit 6223b6e264
No known key found for this signature in database

View File

@ -25,8 +25,9 @@ fn main() {
for path in &llama.link_paths {
println!("cargo:rustc-link-arg=-Wl,-rpath,{}", path.display());
}
println!("cargo:rustc-link-arg=-Wl,--disable-new-dtags");
if cfg!(target_os = "linux") {
println!("cargo:rustc-link-arg=-Wl,--disable-new-dtags");
}
let bindings = bindgen::Builder::default()
.clang_args(
llama