We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 451fea3 commit af7b3f3Copy full SHA for af7b3f3
llama-cpp-sys-2/build.rs
@@ -336,6 +336,16 @@ fn main() {
336
}
337
338
339
+ if matches!(target_os, TargetOs::Linux)
340
+ && target_triple.contains("aarch64")
341
+ && !env::var(format!("CARGO_FEATURE_{}", "native".to_uppercase())).is_ok()
342
+ {
343
+ // If the native feature is not enabled, we take off the native ARM64 support.
344
+ // It is useful in docker environments where the native feature is not enabled.
345
+ config.define("GGML_NATIVE", "OFF");
346
+ config.define("GGML_CPU_ARM_ARCH", "armv8-a");
347
+ }
348
+
349
if cfg!(feature = "vulkan") {
350
config.define("GGML_VULKAN", "ON");
351
match target_os {
0 commit comments