-
Notifications
You must be signed in to change notification settings - Fork 10
/
Cargo.toml
195 lines (170 loc) · 5.48 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
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
[package]
name = "open62541"
version = "0.7.0"
authors = ["HMI Project"]
edition = "2021"
# Keep the MSRV number here in sync with `test.yaml`. We require Rust 1.80 since
# we want to conveniently exclude examples from published crate.
rust-version = "1.80"
description = "High-level, safe bindings for the C99 library open62541, an open source and free implementation of OPC UA (OPC Unified Architecture)."
documentation = "https://docs.rs/open62541"
readme = "README.md"
homepage = "https://github.com/HMIProject/open62541"
repository = "https://github.com/HMIProject/open62541.git"
license = "MPL-2.0"
keywords = ["opcua", "plc", "automation", "hardware", "protocol"]
categories = ["network-programming", "embedded", "api-bindings"]
include = ["src/", "README.md", "CHANGELOG.md"]
[dependencies]
futures-channel = "0.3.30"
futures-core = { version = "0.3.30", default-features = false }
futures-util = { version = "0.3.30", default-features = false }
log = "0.4.20"
open62541-sys = "0.4.9"
paste = "1.0.14"
serde = { version = "1.0.194", optional = true }
serde_json = { version = "1.0.111", optional = true }
thiserror = "2.0.3"
time = { version = "0.3.36", optional = true }
tokio = { version = "1.35.1", optional = true, features = [
"rt",
"sync",
"time",
] }
x509-certificate = { version = "0.24.0", optional = true }
[dev-dependencies]
anyhow = "1.0.79"
env_logger = "0.11.1"
futures = "0.3.30"
itertools = "0.13.0"
rand = "0.8.5"
time = { version = "0.3.31", features = ["macros"] }
# Enable multi-threaded runtime in examples to increase the chances of finding
# problems with our use of open62541.
tokio = { version = "1.35.1", features = ["macros", "rt-multi-thread"] }
[features]
default = ["serde", "time", "tokio"]
mbedtls = ["open62541-sys/mbedtls"]
serde = ["dep:serde", "dep:serde_json", "time?/formatting", "time?/serde"]
time = ["dep:time"]
tokio = ["dep:tokio"]
x509 = ["dep:x509-certificate"]
[lints.rust]
future_incompatible = { level = "warn", priority = -1 }
keyword_idents = { level = "warn", priority = -1 }
let_underscore = { level = "warn", priority = -1 }
missing_debug_implementations = "warn"
nonstandard_style = { level = "warn", priority = -1 }
refining_impl_trait = { level = "warn", priority = -1 }
rust_2018_compatibility = { level = "warn", priority = -1 }
rust_2018_idioms = { level = "warn", priority = -1 }
rust_2021_compatibility = { level = "warn", priority = -1 }
rust_2024_compatibility = { level = "warn", priority = -1 }
trivial_casts = "warn"
trivial_numeric_casts = "warn"
unreachable_pub = "warn"
# Writing unsafe code is a necessity for FFI wrappers.
unsafe_code = "allow"
unsafe_op_in_unsafe_fn = "warn"
unused = { level = "warn", priority = -1 }
warnings = "warn"
[lints.clippy]
# We use absolute paths where we require some item only once. Most often, these
# share a name with another item in scope and we don't want to import an alias.
absolute_paths = "allow"
allow_attributes = "warn"
allow_attributes_without_reason = "warn"
as_conversions = "warn"
as_ptr_cast_mut = "warn"
as_underscore = "warn"
cast_possible_truncation = "warn"
clone_on_ref_ptr = "warn"
default_trait_access = "warn"
enum_variant_names = "warn"
error_impl_error = "warn"
# We panic in certain less likely situations. In each case, this is documented.
expect_used = "allow"
fallible_impl_from = "warn"
format_push_string = "warn"
get_unwrap = "warn"
index_refutable_slice = "warn"
indexing_slicing = "warn"
manual_assert = "warn"
match_on_vec_items = "warn"
match_wild_err_arm = "warn"
# TODO: Add assert messages.
missing_assert_message = "allow"
missing_const_for_fn = "warn"
missing_errors_doc = "warn"
mod_module_files = "warn"
# We export most types from the top module, allow prefixes to distinguish them.
module_name_repetitions = "allow"
# We panic in certain less likely situations. In each case, this is documented.
panic = "allow"
panic_in_result_fn = "warn"
pedantic = { level = "warn", priority = -1 }
should_panic_without_expect = "warn"
string_slice = "warn"
unimplemented = "warn"
unnecessary_self_imports = "warn"
# We panic in certain less likely situations. In each case, this is documented.
unreachable = "allow"
# We panic in certain less likely situations. In each case, this is documented.
unwrap_in_result = "allow"
# TODO: Use `expect()` instead.
unwrap_used = "allow"
verbose_file_reads = "warn"
[[example]]
name = "async_browse"
required-features = ["tokio"]
[[example]]
name = "async_call"
required-features = ["tokio"]
[[example]]
name = "async_client"
required-features = ["tokio"]
[[example]]
name = "async_client_builder"
required-features = ["tokio"]
[[example]]
name = "async_concurrent"
required-features = ["tokio"]
[[example]]
name = "async_monitor"
required-features = ["tokio"]
[[example]]
name = "async_read_write"
required-features = ["tokio"]
[[example]]
name = "async_send_sync"
required-features = ["time", "tokio"]
[[example]]
name = "client_builder"
[[example]]
name = "client_encryption"
required-features = ["mbedtls"]
[[example]]
name = "server"
[[example]]
name = "server_access_control"
required-features = ["mbedtls"]
[[example]]
name = "server_access_control_callback"
required-features = ["mbedtls"]
[[example]]
name = "server_builder"
[[example]]
name = "server_cancellable"
[[example]]
name = "server_data_source"
[[example]]
name = "server_encryption"
required-features = ["mbedtls"]
[[example]]
name = "server_method_callback"
[[example]]
name = "ssl_create_certificate"
required-features = ["mbedtls", "x509"]
[[example]]
name = "ssl_fetch_certificate"
required-features = ["mbedtls", "x509"]