Skip to content

Commit 125aa57

Browse files
committed
Auto merge of #13782 - klensy:llibc, r=weihanglo
gate some libc usages under cfg(unix), drop os_info features Places few `libc` usages under `cfg(unix)`. That didn't remove it from tree, but still looks cleaner. Drop features from os_info crate, as serde support currently unused.
2 parents b89b81a + 57e820e commit 125aa57

File tree

4 files changed

+12
-7
lines changed

4 files changed

+12
-7
lines changed

Cargo.lock

Lines changed: 1 addition & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ miow = "0.6.0"
6868
opener = "0.7.0"
6969
openssl = "0.10.57"
7070
openssl-sys = "=0.9.92" # See rust-lang/cargo#13546 and openssl/openssl#23376 for pinning
71-
os_info = "3.8.2"
71+
os_info = { version = "3.8.2", default-features = false }
7272
pasetors = { version = "0.6.8", features = ["v3", "paserk", "std", "serde"] }
7373
pathdiff = "0.2"
7474
percent-encoding = "2.3"
@@ -173,7 +173,6 @@ indexmap.workspace = true
173173
itertools.workspace = true
174174
jobserver.workspace = true
175175
lazycell.workspace = true
176-
libc.workspace = true
177176
libgit2-sys.workspace = true
178177
memchr.workspace = true
179178
opener.workspace = true
@@ -208,6 +207,9 @@ supports-unicode = "3.0.0"
208207
[target.'cfg(target_has_atomic = "64")'.dependencies]
209208
tracing-chrome.workspace = true
210209

210+
[target.'cfg(unix)'.dependencies]
211+
libc.workspace = true
212+
211213
[target.'cfg(target_os = "linux")'.dependencies]
212214
cargo-credential-libsecret.workspace = true
213215

crates/cargo-util/Cargo.toml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ filetime.workspace = true
1414
hex.workspace = true
1515
ignore.workspace = true
1616
jobserver.workspace = true
17-
libc.workspace = true
1817
same-file.workspace = true
1918
sha2.workspace = true
2019
shell-escape.workspace = true
@@ -25,6 +24,9 @@ walkdir.workspace = true
2524
[target.'cfg(target_os = "macos")'.dependencies]
2625
core-foundation.workspace = true
2726

27+
[target.'cfg(unix)'.dependencies]
28+
libc.workspace = true
29+
2830
[target.'cfg(windows)'.dependencies]
2931
miow.workspace = true
3032
windows-sys = { workspace = true, features = ["Win32_Storage_FileSystem", "Win32_Foundation", "Win32_System_Console"] }

credential/cargo-credential/Cargo.toml

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "cargo-credential"
3-
version = "0.4.4"
3+
version = "0.4.5"
44
rust-version.workspace = true
55
edition.workspace = true
66
license.workspace = true
@@ -10,12 +10,14 @@ description = "A library to assist writing Cargo credential helpers."
1010

1111
[dependencies]
1212
anyhow.workspace = true
13-
libc.workspace = true
1413
serde = { workspace = true, features = ["derive"] }
1514
serde_json.workspace = true
1615
thiserror.workspace = true
1716
time.workspace = true
1817

18+
[target.'cfg(unix)'.dependencies]
19+
libc.workspace = true
20+
1921
[target.'cfg(windows)'.dependencies]
2022
windows-sys = { workspace = true, features = ["Win32_System_Console", "Win32_Foundation"] }
2123

0 commit comments

Comments
 (0)