chromium/components/gwp_asan/BUILD.gn

# Copyright 2018 The Chromium Authors
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.

import("//testing/test.gni")

# Defined as a separate target so that on Android tests can be launched in a
# sub-thread instead of on the main thread to support multi-process tests.
# Can be removed after minSdkVersion >= Q
test("gwp_asan_unittests") {
  testonly = true
  deps = [
    "//base/test:run_all_unittests",
    "//components/gwp_asan/common:unit_tests",
    "//testing/gtest",
    "//third_party/boringssl",
  ]
  if (is_win || is_mac || is_linux || is_chromeos || is_android) {
    deps += [
      "//components/gwp_asan/client:unit_tests",
      "//components/gwp_asan/crash_handler:unit_tests",
    ]
  }
  data_deps = [ "//testing/buildbot/filters:gwp_asan_unittests_filters" ]
}

if (is_win || is_mac || is_linux || is_chromeos || is_android) {
  executable("dump_gwp_asan") {
    sources = [ "tools/dump_gwp_asan/dump_gwp_asan.cc" ]

    deps = [
      "//base",
      "//build/win:default_exe_manifest",
      "//components/gwp_asan/crash_handler",
      "//components/gwp_asan/crash_handler:crash_proto",
      "//third_party/crashpad/crashpad/minidump",
      "//third_party/crashpad/crashpad/snapshot",
      "//third_party/crashpad/crashpad/util",
      "//third_party/protobuf:protobuf_lite",
    ]
  }
}