Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cargo didn't build a cdylib error on maturin 0.13.4 #1141

Closed
messense opened this issue Sep 27, 2022 Discussed in #1140 · 0 comments · Fixed by #1142
Closed

Cargo didn't build a cdylib error on maturin 0.13.4 #1141

messense opened this issue Sep 27, 2022 Discussed in #1140 · 0 comments · Fixed by #1142
Labels
bug Something isn't working

Comments

@messense
Copy link
Member

Discussed in #1140

Originally posted by km19809 September 27, 2022
After the build command, maturin fails with a message: Cargo didn't build a cdylib. Did you miss crate-type = ["cdylib"] in the lib section of your Cargo.toml?
However, the crate was compiled successfully.
Also, there is crate-type = ["cdylib"] in the lib section. here.

What happened to me?
How can I solve this problem?

The last 4 lines of the message:

   Compiling unindent v0.1.10
    Finished release [optimized] target(s) in 1m 12s
💥 maturin failed
  Caused by: Cargo didn't build a cdylib. Did you miss crate-type = ["cdylib"] in the lib section of your Cargo.toml?

Environments
Rust: 1.64.0
Rust-nightly: 1.66.0-nightly (8b705839c 2022-09-26)
Host: x86_64-unknown-linux-gnu

Maturin: 0.13.4

How to reproduce

  1. Clone a repository.
    git clone https://github.com/km19809/pyxel
  2. Build with maturin.
    RUSTUP_TOOLCHAIN=nightly maturin build -o dist --release --target wasm32-unknown-emscripten -- -Clink-arg=-sUSE_SDL=2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant