| # Copyright 2016 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/package.gni") |
| |
| executable("bin") { |
| # This is called debugserver and not gdbserver because it is not intended |
| # to be gdb specific. E.g., The GDB Remote Serial Protocol is used by other |
| # debuggers, e.g., lldb. |
| output_name = "debugserver" |
| |
| sources = [ |
| "cmd_handler.cc", |
| "cmd_handler.h", |
| "io_loop.cc", |
| "io_loop.h", |
| "main.cc", |
| "server.cc", |
| "server.h", |
| "stop_reply_packet.cc", |
| "stop_reply_packet.h", |
| "thread_action_list.cc", |
| "thread_action_list.h", |
| "util.cc", |
| "util.h", |
| ] |
| |
| deps = [ |
| "//garnet/lib/debugger_utils", |
| "//garnet/lib/inferior_control", |
| "//garnet/public/lib/fsl", |
| "//garnet/public/lib/fxl", |
| "//zircon/public/lib/launchpad", |
| "//zircon/public/lib/zx", |
| ] |
| |
| libs = [ |
| "zircon", |
| ] |
| } |
| |
| group("tests") { |
| testonly = true |
| |
| public_deps = [ |
| ":debugserver-unittests", |
| "test_apps", |
| ] |
| } |
| |
| executable("debugserver-unittests") { |
| testonly = true |
| |
| sources = [ |
| "run_all_unittests.cc", |
| "stop_reply_packet.cc", |
| "stop_reply_packet.h", |
| "stop_reply_packet_unittest.cc", |
| "thread_action_list.cc", |
| "thread_action_list.h", |
| "thread_action_list_unittest.cc", |
| "util.cc", |
| "util.h", |
| "util_unittest.cc", |
| ] |
| |
| deps = [ |
| "//garnet/lib/debugger_utils", |
| "//garnet/public/lib/fxl", |
| "//third_party/googletest:gtest", |
| ] |
| |
| libs = [ "zircon" ] |
| } |
| |
| package("debugserver") { |
| deprecated_system_image = true |
| |
| deps = [ |
| ":bin", |
| ] |
| |
| binaries = [ { |
| name = "debugserver" |
| } ] |
| } |
| |
| package("debugserver_tests") { |
| testonly = true |
| deprecated_system_image = true |
| |
| deps = [ |
| ":tests", |
| ] |
| |
| tests = [ |
| { |
| name = "debugserver-unittests" |
| }, |
| { |
| name = "exit-test" |
| dest = "debugserver/exit-test" |
| }, |
| { |
| name = "crash-test" |
| dest = "debugserver/crash-test" |
| }, |
| { |
| name = "loop-test" |
| dest = "debugserver/loop-test" |
| }, |
| { |
| name = "syscall-test" |
| dest = "debugserver/syscall-test" |
| }, |
| { |
| name = "thread-test" |
| dest = "debugserver/thread-test" |
| }, |
| ] |
| } |