blob: 485e3d5abbbfe2ca134918048f42c99843dd2d37 [file] [log] [blame]
# Copyright 2021 The Fuchsia Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import("//build/components.gni")
import("//build/test.gni")
import("//build/zircon/migrated_targets.gni")
zx_library("elfldltl") {
host = true
kernel = true
static = true
sdk = "source"
sdk_headers = [
"lib/elfldltl/constants.h",
"lib/elfldltl/field.h",
"lib/elfldltl/layout.h",
]
sdk_migrated = true
sources = []
public_deps = [ "//sdk/lib/stdcompat" ]
if (is_kernel) {
deps = [
"//zircon/kernel/lib/ktl",
"//zircon/kernel/lib/libc",
]
}
}
test("elfldltl-unittests") {
deps = [ ":unittests" ]
}
# These pure unit tests can be included in a standalone ZBI test binary too.
source_set("unittests") {
sources = [
"field-tests.cc",
"layout-tests.cc",
]
deps = [
".",
"//sdk/lib/stdcompat",
"//zircon/system/ulib/zxtest",
]
}
fuchsia_unittest_package("elfldltl-tests") {
deps = [ ":elfldltl-unittests" ]
}
group("tests") {
testonly = true
deps = [
":elfldltl-tests",
":elfldltl-unittests($host_toolchain)",
]
}