You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Allow users to specify multiple targets, such as both x86_64-unknown-linux-gnu and x86_64-unknown-linux-musl, so that cargo build produces both artifacts.
By the way, how will the filename paths differentiate between multiple targets? Gox allows the target metadata to appear in the destination filepath, for example.
Reacted by Mino, Henrik Laxhuber, Davi Silva , Dmitry Demin, Andy Fleming, repi, Mitchell Skaggs, insomnyawolf, Tianyi Shi and Squirrel
Sounds like a reasonable feature to implement to me! I think the backend of Cargo isn't quite read to do this kind of operation, but with a small amount of refactoring it should be able to, namely parameterizing Kind to have more than one kind of Target.
Kind was moved here. Host is used for proc-macros, plugins, and build scripts which must be compiled for the host architecture. Target is used when the user specifies --target.
Activity
alexcrichton commentedon Apr 10, 2017
Sounds like a reasonable feature to implement to me! I think the backend of Cargo isn't quite read to do this kind of operation, but with a small amount of refactoring it should be able to, namely parameterizing
Kindto have more than one kind ofTarget.steveklabnik commentedon Nov 30, 2017
I'm hitting this today; I am writing a client and server both in wasm. Client crate needs to be compiled with one target, the server with another.
michaeleiselsc commentedon Mar 20, 2018
if we did this, would it be possible to generate the IR only once but build for multiple backends?
sfackler commentedon Mar 20, 2018
dwijnand commentedon Nov 26, 2018
What does
cargo::ops::cargo_rustc::Kinddenote?ehuss commentedon Nov 26, 2018
Kindwas moved here.Hostis used for proc-macros, plugins, and build scripts which must be compiled for the host architecture.Targetis used when the user specifies--target.ehuss commentedon Apr 29, 2020
Closing in favor of tracking issue #8176.