Skip to content
Discussion options

You must be logged in to vote

Your result makes sense with current maturin, but I would still keep cdylib in the manifest.

It is not that maturin never cares. The current build path can recover when the Cargo target is a normal Rust library: if no cdylib target is declared, maturin looks for a lib-like target and, on Rust 1.64 or newer, invokes Cargo with --crate-type cdylib. That explains why maturin develop still worked in your test.

The manifest default is still useful because it makes the crate's intent explicit to Cargo and to tools that are not maturin. A plain cargo build will not otherwise produce the Python-loadable dynamic library artifact. Maturin's own packaging path also still expects to collect a cdylib

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@elisw93
Comment options

Answer selected by elisw93
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants