Skip dsymutil by default for compiler bootstrap
`dsymutil` adds time to builds on Apple platforms for no clear benefit, and also makes it more difficult for debuggers to find debug info. The compiler currently defaults to running `dsymutil` to preserve its historical default, but when compiling the compiler itself, we skip it by default since we know it's safe to do so in that case.
This commit is contained in:
parent
1f5bc176b0
commit
e628fcfcb5
3 changed files with 24 additions and 0 deletions
|
|
@ -1126,6 +1126,19 @@ impl<'a> Builder<'a> {
|
|||
},
|
||||
);
|
||||
|
||||
// `dsymutil` adds time to builds on Apple platforms for no clear benefit, and also makes
|
||||
// it more difficult for debuggers to find debug info. The compiler currently defaults to
|
||||
// running `dsymutil` to preserve its historical default, but when compiling the compiler
|
||||
// itself, we skip it by default since we know it's safe to do so in that case.
|
||||
// See https://github.com/rust-lang/rust/issues/79361 for more info on this flag.
|
||||
if target.contains("apple") {
|
||||
if self.config.rust_run_dsymutil {
|
||||
rustflags.arg("-Zrun-dsymutil=yes");
|
||||
} else {
|
||||
rustflags.arg("-Zrun-dsymutil=no");
|
||||
}
|
||||
}
|
||||
|
||||
if self.config.cmd.bless() {
|
||||
// Bless `expect!` tests.
|
||||
cargo.env("UPDATE_EXPECT", "1");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue