Print linker arguments if calling the linker fails
Needed to diagnose https://github.com/rust-lang/rust/issues/33844 Signed-off-by: Peter Atashian <retep998@gmail.com>
This commit is contained in:
parent
298730e703
commit
d34ad3c3b2
1 changed files with 5 additions and 1 deletions
|
@ -692,7 +692,11 @@ fn link_natively(sess: &Session,
|
|||
info!("linker stdout:\n{}", escape_string(&prog.stdout[..]));
|
||||
},
|
||||
Err(e) => {
|
||||
sess.fatal(&format!("could not exec the linker `{}`: {}", pname, e));
|
||||
// Trying to diagnose https://github.com/rust-lang/rust/issues/33844
|
||||
sess.struct_err(&format!("could not exec the linker `{}`: {}", pname, e))
|
||||
.note(&format!("{:?}", &cmd))
|
||||
.emit();
|
||||
sess.abort_if_errors();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue