diff options
| author | Lexi Winter <ivy@FreeBSD.org> | 2025-10-05 09:19:31 +0100 |
|---|---|---|
| committer | Lexi Winter <ivy@FreeBSD.org> | 2025-10-05 09:19:31 +0100 |
| commit | f85f2b2d6e5b7ed869376eb4b180c3a74a5c5da9 (patch) | |
| tree | ad799ccacfb459b809b02b9c115ed4befb93b4c1 /misc/shimmy/files/llama-cpp-rs | |
| parent | 0b1510fe1f98f82da6f3481cb6c58957022d9211 (diff) | |
| parent | b057c68280a2f2a7b3d1fbac36f7b034e1fdf593 (diff) | |
Merge remote-tracking branch 'freebsd/main' into lf/main
Diffstat (limited to 'misc/shimmy/files/llama-cpp-rs')
| -rw-r--r-- | misc/shimmy/files/llama-cpp-rs/patch-llama-cpp-sys-2_build.rs | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/misc/shimmy/files/llama-cpp-rs/patch-llama-cpp-sys-2_build.rs b/misc/shimmy/files/llama-cpp-rs/patch-llama-cpp-sys-2_build.rs new file mode 100644 index 000000000000..de8f6436d05a --- /dev/null +++ b/misc/shimmy/files/llama-cpp-rs/patch-llama-cpp-sys-2_build.rs @@ -0,0 +1,38 @@ +--- llama-cpp-sys-2/build.rs.orig 2025-09-12 14:16:40 UTC ++++ llama-cpp-sys-2/build.rs +@@ -20,6 +20,7 @@ enum TargetOs { + Apple(AppleVariant), + Linux, + Android, ++ FreeBSD, + } + + macro_rules! debug_log { +@@ -55,6 +56,8 @@ fn parse_target_os() -> Result<(TargetOs, String), Str + Ok((TargetOs::Android, target)) + } else if target.contains("linux") { + Ok((TargetOs::Linux, target)) ++ } else if target.contains("freebsd") { ++ Ok((TargetOs::FreeBSD, target)) + } else { + Err(target) + } +@@ -632,7 +635,7 @@ fn main() { + config.cflag("/FS"); + config.cxxflag("/FS"); + } +- TargetOs::Linux => { ++ TargetOs::Linux | TargetOs::FreeBSD => { + println!("cargo:rustc-link-lib=vulkan"); + } + _ => (), +@@ -738,6 +741,9 @@ fn main() { + } + TargetOs::Linux => { + println!("cargo:rustc-link-lib=dylib=stdc++"); ++ } ++ TargetOs::FreeBSD => { ++ println!("cargo:rustc-link-lib=dylib=c++"); + } + TargetOs::Apple(variant) => { + println!("cargo:rustc-link-lib=framework=Foundation"); |
