| # Copyright 2020 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/host.gni") |
| import("//build/test/test_package.gni") |
| |
| executable("sh_mirror") { |
| output_name = "sh_mirror" |
| |
| sources = [ "main.cc" ] |
| deps = [ |
| ":server_lib", |
| "//src/developer/debug/ipc:client", |
| "//src/developer/debug/zxdb/client", |
| "//src/developer/debug/zxdb/common", |
| "//zircon/public/lib/cmdline", |
| ] |
| } |
| |
| static_library("server_lib") { |
| public = [ |
| "command_line_options.h", |
| "server.h", |
| ] |
| |
| sources = [ |
| "command_line_options.cc", |
| "server.cc", |
| ] |
| |
| deps = [ |
| ":shared", |
| "//src/developer/debug/shared", |
| "//src/lib/fxl", |
| "//third_party/boringssl", |
| "//zircon/public/lib/cmdline", |
| ] |
| } |
| |
| source_set("shared") { |
| public = [ |
| "common.h", |
| "wire_format.h", |
| ] |
| sources = [ "wire_format.cc" ] |
| deps = [ |
| "//src/developer/debug/shared", |
| "//src/lib/fxl:fxl_logging", |
| ] |
| } |
| |
| source_set("client") { |
| public = [ "client.h" ] |
| sources = [ "client.cc" ] |
| deps = [ |
| ":shared", |
| "//src/developer/debug/shared", |
| "//zircon/public/lib/fbl", |
| ] |
| } |
| |
| install_host_tools("sh_mirror_host") { |
| deps = [ ":sh_mirror" ] |
| outputs = [ "sh_mirror" ] |
| } |
| |
| executable("sh_mirror_tests_bin") { |
| testonly = true |
| sources = [ |
| "client_server_test.cc", |
| "test_shared.cc", |
| "test_shared.h", |
| "wire_format_test.cc", |
| ] |
| deps = [ |
| ":client", |
| ":server_lib", |
| ":shared", |
| "//src/developer/debug/ipc:client", |
| "//src/lib/fxl/test:gtest_main", |
| "//third_party/googletest:gtest", |
| "//zircon/public/lib/async-loop", |
| "//zircon/public/lib/async-loop-cpp", |
| "//zircon/public/lib/cmdline", |
| "//zircon/public/lib/fbl", |
| "//zircon/public/lib/fdio", |
| "//zircon/public/lib/memfs", |
| ] |
| |
| # TODO(46840): Fix the leaks and remove this. |
| deps += [ "//build/config/sanitizers:suppress-lsan.DO-NOT-USE-THIS" ] |
| } |