build: Correctly enable dhat support in vmm crate

The "dhat-heap" feature needs to be enabled inside the vmm crate as a
depenency from the top-level as there is build time check for that
feature inside the vmm crate.

Signed-off-by: Rob Bradford <rbradford@rivosinc.com>
This commit is contained in:
Rob Bradford 2024-05-07 11:29:02 +01:00
parent a70808bae9
commit fd43b79f96
3 changed files with 4 additions and 1 deletions

1
Cargo.lock generated
View File

@ -2567,6 +2567,7 @@ dependencies = [
"cfg-if",
"clap",
"devices",
"dhat",
"epoll",
"event_monitor",
"flume",

View File

@ -63,7 +63,7 @@ wait-timeout = "0.2.0"
[features]
default = ["kvm", "io_uring"]
dbus_api = ["zbus", "vmm/dbus_api"]
dhat-heap = ["dhat"] # For heap profiling
dhat-heap = ["dhat", "vmm/dhat-heap"] # For heap profiling
guest_debug = ["vmm/guest_debug"]
igvm = ["vmm/igvm", "mshv"]
io_uring = ["vmm/io_uring"]

View File

@ -7,6 +7,7 @@ edition = "2021"
[features]
default = []
dbus_api = ["blocking", "futures", "zbus"]
dhat-heap = ["dhat"] # For heap profiling
guest_debug = ["kvm", "gdbstub", "gdbstub_arch"]
igvm = ["hex", "dep:igvm", "igvm_defs", "mshv-bindings", "range_map_vec"]
io_uring = ["block/io_uring"]
@ -27,6 +28,7 @@ blocking = { version = "1.5.1", optional = true }
cfg-if = "1.0.0"
clap = "4.5.4"
devices = { path = "../devices" }
dhat = { version = "0.3.3", optional = true }
epoll = "4.3.3"
event_monitor = { path = "../event_monitor" }
flume = "0.11.0"