From 063f60ab8f917d926fad6e82cb29ee1308c3ae39 Mon Sep 17 00:00:00 2001 From: Debian Rust Maintainers Date: Tue, 28 May 2024 17:06:58 +0200 Subject: [PATCH] d-armel-fix-lldb run panics if lldb is not installed and no output is produced.. Gbp-Pq: Name d-armel-fix-lldb.patch --- src/bootstrap/test.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/bootstrap/test.rs b/src/bootstrap/test.rs index 3c4c4e3af0..708af3a7a6 100644 --- a/src/bootstrap/test.rs +++ b/src/bootstrap/test.rs @@ -1648,7 +1648,11 @@ note: if you're sure you want to do this, please open an issue as to why. In the .ok(); if let Some(ref vers) = lldb_version { cmd.arg("--lldb-version").arg(vers); - let lldb_python_dir = run(Command::new(lldb_exe).arg("-P")).ok(); + let lldb_python_dir = Command::new(lldb_exe) + .arg("-P") + .output() + .map(|output| String::from_utf8_lossy(&output.stdout).to_string()) + .ok(); if let Some(ref dir) = lldb_python_dir { cmd.arg("--lldb-python-dir").arg(dir); } -- 2.30.2