This might also help you: https://users.rust-lang.org/t/cargo-build-dependencies-in-release-current-crate-in-debug
Edit: Just noticed the thread is quite old, the official docs are now at Profiles - The Cargo Book
This might also help you: https://users.rust-lang.org/t/cargo-build-dependencies-in-release-current-crate-in-debug
Edit: Just noticed the thread is quite old, the official docs are now at Profiles - The Cargo Book