addr2line icon indicating copy to clipboard operation
addr2line copied to clipboard

Tests are failing with nightly rust due to packed debuginfo

Open philipc opened this issue 3 years ago • 3 comments

Currently the tests require Linux builds to use split-debuginfo=off and macOS builds to use split-debuginfo=packed. On stable rust, we achieve this with split-debuginfo=packed in Cargo.toml. This works because this option is only supported for macOS. However, nightly rust has stabilized this option for Linux as well, and so now CI is failing.

I can't see how to specify platform specific options in profiles. For example, I would expect something like this to work, but it doesn't:

[target.'cfg(macos)'.profile.test]
split-debuginfo = 'packed'

@davidtwco Do you know how to achieve this? Is it intended that all platforms must use the same split-debuginfo settings?

philipc avatar Sep 13 '22 07:09 philipc

macOS defaults to packed for back compat reasons, so not setting split-debuginfo at all should work.

bjorn3 avatar Sep 13 '22 08:09 bjorn3

Hmm, can't test that now, but the reason I had this in the first place is because it was defaulting to unpacked.

philipc avatar Sep 13 '22 08:09 philipc

Right, cargo changed the default in https://github.com/rust-lang/cargo/pull/9298. My bad.

bjorn3 avatar Sep 13 '22 09:09 bjorn3

The relevant cargo issue is https://github.com/rust-lang/cargo/issues/4897

We can use environment variables to work around this in CI, but the cargo setting would still be preferred.

philipc avatar Nov 03 '22 06:11 philipc