cargo install is specifically for installing binaries, not arbitrary crates, and from the way you framed the question it seems like you want the latter. Apologies if I got that wrong!
If you want to add a library as a dependency, you do this via Cargo.toml's, [dependenceis] section:
[dependencies]
foo = "x.x.x"
To answer the original question, to my knowledge, it is not possible to specify multiple crates with --version for cargo install.
Yes, I am sure. I am building a Docker image which should not upgrade executable dependencies while building. To set a specific version for each dependency in Dockerfile is a good practice.
To answer the original question, to my knowledge, it is not possible to specify multiple crates with --version for cargo install.