Troubleshooting 'proc-macro crate build data is missing dylib path' error

⚓ Rust    📅 2025-06-23    👤 surdeus    👁️ 5      

surdeus

Warning

This post was published 50 days ago. The information described in this article may have changed.

Hello,
I am trying to troubleshoot an error that pops up when trying to use rust-analyzer in VSCode on a project that has a complex build system.
I got pretty far into configuring rust-analyzer for VSCode (and generating configurations). But I'm getting stuck on this error that seems to be related to the defmt crate and its macros:

proc-macro crate build data is missing dylib path

This error diseappiears when I remove ariel-os/defmt from the enabled features in the rust-analyzer config.

I created a repository to recreate the issue here: github.com/nponsard/ariel-os-vscode-config-troubleshooting

Here's how you can replicate the issue:

  • clone the repository
  • open it in VSCode (you can use the devcontainer configuration)
  • install the dependencies ./install-deps.sh
  • restart rust-analyzer
  • open src/main.rs and wait for it to finish scanning the project
  • once rust-analyzer finished scanning, try to jump to the definition of the info!() macro line 8
  • the error should appear and propagate back to main.rs "proc-macro crate build data is missing dylib path"

Do you have any idea how to troubleshoot this further ?

Thanks

2 posts - 2 participants

Read full topic

🏷️ rust_feed