-
Notifications
You must be signed in to change notification settings - Fork 9
/
Cargo.toml
91 lines (78 loc) · 3.01 KB
/
Cargo.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
[package]
name = "matrix-sdk-crypto-wasm"
description = "Matrix encryption library, for JavaScript"
authors = ["Ivan Enderlin <[email protected]>"]
edition = "2021"
homepage = "https://github.com/matrix-org/matrix-rust-sdk-wasm"
keywords = ["matrix", "chat", "messaging", "ruma", "nio"]
license = "Apache-2.0"
readme = "README.md"
repository = "https://github.com/matrix-org/matrix-rust-sdk-wasm"
rust-version = "1.70"
version = "0.0.0"
publish = false
[package.metadata.docs.rs]
rustdoc-args = ["--cfg", "docsrs"]
################################################################################
#
# Configuration for `wasm-pack`
#
# See https://rustwasm.github.io/docs/wasm-pack/cargo-toml-configuration.html
# for details of what can be set here.
#
################################################################################
[package.metadata.wasm-pack.profile.profiling]
wasm-opt = false
[package.metadata.wasm-pack.profile.profiling.wasm-bindgen]
debug-js-glue = false
demangle-name-section = true
dwarf-debug-info = true
[package.metadata.wasm-pack.profile.release]
# Tell wasm-opt to:
# * `-Oz`: optimise for size
# * `-g`: include the "name" section (which holds the printable names for
# symbols) in the output.
wasm-opt = ['-Oz', '-g']
################################################################################
[profile.release]
# Tell cargo to run `rustc` with `-Oz` - ie, to optimize for size.
# https://doc.rust-lang.org/cargo/reference/profiles.html#opt-level
opt-level = 'z'
# Use a single codegen-unit to enable better optimizations
codegen-units = 1
# Enable fat link time optimization
lto = true
[lib]
crate-type = ["cdylib"]
[features]
default = ["qrcode"]
qrcode = ["matrix-sdk-crypto/qrcode", "dep:matrix-sdk-qrcode"]
[dependencies]
anyhow = "1.0.68"
console_error_panic_hook = "0.1.7"
futures-util = "0.3.27"
http = "1.1.0"
js-sys = "0.3.49"
matrix-sdk-common = { git = "https://github.com/matrix-org/matrix-rust-sdk", features = ["js"] }
matrix-sdk-indexeddb = { git = "https://github.com/matrix-org/matrix-rust-sdk", default-features = false, features = ["e2e-encryption"] }
matrix-sdk-qrcode = { git = "https://github.com/matrix-org/matrix-rust-sdk", optional = true }
serde = "1.0.91"
serde_json = "1.0.91"
serde-wasm-bindgen = "0.5.0"
tracing = { version = "0.1.36", default-features = false, features = ["std"] }
tracing-subscriber = { version = "0.3.14", default-features = false, features = ["registry", "std", "ansi"] }
url = "2.5.0"
wasm-bindgen = "0.2.89"
wasm-bindgen-futures = "0.4.33"
zeroize = "1.6.0"
wasm-bindgen-test = "0.3.37"
[build-dependencies]
vergen = { version = "8.0.0", features = ["build", "git", "gitcl"] }
[dependencies.matrix-sdk-crypto]
git = "https://github.com/matrix-org/matrix-rust-sdk"
default_features = false
features = ["js", "automatic-room-key-forwarding"]
[lints.rust]
# Workaround for https://github.com/rustwasm/wasm-bindgen/issues/4283, while we work up the courage to upgrade
# wasm-bindgen
unexpected_cfgs = { level = "warn", check-cfg = ['cfg(wasm_bindgen_unstable_test_coverage)'] }