mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2025-07-28 11:37:44 +00:00
uucore: make libc optional
This commit is contained in:
parent
96e8748336
commit
0ea5314ea1
2 changed files with 10 additions and 6 deletions
|
@ -4,22 +4,25 @@ version = "0.0.1"
|
||||||
authors = []
|
authors = []
|
||||||
|
|
||||||
[dependencies]
|
[dependencies]
|
||||||
libc = { git = "https://github.com/rust-lang/libc.git" }
|
|
||||||
getopts = "*"
|
getopts = "*"
|
||||||
time = { version = "*", optional = true }
|
time = { version = "*", optional = true }
|
||||||
data-encoding = { version = "^1.1", optional = true }
|
data-encoding = { version = "^1.1", optional = true }
|
||||||
|
|
||||||
|
[dependencies.libc]
|
||||||
|
git = "https://github.com/rust-lang/libc.git"
|
||||||
|
optional = true
|
||||||
|
|
||||||
[features]
|
[features]
|
||||||
fs = []
|
fs = ["libc"]
|
||||||
utf8 = []
|
utf8 = []
|
||||||
encoding = ["data-encoding"]
|
encoding = ["data-encoding"]
|
||||||
parse_time = []
|
parse_time = []
|
||||||
utmpx = ["time"]
|
utmpx = ["time", "libc"]
|
||||||
c_types = []
|
c_types = ["libc"]
|
||||||
process = []
|
process = ["libc"]
|
||||||
signals = []
|
signals = []
|
||||||
wide = []
|
wide = []
|
||||||
default = ["fs", "utf8", "encoding", "parse_time", "utmpx", "c_types", "process", "signals", "wide"]
|
default = ["fs", "libc", "utf8", "encoding", "parse_time", "utmpx", "c_types", "process", "signals", "wide"]
|
||||||
|
|
||||||
[lib]
|
[lib]
|
||||||
path = "lib.rs"
|
path = "lib.rs"
|
||||||
|
|
|
@ -1,3 +1,4 @@
|
||||||
|
#[cfg(feature = "libc")]
|
||||||
pub extern crate libc;
|
pub extern crate libc;
|
||||||
|
|
||||||
#[macro_use]
|
#[macro_use]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue