atagen

malice

public
Star0
Watch0
ecb8598b38afe9f3ab32530f9a0820c529dcd608
2
ssh://brewery@pls.lobotomise.me:33/atagen/malice.git
crates/malice-worker/Cargo.tomlToml59 lines2.2 KB
1
[package]
2
name = "malice-worker"
3
version = "0.1.0"
4
edition = "2024"
5
publish = false
6
7
# malice-worker's wasm profile needs are workspace-wide settings (debug info off
8
# for dev, panic=abort and LTO for release) that would otherwise leak into
9
# malice-server's native build if this crate stayed in the root workspace, so it
10
# gets its own, like macltok's harness/web.
11
[workspace]
12
13
[lib]
14
crate-type = ["cdylib", "rlib"]
15
16
[target.'cfg(target_family = "wasm")'.dependencies]
17
macltok = { path = "../../vendor/macltok", features = ["indexeddb", "serde", "mirror"] }
18
malice-core = { path = "../malice-core" }
19
ruma = { version = "0.16", default-features = false }
20
futures-util = { version = "0.3", default-features = false, features = ["std"] }
21
futures-channel = "0.3"
22
serde_json = "1"
23
# pinned exactly so flake.nix's wasmBindgenCli, built for this locked version, matches
24
# what wasm-bindgen-test-runner needs at test time
25
wasm-bindgen = "=0.2.128"
26
wasm-bindgen-futures = "=0.4.78"
27
js-sys = "=0.3.105"
28
29
[dev-dependencies]
30
wasm-bindgen-test = "0.3"
31
web-sys = { version = "0.3", features = ["SharedWorkerGlobalScope"] }
32
gloo-timers = { version = "0.3", features = ["futures"] }
33
34
[lints.rust]
35
unsafe_code = "forbid"
36
37
# with debuginfo the test wasm balloons and can OOM the test runner, per macltok's
38
# own harness/web/Cargo.toml
39
[profile.dev]
40
debug = false
41
42
[profile.release]
43
opt-level = "z"
44
lto = true
45
codegen-units = 1
46
panic = "abort"
47
strip = true
48
49
[patch.crates-io]
50
matrix-sdk = { path = "../../../matrix-rust-sdk/crates/matrix-sdk" }
51
matrix-sdk-base = { path = "../../../matrix-rust-sdk/crates/matrix-sdk-base" }
52
matrix-sdk-common = { path = "../../../matrix-rust-sdk/crates/matrix-sdk-common" }
53
matrix-sdk-crypto = { path = "../../../matrix-rust-sdk/crates/matrix-sdk-crypto" }
54
matrix-sdk-indexeddb = { path = "../../../matrix-rust-sdk/crates/matrix-sdk-indexeddb" }
55
matrix-sdk-sqlite = { path = "../../../matrix-rust-sdk/crates/matrix-sdk-sqlite" }
56
matrix-sdk-store-encryption = { path = "../../../matrix-rust-sdk/crates/matrix-sdk-store-encryption" }
57
matrix-sdk-test = { path = "../../../matrix-rust-sdk/testing/matrix-sdk-test" }
58
matrix-sdk-test-macros = { path = "../../../matrix-rust-sdk/testing/matrix-sdk-test-macros" }
59
matrix-sdk-ui = { path = "../../../matrix-rust-sdk/crates/matrix-sdk-ui" }