diff --git a/crates/matrix-sdk-crypto/Cargo.toml b/crates/matrix-sdk-crypto/Cargo.toml index 3635ba628..5e31b4945 100644 --- a/crates/matrix-sdk-crypto/Cargo.toml +++ b/crates/matrix-sdk-crypto/Cargo.toml @@ -15,6 +15,9 @@ version = "0.4.1" features = ["docsrs"] rustdoc-args = ["--cfg", "docsrs"] +[lib] +crate-type = ["cdylib"] + [features] default = [] qrcode = ["matrix-qrcode"] diff --git a/crates/matrix-sdk-crypto/src/lib.rs b/crates/matrix-sdk-crypto/src/lib.rs index d98dfd56b..2f58f8418 100644 --- a/crates/matrix-sdk-crypto/src/lib.rs +++ b/crates/matrix-sdk-crypto/src/lib.rs @@ -15,8 +15,7 @@ #![doc = include_str!("../README.md")] #![cfg_attr(docsrs, feature(doc_auto_cfg))] #![warn(missing_docs, missing_debug_implementations)] - -#[cfg(all(feature = "js", not(target_arch = "wasm32")))] +#![cfg(all(feature = "js", not(target_arch = "wasm32")))] compile_error!( "The `js` feature must be enabled only for the `wasm32` target (either `wasm32-unknown-unknown` or `wasm32-wasi`)." );