sequoia_port/security/sequoia/files/patch-ffi_tests_c-tests.rs

21 lines
830 B
Rust

--- ffi/tests/c-tests.rs.orig 2021-06-19 18:51:23 UTC
+++ ffi/tests/c-tests.rs
@@ -224,10 +224,16 @@ fn build(include_dirs: &[PathBuf], ldpath: &Path, targ
filetime::set_file_times(target_c, mtime, mtime).unwrap();
}
+ let make_executable;
+ if cfg!(target_os = "freebsd") || cfg!(target_os = "macos"){
+ make_executable = "gmake";
+ } else {
+ make_executable = "make";
+ }
let includes =
include_dirs.iter().map(|dir| format!("-I{:?}", dir))
.collect::<Vec<String>>().join(" ");
- let st = Command::new("make")
+ let st = Command::new(make_executable)
.env("CFLAGS", &format!("-Wall -O0 -ggdb {} {}", includes,
env::var("CFLAGS").unwrap_or_else(|_| "".into())))
.env("LDFLAGS", &format!("-L{:?}", ldpath))