-
Notifications
You must be signed in to change notification settings - Fork 2.8k
Open
Labels
A-crate-typesArea: crate-type declaration (lib, staticlib, dylib, cdylib, etc.)Area: crate-type declaration (lib, staticlib, dylib, cdylib, etc.)C-feature-requestCategory: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted`Category: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted`S-needs-designStatus: Needs someone to work further on the design for the feature or fix. NOT YET accepted.Status: Needs someone to work further on the design for the feature or fix. NOT YET accepted.
Description
Cargo currently enforces only one library crate per package which makes total sense for Rust libraries. However it doesn't make much sense for cdylibs or staticlibs which are not going to be consumed by downstream Rust dependencies. Requiring that only the library crate can be a cdylib or staticlib, and not binary crates, sometimes forces people into mixing lib and cdylib or staticlib and Rust currently produces suboptimal results when doing so. It also means people cannot produce multiple cdylibs or staticlibs from a single package.
I'd like to propose extending [[bin]] to allowcdylib and staticlib for the crate-type.
Shoeboxam, krolli, joshtriplett, stanislav-tkach, tobywf and 17 moreEvrey, guilhermewerner, jmjoy and EriKWDev
Metadata
Metadata
Assignees
Labels
A-crate-typesArea: crate-type declaration (lib, staticlib, dylib, cdylib, etc.)Area: crate-type declaration (lib, staticlib, dylib, cdylib, etc.)C-feature-requestCategory: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted`Category: proposal for a feature. Before PR, ping rust-lang/cargo if this is not `Feature accepted`S-needs-designStatus: Needs someone to work further on the design for the feature or fix. NOT YET accepted.Status: Needs someone to work further on the design for the feature or fix. NOT YET accepted.