Preventing rustup-installed binaries getting busted after garbage collection

I use rustup to manage my rust installation. It works great for me, except that periodically rustup-installed cargo & rustc break when I run garbage collection. Presumably, that’s because the global linker they depend on gets removed.

Is there some way for me to either:

  • Make sure that installed Rust toolchain are considered gc roots by nix?
  • Alternatively, to force re-download (and re-patching) of toolchains during upgrades iff that’s necessary?

Perhaps something like this could be of service?

1 Like

Not really, I do need Rustup in particular, rather than a rustup replacement.