Top "Rust-cargo" questions

Cargo is the official package manager for the Rust programming language.

How do I use conditional compilation with `cfg` and Cargo?

I want to conditionally compile my source code using cfg with Cargo, after Googling for a while, it seems that …

rust rust-cargo
How can a Rust program access metadata from its Cargo package?

How do you access a Cargo package's metadata (e.g. version) from the Rust code in the package? In my …

rust rust-cargo
error[E0554]: #![feature] may not be used on the stable release channel Couldn't install racer using cargo

I'm trying to install racer using cargo, so I executed the command cargo install racer in the terminal and it …

rust rust-cargo
How to get assembly output from building with Cargo?

While I've seen docs on using rustc directly to output assembly, having to manually extract commands used by Cargo and …

assembly rust rust-cargo
How to clear the Cargo cache?

When I run cargo build, various libs get stored within the folder /usr/local/lib/rustlib/. What is the correct …

rust rust-crates rust-cargo
Error installing a crate via cargo: specified package has no binaries

I'm trying to install a Rust crate on my system (Arch Linux) using Cargo. I can search for crates and …

installation rust rust-cargo rust-crates
Does cargo install have an equivalent update command?

I'd like to update a package that I used cargo install to globally install packages, such as rustfmt or racer. …

rust rust-cargo
How do I specify the linker path in Rust?

I'm trying to link a Rust program with libsoundio. I'm using Windows and there's a GCC binary download available. I …

rust static-linking dynamic-linking rust-cargo
How to pass rustc flags to cargo?

I am trying to disable dead code warnings. I tried the following cargo build -- -A dead_code ➜ rla git:(…

rust rust-cargo
How can I set default build target for Cargo?

I tried to make 'Hello World' in Rust using this tutorial, but the build command is a bit verbose: cargo +…

rust rust-cargo