Use arm-none-eabi-objcopy instead of llvm-objcopy #95

Open
atse wants to merge 1 commits from atse/thermostat:workaround-llvm-bug into master

1 Commits (master)

Author SHA1 Message Date
atse 8c8ac71a6f Use arm-none-eabi-objcopy instead of llvm-objcopy
Since LLVM v15, llvm-objcopy seems to produce broken (misaligned?)
binaries, which when combined with some difficult to debug timing issues
caused by the calibrate_dac_feedback routine, would cause the
independent watchdog to kick in, and bootloop the Thermostat.

As NixOS 23.11 ships LLVM v16, upgrading to it breaks builds. Using
rust-objcopy from cargo-binutils does not help either since the pinned
version of Rust uses LLVM v15.

arm-none-eabi-objcopy doesn't have this problem, so use it instead.

See https://github.com/llvm/llvm-project/issues/58407 and
https://github.com/rust-lang/rust/issues/102983.
2024-01-24 10:52:00 +08:00