chromium/chromeos/ash/services/network_config/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("//build/config/chromeos/ui_mode.gni")

assert(is_chromeos_ash)

static_library("network_config") {
  sources = [
    "cros_network_config.cc",
    "cros_network_config.h",
  ]
  public_deps = [
    "//base",
    "//chromeos/ash/components/network",
    "//chromeos/services/network_config/public/mojom",
    "//mojo/public/cpp/bindings",
  ]
  deps = [
    "//ash/constants",
    "//chromeos/ash/components/carrier_lock",
    "//chromeos/ash/components/dbus/hermes",
    "//chromeos/ash/components/dbus/shill",
    "//chromeos/ash/components/login/login_state",
    "//chromeos/ash/components/sync_wifi:network_eligibility_checker",
    "//chromeos/ash/components/system",
    "//chromeos/components/onc",
    "//chromeos/services/network_config/public/cpp",
    "//components/captive_portal/core",
    "//components/device_event_log",
    "//components/onc",
    "//components/user_manager",
    "//dbus",
    "//net",
  ]
}

component("in_process_instance") {
  output_name = "network_config_in_process_instance"
  defines = [ "IS_IN_PROCESS_NETWORK_CONFIG_IMPL" ]
  sources = [
    "in_process_instance.cc",
    "in_process_instance.h",
  ]
  public_deps = [
    "//base",
    "//chromeos/services/network_config/public/mojom",
    "//mojo/public/cpp/bindings",
  ]
  deps = [
    ":network_config",
    "//chromeos/ash/components/network",
  ]
}

source_set("test_support") {
  testonly = true
  sources = [
    "test_apn_data.cc",
    "test_apn_data.h",
    "test_network_configuration_observer.cc",
    "test_network_configuration_observer.h",
  ]
  public_deps = [
    "//chromeos/ash/components/network",
    "//chromeos/components/onc",
    "//chromeos/services/network_config/public/mojom",
  ]
  deps = [
    "//ash/constants:constants",
    "//components/onc",
  ]
}

source_set("unit_tests") {
  testonly = true
  sources = [ "cros_network_config_unittest.cc" ]
  deps = [
    ":network_config",
    ":test_support",
    "//ash/components/arc:prefs",
    "//ash/constants",
    "//base",
    "//base/test:test_support",
    "//chromeos/ash/components/carrier_lock",
    "//chromeos/ash/components/dbus/shill:test_support",
    "//chromeos/ash/components/login/login_state",
    "//chromeos/ash/components/network",
    "//chromeos/ash/components/network:test_support",
    "//chromeos/ash/components/system",
    "//chromeos/ash/services/network_config/public/cpp:test_support",
    "//chromeos/components/onc",
    "//chromeos/services/network_config/public/mojom",
    "//components/captive_portal/core",
    "//components/onc",
    "//components/prefs:test_support",
    "//components/proxy_config",
    "//components/sync_preferences:test_support",
    "//components/user_manager:test_support",
    "//net",
    "//testing/gtest",
    "//third_party/re2",
  ]
}