-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCargo.toml
More file actions
59 lines (52 loc) · 2.05 KB
/
Copy pathCargo.toml
File metadata and controls
59 lines (52 loc) · 2.05 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
[package]
name = "rcp"
version = "5.11.0"
edition = "2021"
rust-version = "1.75"
license = "MPL-2.0"
description = "Remote Control Protocol for automotive zonal architecture"
keywords = ["automotive", "rcp", "functional-safety", "iso26262"]
categories = ["embedded", "network-programming"]
[lib]
name = "rcp"
path = "src/lib.rs"
[features]
# Opt-in only: not enabled by any other feature and not part of `default`.
# Gates `rcp::iseled::iseled_frame_crc8`/`IseledFrameCrc`, this crate's
# invented CRC-8/AUTOSAR stand-in for ISELED's own (still unrecovered)
# native per-frame CRC parameters. See `src/iseled.rs`'s module doc comment
# "Provenance note: the native ISELED CRC is a distinct, additive layer".
iseled-unconfirmed-crc = []
[[bin]]
name = "rust-rcp"
path = "src/bin/rcp.rs"
[dependencies]
thiserror = "1"
parking_lot = "0.12"
serde = { version = "1", features = ["derive"] }
serde_json = "1"
serde_yaml = "0.9"
base64 = "0.22"
chrono = { version = "0.4", features = ["serde"] }
tokio = { version = "1", features = ["rt", "rt-multi-thread", "sync", "time", "macros"] }
async-trait = "0.1"
[dev-dependencies]
tempfile = "3"
tokio-test = "0.4"
[profile.release]
strip = true
opt-level = "z"
lto = true
codegen-units = 1
# `src/l2.rs`'s raw AF_PACKET/SOCK_RAW transport: this crate is
# `#![forbid(unsafe_code)]` crate-wide (`src/lib.rs`), which rules out a
# direct `libc` `socket()`/`bind()`/`sendto()`/`recvfrom()` implementation
# (that would require `unsafe extern "C"` calls in this crate's own
# source, and `forbid` cannot be locally overridden). `nix` wraps those
# same syscalls in a fully safe Rust API (`unsafe` lives inside `nix`'s
# own crate, not this one) and is gated to `target_os = "linux"` here so
# no other build target's dependency graph grows because of it — see
# `src/l2.rs`'s own module doc comment, "Why `nix`, not raw `libc`
# `unsafe` syscalls — a flagged judgment call", for the full reasoning.
[target.'cfg(target_os = "linux")'.dependencies]
nix = { version = "0.31.3", features = ["socket", "net"] }