mirror of
https://chromium.googlesource.com/crosvm/crosvm
synced 2024-11-24 20:48:55 +00:00
94217cc88b
"enable" feature in swap crate was set as default to run unit/integration tests of the crate. https://crrev.com/c/4486546 However missing `default-features = false` at non-root Cargo.toml cause other crates (e.g. x86_64) installing userfaultfd always. This makes the swap/enable non-default. CQ still runs unit/integration tests of the swap crate on aarch64 and x86_64. BUG=b:281935498 TEST=cargo test -p swap --features=swap/enable Change-Id: I57436c3cb8cbdfac04c3145cc599261b89cf4e0e Reviewed-on: https://chromium-review.googlesource.com/c/crosvm/crosvm/+/4518090 Commit-Queue: Shin Kawamura <kawasin@google.com> Reviewed-by: Dennis Kempin <denniskempin@google.com>
45 lines
1 KiB
TOML
45 lines
1 KiB
TOML
[package]
|
|
name = "swap"
|
|
version = "0.1.0"
|
|
authors = ["The ChromiumOS Authors"]
|
|
edition = "2021"
|
|
|
|
# The process tests will use fork, which requires a custom test harness to enforce single threaded
|
|
# execution.
|
|
[[test]]
|
|
name = "main"
|
|
path = "tests/main.rs"
|
|
harness = false
|
|
|
|
|
|
[features]
|
|
trace_marker = ["cros_tracing/trace_marker"]
|
|
log_page_fault = []
|
|
enable = ["userfaultfd", "userfaultfd-sys"]
|
|
|
|
[dependencies]
|
|
anyhow = "*"
|
|
base = { path = "../base" }
|
|
cfg-if = "*"
|
|
cros_tracing = { path = "../cros_tracing" }
|
|
data_model = { path = "../common/data_model" }
|
|
jail = { path = "../jail"}
|
|
num_cpus = "*"
|
|
once_cell = "*"
|
|
remain = "*"
|
|
serde = { version = "1", features = [ "derive" ] }
|
|
serde_json = "*"
|
|
sync = { path = "../common/sync" } # provided by ebuild
|
|
thiserror = "*"
|
|
vm_memory = { path = "../vm_memory"}
|
|
|
|
[target.'cfg(unix)'.dependencies]
|
|
libc = "*"
|
|
|
|
[target.'cfg(target_os="linux")'.dependencies]
|
|
userfaultfd = { version = "0.5.0", optional = true }
|
|
userfaultfd-sys = { version = "0.4.2", optional = true }
|
|
|
|
[dev_dependencies]
|
|
libtest-mimic = "0.6"
|
|
tempfile = "*"
|