blob: 1fb87d09b926b0b60db6c33a86fefd5d94165e36 [file] [log] [blame]
# Hypervisor specific code.
source_set("src") {
sources = [
"alloc.c",
"api.c",
"cpio.c",
"cpu.c",
"load.c",
"main.c",
"mm.c",
"vm.c",
]
deps = [
":common",
":fdt",
":fdt_handler",
":memiter",
]
if (is_debug) {
deps += [ ":common_debug" ]
}
}
# Code that is not specific to a certain image so can be shared.
source_set("common") {
sources = [
"std.c",
]
}
# Debug code that is not specific to a certain image so can be shared.
source_set("common_debug") {
sources = [
"dlog.c",
]
deps = [
":common",
"//src/arch/${arch}:putchar",
]
}
source_set("fdt") {
sources = [
"fdt.c",
]
deps = [
":common",
":common_debug",
]
}
source_set("fdt_handler") {
sources = [
"fdt_handler.c",
]
deps = [
":common",
":common_debug",
":fdt",
]
}
source_set("memiter") {
sources = [
"memiter.c",
]
}
executable("unit_tests") {
testonly = true
sources = [
"fdt_handler_test.cc",
"fdt_test.cc",
]
cflags_cc = [ "-Wno-c99-extensions" ]
deps = [
":fdt",
":fdt_handler",
"mock:mm",
"//third_party:gtest_main",
]
}