fix: prioritise llvm tools
This commit is contained in:
parent
6e122e7632
commit
f43f21275d
|
|
@ -637,7 +637,7 @@ fn link_in_precompiled_bcm_o(config: &Config) {
|
||||||
fs::copy(bcm_o_src_path, &bcm_o_dst_path).unwrap();
|
fs::copy(bcm_o_src_path, &bcm_o_dst_path).unwrap();
|
||||||
|
|
||||||
// check that fips module is named as expected
|
// check that fips module is named as expected
|
||||||
let ar = &["ar", "llvm-ar"];
|
let ar = &["llvm-ar", "ar"];
|
||||||
let out = run_command(ar, |c| c.arg("t").arg(&libcrypto_path).arg("bcm.o")).unwrap();
|
let out = run_command(ar, |c| c.arg("t").arg(&libcrypto_path).arg("bcm.o")).unwrap();
|
||||||
|
|
||||||
assert_eq!(
|
assert_eq!(
|
||||||
|
|
|
||||||
|
|
@ -61,7 +61,7 @@ pub fn prefix_symbols(config: &Config) {
|
||||||
// Use `nm` to list symbols in these static libraries
|
// Use `nm` to list symbols in these static libraries
|
||||||
let nm: &[PathBuf] = match &*config.target_os {
|
let nm: &[PathBuf] = match &*config.target_os {
|
||||||
"android" => &[android_toolchain(config).join("llvm-nm")],
|
"android" => &[android_toolchain(config).join("llvm-nm")],
|
||||||
_ => &[PathBuf::from("nm"), PathBuf::from("llvm-nm")],
|
_ => &[PathBuf::from("llvm-nm"), PathBuf::from("nm")],
|
||||||
};
|
};
|
||||||
let out = run_command(nm, |c| c.args(&static_libs)).unwrap();
|
let out = run_command(nm, |c| c.args(&static_libs)).unwrap();
|
||||||
let mut redefine_syms: Vec<String> = String::from_utf8_lossy(&out.stdout)
|
let mut redefine_syms: Vec<String> = String::from_utf8_lossy(&out.stdout)
|
||||||
|
|
@ -89,7 +89,7 @@ pub fn prefix_symbols(config: &Config) {
|
||||||
// Use `objcopy` to prefix symbols in these static libraries
|
// Use `objcopy` to prefix symbols in these static libraries
|
||||||
let objcopy: &[PathBuf] = match &*config.target_os {
|
let objcopy: &[PathBuf] = match &*config.target_os {
|
||||||
"android" => &[android_toolchain(config).join("llvm-objcopy")],
|
"android" => &[android_toolchain(config).join("llvm-objcopy")],
|
||||||
_ => &[PathBuf::from("objcopy"), PathBuf::from("llvm-objcopy")],
|
_ => &[PathBuf::from("llvm-objcopy"), PathBuf::from("objcopy")],
|
||||||
};
|
};
|
||||||
for static_lib in &static_libs {
|
for static_lib in &static_libs {
|
||||||
run_command(objcopy, |c| {
|
run_command(objcopy, |c| {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue