-
Notifications
You must be signed in to change notification settings - Fork 12.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
compilation failure with "cargo check --tests" for espidf #125714
Comments
First of a short general remark, while we can push for making it possible to build crossplatform test this way they will never be runnable. For us the way forward is to build tests and use an external test harness, in the concrete case we are using the embedded-test crate for such adventures. A current workaround to don't have rust-analyzer go insane on trying to build that tests the normal way is: For your example project you would add a section like this [[bin]]
name = "your project name"
harness = false That said this answer is only trying to answer to the underlying issue of building test against espidf as a crossplatform target and |
Running
cargo check --tests
fails to compiletest
for the esp-idf-template (tested on mcu esp32-c3, default template options).rust-lang/libc#3658 introduced these constants for espidf, where previously the error was a missing constant altogether (rust-lang/rust-analyzer#16552).
Steps to Reproduce
cargo generate esp-rs/esp-idf-template cargo
cd <project name> && cargo check --tests
Meta
rustc --version --verbose
:The text was updated successfully, but these errors were encountered: