-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathCargo.toml
59 lines (50 loc) · 1.49 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
[package]
name = "rust-device-detector"
edition = "2021"
[dependencies]
clap = { version = "4.0", features = ["derive"], optional = true }
indexmap = { version = "2.0", features = ["serde"] }
serde = { version = "1.0", features = ["derive"] }
hyper = { version = "0.14", features = ["server", "tcp", "http1", "http2"], optional = true }
serde_yaml = "0.9"
serde_json = "1.0"
fancy-regex = "0.13.0"
anyhow = "1.0"
itertools = "0.13.0"
once_cell = "1.8"
tokio = { version = "1", features = ["full"], optional = true }
version-compare = "0.2.0"
fallible-iterator = "0.3"
moka = { version = "0.11", optional = true }
const_format = "0.2"
# dhat = "0.3.2"
libc = { version = "0.2", optional = true }
[build-dependencies]
cbindgen = { version = "0.26", optional = true }
[dev-dependencies]
stats_alloc = "0.1.1"
futures = "0.3"
glob = "0.3"
# proc macro to iterate over yml files in tests, has to be own crate.
test_each_file = { path = "test_each_file" }
[lib]
crate-type = ["cdylib", "staticlib", "rlib"]
[[bin]]
name = "rust-device-detector"
required-features = ["build-binary"]
[features]
default = []
full = ["cache", "build-binary", "ffi"]
# cache is a feature because moka brings in a lot of dependencies.
cache = ["dep:moka"]
ffi = ["dep:libc", "dep:cbindgen"]
build-binary = ["dep:clap", "dep:tokio", "dep:hyper"]
[profile.test]
# these tests take a long time without optimization
opt-level = 3
[profile.release]
# 15% improvement in speed, last time I tested.
lto = true
#debug = 1
#incremental = true
#debug = true