-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCargo.toml
More file actions
107 lines (91 loc) · 3.26 KB
/
Cargo.toml
File metadata and controls
107 lines (91 loc) · 3.26 KB
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
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
[package]
name = "codemp"
description = "codemp -- code multiplexer"
homepage = "https://code.mp"
repository = "https://github.com/hexedtech/codemp"
authors = [
"alemi <me@alemi.dev>",
"zaaarf <me@zaaarf.foo>",
"frelodev <frelodev@gmail.com>",
"cschen <dev@cschen.cc>"
]
license = "GPL-3.0-only"
edition = "2024"
version = "0.8.5"
exclude = ["dist/*"]
[lints]
rust.unsafe_code = "warn"
rust.missing_docs = "warn"
clippy.unwrap_used = "warn"
clippy.collapsible_if = "allow"
[lib]
name = "codemp"
crate-type = ["cdylib", "rlib"]
[dependencies]
# core
tracing = "0.1"
thiserror = "2.0"
# crdt
diamond-types = "1.0"
# proto
codemp-proto = { git = "https://github.com/hexedtech/codemp-proto", rev = "6b45fd7bd7c03ef60234880c59157481def4ca71", features = ["client"] }
uuid = { version = "1.17", features = ["v4"] }
tonic = { version = "0.14", features = ["tls-native-roots"] }
# api
tokio = { version = "1.47", features = ["macros", "rt-multi-thread", "sync"] }
xxhash-rust = { version = "0.8", features = ["xxh3"] }
# client
tokio-stream = "0.1"
dashmap = "6.1"
# glue (multiple)
tracing-subscriber = { version = "0.3", optional = true }
# glue (java)
jni = { version = "0.22", features = ["invocation"], optional = true }
#jni-toolbox = { version = "0.2", optional = true, features = ["uuid"] }
jni-toolbox = { git = "https://github.com/hexedtech/jni-toolbox", rev = "9b54289d562f3ba0dfc59ab38342e7502aeb529c", optional = true, features = ["uuid", "unsigned"] }
# glue (lua)
mlua = { version = "0.11", features = ["module", "serialize", "error-send"], optional = true }
mlua-serde-derive = { version = "0.1.1", optional = true }
# glue (js)
napi = { version = "3.1", features = ["full"], optional = true }
napi-derive = { version="3.1", optional = true}
# glue (python)
pyo3 = { version = "0.28", features = ["multiple-pymethods", "experimental-inspect"], optional = true}
# extra
async-trait = { version = "0.1", optional = true }
serde = { version = "1.0", features = ["derive"], optional = true }
syn = { version = "2.0", features = ["full"], optional = true }
regex = { version = "1.12", optional = true }
[build-dependencies]
# glue (js)
napi-build = { version = "2.2", optional = true }
# glue (python)
pyo3-build-config = { version = "0.28", optional = true }
pyo3-introspection = { version = "0.28", optional = true }
[features]
default = ["lua-jit", "py-abi3", "py-extmod"]
# extra
async-trait = ["dep:async-trait"]
serialize = ["dep:serde", "uuid/serde"]
# special tests which require more setup
test-e2e = []
test-coverage = ["dep:syn", "dep:regex"]
# ffi
java = ["dep:jni", "dep:tracing-subscriber", "dep:jni-toolbox", "codemp-proto/java"]
js = ["dep:napi-build", "dep:tracing-subscriber", "dep:napi", "dep:napi-derive", "codemp-proto/js"]
py = ["dep:pyo3", "dep:tracing-subscriber", "dep:pyo3-build-config", "dep:pyo3-introspection", "codemp-proto/py"]
lua = ["serialize", "dep:mlua", "dep:mlua-serde-derive", "dep:tracing-subscriber", "codemp-proto/lua"]
# ffi variants
lua-jit = ["mlua?/luajit"]
lua-54 = ["mlua?/lua54"]
py-abi3 = ["pyo3?/abi3-py38"]
py-extmod = ["pyo3?/extension-module"]
# enables ci-specific stuff
ci = []
[package.metadata.docs.rs] # enabled features when building on docs.rs
features = ["serialize"]
[profile.release]
opt-level = 'z'
lto = true
codegen-units = 1
strip = 'symbols'