Skip to content

Commit 798cece

Browse files
authored
feat(wasm): Add lib to matrix-sdk-ffi target (#5242)
The uniffi tool for generating JS/Wasm bindings utilizes rust as its intermediate language. As a result, the 'target' uniffi annotated library needs to be marked as a 'lib' so that the generated rust code can utilize it to generate the Wasm create + typescript bindings. Signed-off-by: Daniel Salinas
1 parent 06b3871 commit 798cece

File tree

1 file changed

+8
-1
lines changed

1 file changed

+8
-1
lines changed

bindings/matrix-sdk-ffi/Cargo.toml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,14 @@ publish = false
1414
release = true
1515

1616
[lib]
17-
crate-type = ["cdylib", "staticlib"]
17+
crate-type = [
18+
# Needed by uniffi for Android bindings
19+
"cdylib",
20+
# Needed by uniffi for iOS bindings
21+
"staticlib",
22+
# Needed by uniffi for JS/Wasm bindings, which use rust as an intermediate language
23+
"lib"
24+
]
1825

1926
[features]
2027
default = ["bundled-sqlite", "unstable-msc4274"]

0 commit comments

Comments
 (0)