Skip to content

Commit a1d7798

Browse files
authored
Merge pull request uutils#10441 from xtqqczze/deps/nix
fix(deps): refactor nix package configuration
2 parents 28b52bb + f19b9f0 commit a1d7798

File tree

12 files changed

+29
-16
lines changed

12 files changed

+29
-16
lines changed

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -563,8 +563,8 @@ nix = { workspace = true, features = [
563563
"process",
564564
"signal",
565565
"socket",
566-
"user",
567566
"term",
567+
"user",
568568
] }
569569
rlimit = "0.10.1"
570570
xattr.workspace = true

src/uu/dd/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@ thiserror = { workspace = true }
3232
fluent = { workspace = true }
3333

3434
[target.'cfg(any(target_os = "linux", target_os = "android"))'.dependencies]
35-
signal-hook = { workspace = true }
3635
nix = { workspace = true, features = ["fs"] }
36+
signal-hook = { workspace = true }
3737

3838
[[bin]]
3939
name = "dd"

src/uu/env/Cargo.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@ fluent = { workspace = true }
2727
[target.'cfg(unix)'.dependencies]
2828
nix = { workspace = true, features = ["signal"] }
2929

30-
3130
[[bin]]
3231
name = "env"
3332
path = "src/main.rs"

src/uu/kill/Cargo.toml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,12 @@ path = "src/kill.rs"
1919

2020
[dependencies]
2121
clap = { workspace = true }
22-
nix = { workspace = true, features = ["signal"] }
2322
uucore = { workspace = true, features = ["signals"] }
2423
fluent = { workspace = true }
2524

25+
[target.'cfg(unix)'.dependencies]
26+
nix = { workspace = true, features = ["signal"] }
27+
2628
[[bin]]
2729
name = "kill"
2830
path = "src/main.rs"

src/uu/mkfifo/Cargo.toml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,12 @@ path = "src/mkfifo.rs"
1919

2020
[dependencies]
2121
clap = { workspace = true }
22-
nix = { workspace = true, features = ["fs"] }
2322
uucore = { workspace = true, features = ["fs", "mode"] }
2423
fluent = { workspace = true }
2524

25+
[target.'cfg(unix)'.dependencies]
26+
nix = { workspace = true, features = ["fs"] }
27+
2628
[features]
2729
selinux = ["uucore/selinux"]
2830
smack = ["uucore/smack"]

src/uu/nice/Cargo.toml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,12 @@ path = "src/nice.rs"
2020
[dependencies]
2121
clap = { workspace = true }
2222
libc = { workspace = true }
23-
nix = { workspace = true }
2423
uucore = { workspace = true }
2524
fluent = { workspace = true }
2625

26+
[target.'cfg(unix)'.dependencies]
27+
nix = { workspace = true }
28+
2729
[[bin]]
2830
name = "nice"
2931
path = "src/main.rs"

src/uu/stty/Cargo.toml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,9 +20,11 @@ path = "src/stty.rs"
2020
[dependencies]
2121
clap = { workspace = true }
2222
uucore = { workspace = true, features = ["parser"] }
23-
nix = { workspace = true, features = ["term", "ioctl"] }
2423
fluent = { workspace = true }
2524

25+
[target.'cfg(unix)'.dependencies]
26+
nix = { workspace = true, features = ["ioctl", "term"] }
27+
2628
[[bin]]
2729
name = "stty"
2830
path = "src/main.rs"

src/uu/timeout/Cargo.toml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,12 @@ path = "src/timeout.rs"
2020
[dependencies]
2121
clap = { workspace = true }
2222
libc = { workspace = true }
23-
nix = { workspace = true, features = ["signal"] }
2423
uucore = { workspace = true, features = ["parser", "process", "signals"] }
2524
fluent = { workspace = true }
2625

26+
[target.'cfg(unix)'.dependencies]
27+
nix = { workspace = true, features = ["signal"] }
28+
2729
[[bin]]
2830
name = "timeout"
2931
path = "src/main.rs"

src/uu/tsort/Cargo.toml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,11 @@ clap = { workspace = true }
2323
fluent = { workspace = true }
2424
string-interner = { workspace = true }
2525
thiserror = { workspace = true }
26-
nix = { workspace = true, features = ["fs"] }
2726
uucore = { workspace = true }
2827

28+
[target.'cfg(unix)'.dependencies]
29+
nix = { workspace = true, features = ["fs"] }
30+
2931
[[bin]]
3032
name = "tsort"
3133
path = "src/main.rs"

src/uu/tty/Cargo.toml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,12 @@ path = "src/tty.rs"
1919

2020
[dependencies]
2121
clap = { workspace = true }
22-
nix = { workspace = true, features = ["term"] }
2322
uucore = { workspace = true, features = ["fs"] }
2423
fluent = { workspace = true }
2524

25+
[target.'cfg(unix)'.dependencies]
26+
nix = { workspace = true, features = ["term"] }
27+
2628
[[bin]]
2729
name = "tty"
2830
path = "src/main.rs"

0 commit comments

Comments
 (0)