atagen

matrix-rust-sdk

public
Star0
Watch0
ssh://brewery@pls.lobotomise.me:33/atagen/matrix-rust-sdk.git
Cargo.tomlToml241 lines11.5 KB
1
[workspace]
2
members = [
3
    "benchmarks",
4
    "bindings/matrix-sdk-crypto-ffi",
5
    "bindings/matrix-sdk-ffi",
6
    "crates/*",
7
    "examples/*",
8
    "labs/*",
9
    "testing/*",
10
    "uniffi-bindgen",
11
    "xtask",
12
]
13
exclude = ["testing/data"]
14
# xtask, multiverse, testing and the bindings should only be built when invoked explicitly.
15
default-members = ["benchmarks", "crates/*"]
16
resolver = "3"
17
18
[workspace.package]
19
rust-version = "1.93"
20
21
[workspace.dependencies]
22
anyhow = { version = "1.0.100", default-features = false }
23
aquamarine = { version = "0.6.0", default-features = false }
24
as_variant = { version = "1.3.0", default-features = false }
25
assert-json-diff = { version = "2.0.2", default-features = false }
26
assert_matches = { version = "1.5.0", default-features = false }
27
assert_matches2 = { version = "0.1.2", default-features = false }
28
async_cell = { version = "0.2.3", default-features = false }
29
async-compat = { version = "0.2.5", default-features = false }
30
async-once-cell = { version = "0.5.4", default-features = false }
31
async-rx = { version = "0.2.0", default-features = false }
32
# Bumping this to 0.3.6 produces a test failure because the semantic between the
33
# versions changed subtly: https://github.com/matrix-org/matrix-rust-sdk/issues/4599
34
async-stream = { version = "0.3.6", default-features = false }
35
async-trait = { version = "0.1.89", default-features = false }
36
base64 = { version = "0.22.1", default-features = false, features = ["std"] }
37
bitflags = { version = "2.10.0", default-features = false }
38
byteorder = { version = "1.5.0", default-features = false, features = ["std"] }
39
cfg-if = { version = "1.0.4", default-features = false }
40
clap = { version = "4.5.53", default-features = false, features = ["std", "help", "usage"] }
41
chrono = { version = "0.4.42", default-features = false, features = ["clock", "std", "oldtime", "wasmbind"] }
42
dirs = { version = "6.0.0", default-features = false }
43
eyeball = { version = "0.8.8", default-features = false, features = ["tracing"] }
44
eyeball-im = { version = "0.8.0", default-features = false, features = ["tracing"] }
45
eyeball-im-util = { version = "0.10.0", default-features = false }
46
futures-core = { version = "0.3.31", default-features = false, features = ["std"] }
47
futures-executor = { version = "0.3.31", default-features = false, features = ["std"] }
48
futures-util = { version = "0.3.31", default-features = false, features = ["std"] }
49
getrandom = { version = "0.4.2", default-features = false }
50
gloo-timers = { version = "0.3.0", default-features = false }
51
gloo-utils = { version = "0.2.0", default-features = false, features = ["serde"] }
52
growable-bloom-filter = { version = "2.1.1", default-features = false }
53
hkdf = { version = "0.12.4", default-features = false }
54
hmac = { version = "0.12.1", default-features = false }
55
http = { version = "1.3.1", default-features = false }
56
imbl = { version = "6.1.0", default-features = false }
57
indexed_db_futures = { version = "0.7.0", package = "matrix_indexed_db_futures", default-features = false }
58
indexmap = { version = "2.12.1", default-features = false }
59
insta = { version = "1.44.1", features = ["json", "redactions"] }
60
itertools = { version = "0.14.0", default-features = false, features = ["use_std"] }
61
js-sys = { version = "0.3.82", default-features = false, features = ["std"] }
62
mime = { version = "0.3.17", default-features = false }
63
oauth2 = { version = "5.0.0", default-features = false, features = ["timing-resistant-secret-traits"] }
64
oauth2-reqwest = { version = "0.1.0-alpha.3", default-features = false }
65
pbkdf2 = { version = "0.12.2", default-features = false }
66
pin-project-lite = { version = "0.2.16", default-features = false }
67
proc-macro2 = { version = "1.0.106", default-features = false }
68
proptest = { version = "1.9.0", default-features = false, features = ["std"] }
69
quote = { version = "1.0.37", default-features = false }
70
rand = { version = "0.10.1", default-features = false, features = ["std", "std_rng", "thread_rng"] }
71
regex = { version = "1.12.2", default-features = false }
72
reqwest = { version = "0.13.1", default-features = false }
73
rmp-serde = { version = "1.3.0", default-features = false }
74
ruma = { version = "0.16.0", features = [
75
    "client-api-c",
76
    "compat-unset-avatar",
77
    "compat-upload-signatures",
78
    "compat-arbitrary-length-ids",
79
    "compat-tag-info",
80
    "compat-encrypted-stickers",
81
    "compat-lax-room-create-deser",
82
    "compat-lax-room-topic-deser",
83
    "unstable-msc3230",
84
    "unstable-msc3401",
85
    "unstable-msc3417",
86
    "unstable-msc3488",
87
    "unstable-msc3489",
88
    "unstable-msc4075",
89
    "unstable-msc4140",
90
    "unstable-msc4143",
91
    "unstable-msc4171",
92
    "unstable-msc4195",
93
    "unstable-msc4278",
94
    "unstable-msc4286",
95
    "unstable-msc4306",
96
    "unstable-msc4308",
97
    "unstable-msc4310",
98
] }
99
sentry = { version = "0.47.0", default-features = false }
100
sentry-tracing = { version = "0.47.0", default-features = false }
101
serde = { version = "1.0.228", default-features = false, features = ["std", "rc", "derive"] }
102
serde_html_form = { version = "0.4.0", default-features = false }
103
serde_json = { version = "1.0.145", default-features = false, features = ["std"] }
104
sha2 = { version = "0.10.9", default-features = false }
105
similar-asserts = { version = "1.7.0", default-features = false }
106
stream_assert = { version = "0.1.1", default-features = false }
107
syn = { version = "2.0.43", default-features = false, features = ["derive", "parsing", "printing", "clone-impls"] }
108
tempfile = { version = "3.23.0", default-features = false }
109
thiserror = { version = "2.0.17", default-features = false }
110
tokio = { version = "1.48.0", default-features = false, features = ["sync"] }
111
tokio-stream = { version = "0.1.17", default-features = false }
112
tracing = { version = "0.1.41", default-features = false, features = ["std"] }
113
tracing-appender = { version = "0.2.3", default-features = false }
114
tracing-core = { version = "0.1.34", default-features = false }
115
tracing-subscriber = { version = "0.3.20", default-features = false, features = ["std", "smallvec", "fmt"] }
116
unicode-normalization = { version = "0.1.25", default-features = false }
117
unicode-segmentation = { version = "1.12.0", default-features = false }
118
uniffi = { version = "0.31.0", default-features = false, features = ["cargo-metadata"] }
119
uniffi_bindgen = { version = "0.31.0", default-features = false, features = ["cargo-metadata"] }
120
url = { version = "2.5.7", default-features = false }
121
uuid = { version = "1.18.1", default-features = false }
122
vergen-gitcl = { version = "1.0.8", default-features = false }
123
vodozemac = { version = "0.10.0", default-features = false, features = ["libolm-compat", "insecure-pk-encryption", "experimental-session-config"] }
124
wasm-bindgen = { version = "0.2.105", default-features = false }
125
wasm-bindgen-test = { version = "0.3.55", default-features = false, features = ["std"] }
126
web-sys = { version = "0.3.82", default-features = false }
127
wiremock = { version = "0.6.5", default-features = false }
128
zeroize = { version = "1.8.2", default-features = false }
129
130
matrix-sdk = { path = "crates/matrix-sdk", version = "0.18.0", default-features = false }
131
matrix-sdk-base = { path = "crates/matrix-sdk-base", version = "0.18.0" }
132
matrix-sdk-common = { path = "crates/matrix-sdk-common", version = "0.18.0" }
133
matrix-sdk-crypto = { path = "crates/matrix-sdk-crypto", version = "0.18.0" }
134
matrix-sdk-ffi-macros = { path = "bindings/matrix-sdk-ffi-macros", version = "0.7.0" }
135
matrix-sdk-indexeddb = { path = "crates/matrix-sdk-indexeddb", version = "0.18.0", default-features = false }
136
matrix-sdk-qrcode = { path = "crates/matrix-sdk-qrcode", version = "0.18.0" }
137
matrix-sdk-sqlite = { path = "crates/matrix-sdk-sqlite", version = "0.18.0", default-features = false }
138
matrix-sdk-store-encryption = { path = "crates/matrix-sdk-store-encryption", version = "0.18.0" }
139
matrix-sdk-test = { path = "testing/matrix-sdk-test", version = "0.18.0" }
140
matrix-sdk-test-utils = { path = "testing/matrix-sdk-test-utils", version = "0.18.0" }
141
matrix-sdk-ui = { path = "crates/matrix-sdk-ui", version = "0.18.0", default-features = false }
142
matrix-sdk-search = { path = "crates/matrix-sdk-search", version = "0.18.0" }
143
144
[workspace.lints.rust]
145
rust_2018_idioms = "warn"
146
semicolon_in_expressions_from_macros = "warn"
147
unexpected_cfgs = { level = "warn", check-cfg = [
148
    'cfg(tarpaulin_include)', # Used by tarpaulin (code coverage)
149
    'cfg(ruma_unstable_exhaustive_types)', # Used by Ruma's EventContent derive macro
150
] }
151
unused_extern_crates = "warn"
152
unused_import_braces = "warn"
153
unused_qualifications = "warn"
154
trivial_casts = "warn"
155
trivial_numeric_casts = "warn"
156
157
[workspace.lints.clippy]
158
assigning_clones = "allow"
159
box_default = "allow"
160
cloned_instead_of_copied = "warn"
161
dbg_macro = "warn"
162
inefficient_to_string = "warn"
163
macro_use_imports = "warn"
164
manual_let_else = "warn"
165
mut_mut = "warn"
166
needless_borrow = "warn"
167
nonstandard_macro_braces = "warn"
168
redundant_clone = "warn"
169
str_to_string = "warn"
170
todo = "warn"
171
unnecessary_semicolon = "warn"
172
unused_async = "warn"
173
174
# Default development profile; default for most Cargo commands, otherwise
175
# selected with `--debug`
176
[profile.dev]
177
# Saves a lot of disk space. If symbols are needed, use the dbg profile.
178
debug = 0
179
180
# Profile for debug builds with full optimization and minimal debug symbols.
181
# This should be just enough to have proper backtraces, having way smaller binaries
182
# (10% of the size with full debug symbols profile, like `reldbg`).
183
# This profile differs from `reldbg` in not containing the debug symbols needed for
184
# debugging with LLDB/GDB, trading that for binary size, allowing quick iterations
185
# of building the bindings, installing in a real device, testing your changes, repeat.
186
# It's also different from `dev` in having enough debug symbols to display backtraces.
187
[profile.reldev]
188
inherits = "dev"
189
opt-level = 3
190
debug = "line-tables-only"
191
strip = "debuginfo"
192
193
[profile.dev.package]
194
# Optimize quote even in debug mode. Speeds up proc-macros enough to account
195
# for the extra time of optimizing it for a clean build of matrix-sdk-ffi.
196
quote = { opt-level = 2 }
197
sha2 = { opt-level = 2 }
198
# faster runs for insta.rs snapshot testing
199
insta.opt-level = 3
200
similar.opt-level = 3
201
202
# Custom profile with full debugging info, use `--profile dbg` to select
203
[profile.dbg]
204
inherits = "dev"
205
debug = 2
206
207
# Custom profile for use in (debug) builds of the binding crates, use
208
# `--profile reldbg` to select
209
[profile.reldbg]
210
inherits = "dbg"
211
opt-level = 3
212
213
[profile.dist]
214
# Use release profile as a base
215
inherits = "release"
216
# Strip the minimal debug info, while still allowing us to have proper backtraces, but it will affect debuggers
217
strip = "debuginfo"
218
# Use link time optimizations
219
lto = true
220
# Use binary size optimization, since this is intended for distributed copies of the SDK
221
opt-level = "s"
222
223
[profile.profiling]
224
inherits = "release"
225
# LTO is too slow to compile.
226
lto = false
227
# Get symbol names for profiling purposes.
228
debug = true
229
230
[profile.bench]
231
inherits = "release"
232
lto = false
233
234
[patch.crates-io]
235
async-compat = { git = "https://github.com/element-hq/async-compat", rev = "5a27c8b290f1f1dcfc0c4ec22c464e38528aa591" }
236
const_panic = { git = "https://github.com/jplatte/const_panic", rev = "e0b317a9a7bde2d48a7d15b6a60d70e4a41d3b5f" }
237
# Needed to fix rotation log issue on Android (https://github.com/tokio-rs/tracing/issues/2937)
238
tracing = { git = "https://github.com/tokio-rs/tracing.git", rev = "20f5b3d8ba057ca9c4ae00ad30dda3dce8a71c05" }
239
tracing-core = { git = "https://github.com/tokio-rs/tracing.git", rev = "20f5b3d8ba057ca9c4ae00ad30dda3dce8a71c05" }
240
tracing-subscriber = { git = "https://github.com/tokio-rs/tracing.git", rev = "20f5b3d8ba057ca9c4ae00ad30dda3dce8a71c05" }
241
tracing-appender = { git = "https://github.com/tokio-rs/tracing.git", rev = "20f5b3d8ba057ca9c4ae00ad30dda3dce8a71c05" }