Skip to content
This repository was archived by the owner on Apr 28, 2025. It is now read-only.

Commit 9b25dca

Browse files
committed
fixup
1 parent ffe79c2 commit 9b25dca

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

crates/libm-cdylib/src/test_utils.rs

+6
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,12 @@ where
7474
{
7575
let mut cmd = process::Command::new(path);
7676

77+
if cfg!(target_os = "linux") {
78+
let ld_library_path = std::env::var("LD_LIBRARY_PATH").unwrap_or_default();
79+
let ld_library_path = format!("{}:{}", cdylib_dir().display(), ld_library_path);
80+
cmd.env("LD_LIBRARY_PATH", ld_library_path);
81+
}
82+
7783
// Run the binary:
7884
let output = cmd.output().unwrap();
7985
handle_err(&format!("run file: {}", path.display()), &output);

0 commit comments

Comments
 (0)