Skip to content

Commit

Permalink
Merge pull request rust-lang#195 from meowtec/feat/improve-fail-hint
Browse files Browse the repository at this point in the history
Improve hint for cmake not installed in Linux (code 127)
  • Loading branch information
tgross35 authored Aug 15, 2024
2 parents f89c724 + cdf638f commit 584e1c1
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1075,6 +1075,12 @@ fn run(cmd: &mut Command, program: &str) {
Err(e) => fail(&format!("failed to execute command: {}", e)),
};
if !status.success() {
if status.code() == Some(127) {
fail(&format!(
"command did not execute successfully, got: {}, is `{}` not installed?",
status, program
));
}
fail(&format!(
"command did not execute successfully, got: {}",
status
Expand Down

0 comments on commit 584e1c1

Please sign in to comment.