Skip to content

Commit

Permalink
fix nightly warning about cfg lints
Browse files Browse the repository at this point in the history
  • Loading branch information
Taowyoo committed Aug 28, 2024
1 parent 7b4005b commit 1096938
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 1 deletion.
6 changes: 6 additions & 0 deletions mbedtls-platform-support/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -44,3 +44,9 @@ custom_gmtime_r = ["mbedtls-sys-auto/custom_gmtime_r", "chrono"]
custom_time = ["mbedtls-sys-auto/custom_time", "chrono"]
force_aesni_support = ["mbedtls-sys-auto/custom_has_support","mbedtls-sys-auto/aes_alt", "aesni"]
aesni = ["mbedtls-sys-auto/aesni"]

[lints.rust]
unexpected_cfgs = { level = "warn", check-cfg = [
'cfg(sys_threading_component, values("custom"))',
'cfg(sys_time_component, values("custom"))',
] }
7 changes: 7 additions & 0 deletions mbedtls-sys/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -72,3 +72,10 @@ custom_time = ["time"]
custom_gmtime_r = ["time"]
# deprecated features, these don't do anything anymore, can be removed on major version bump
pthread = ["threading"]

[lints.rust]
unexpected_cfgs = { level = "warn", check-cfg = [
'cfg(std_component, values("fs"))',
'cfg(threading_component, values("pthread"))',
'cfg(time_component, values("custom", "libc"))',
] }
11 changes: 10 additions & 1 deletion mbedtls/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -150,4 +150,13 @@ harness = false

[[bench]]
name = "cipher"
harness = false
harness = false

[lints.rust]
unexpected_cfgs = { level = "warn", check-cfg = [
'cfg(nightly)',
'cfg(sys_threading_component, values("custom"))',
'cfg(sys_time_component, values("custom"))',
'cfg(sys_std_component, values("entropy", "net"))',
'cfg(time_component, values("custom", "libc"))',
] }

0 comments on commit 1096938

Please sign in to comment.