Commit 66c53eef authored by brettw's avatar brettw Committed by Commit bot

Add remoting and PPAPI tests to GN build

Reland of https://codereview.chromium.org/965633002/

TBR=dpranke

Review URL: https://codereview.chromium.org/961323004

Cr-Commit-Position: refs/heads/master@{#318756}
parent 32e6c721
......@@ -63,8 +63,10 @@ group("gn_all") {
"//mojo",
"//mojo/common:mojo_common_unittests",
"//net:net_unittests",
"//ppapi:ppapi_unittests",
"//ppapi/examples", # TODO(GYP): What's the GYP equivalent?
"//printing:printing_unittests",
"//remoting:remoting_unittests",
"//skia:skia_unittests",
"//sql:sql_unittests",
"//sync:sync_unit_tests",
......@@ -276,8 +278,6 @@ if (is_linux) {
# components_browsertests TODO(GYP)
# device_unittests TODO(GYP)
# nacl_loader_unittests TODO(GYP)
# ppapi_unittests TODO(GYP)
# remoting_unittests TODO(GYP)
"//base:base_unittests", # PASSES (*) 2/25/2015
"//cc:cc_unittests", # PASSES 2/25/2015
......@@ -304,7 +304,9 @@ if (is_linux) {
"//media:media_unittests", # TODO(GYP) MidiManagerTest fails.
"//mojo/common:mojo_common_unittests", # PASSES 2/25/2015
"//net:net_unittests", # PASSES 2/25/2015
"//ppapi:ppapi_unittests", # PASSES 2/26/2015
"//printing:printing_unittests", # PASSES 2/25/2015
"//remoting:remoting_unittests", # Some crashes.
"//sandbox/linux:sandbox_linux_unittests", # PASSES 2/25/2015
"//skia:skia_unittests", # PASSES 2/25/2015
"//sql:sql_unittests", # PASSES 2/25/2015
......
# Copyright 2015 The Chromium 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/config/linux/pkg_config.gni")
assert(is_linux, "This file should only be referenced on Linux")
# Depend on //build/config/linux/gtk to use GTK.
#
# GN doesn't check visibility for configs so we give this an obviously internal
# name to discourage random targets from accidentally depending on this and
# bypassing the GTK target's visibility.
pkg_config("gtk_internal_config") {
# Gtk requires gmodule, but it does not list it as a dependency in some
# misconfigured systems.
packages = [
"gmodule-2.0",
"gtk+-2.0",
"gthread-2.0",
]
}
# Basically no parts of Chrome should depend on GTK. To prevent accidents, the
# parts that explicitly need GTK are whitelisted on this target.
group("gtk") {
visibility = [
"//chrome/browser/ui/libgtk2ui",
"//remoting/host",
]
direct_dependent_configs = [ ":gtk_internal_config" ]
}
# Depend on "gtkprint" to get this.
pkg_config("gtkprint_internal_config") {
packages = [ "gtk+-unix-print-2.0" ]
}
group("gtkprint") {
visibility = [ "//chrome/browser/ui/libgtk2ui" ]
direct_dependent_configs = [ ":gtkprint_internal_config" ]
}
......@@ -5,21 +5,6 @@
assert(is_linux, "This file should only be referenced on Linux")
import("//build/config/features.gni")
import("//build/config/linux/pkg_config.gni")
pkg_config("gtk") {
# Gtk requires gmodule, but it does not list it as a dependency in some
# misconfigured systems.
packages = [
"gmodule-2.0",
"gtk+-2.0",
"gthread-2.0",
]
}
pkg_config("gtkprint") {
packages = [ "gtk+-unix-print-2.0" ]
}
component("libgtk2ui") {
sources = [
......@@ -79,8 +64,6 @@ component("libgtk2ui") {
defines = [ "LIBGTK2UI_IMPLEMENTATION" ]
configs += [
":gtk",
":gtkprint",
"//build/config/linux:gconf",
"//printing:cups",
]
......@@ -109,6 +92,8 @@ component("libgtk2ui") {
"//base",
"//base/third_party/dynamic_annotations",
"//base:i18n",
"//build/config/linux/gtk",
"//build/config/linux/gtk:gtkprint",
"//chrome/app/theme:theme_resources",
"//chrome:extra_resources",
"//chrome:resources",
......
......@@ -3,6 +3,8 @@
# found in the LICENSE file.
import("//ppapi/ppapi_sources.gni")
import("//testing/test.gni")
shared_library("ppapi_tests") {
sources = ppapi_sources.test_common_source_files +
ppapi_sources.test_trusted_source_files
......@@ -15,4 +17,76 @@ shared_library("ppapi_tests") {
"//ppapi/shared_impl",
]
}
# TODO(GYP) other targets from ppapi_tests.gyp
test("ppapi_unittests") {
sources = [
"host/resource_message_filter_unittest.cc",
"proxy/device_enumeration_resource_helper_unittest.cc",
"proxy/file_chooser_resource_unittest.cc",
"proxy/file_system_resource_unittest.cc",
"proxy/flash_resource_unittest.cc",
"proxy/interface_list_unittest.cc",
"proxy/mock_resource.cc",
"proxy/mock_resource.h",
"proxy/nacl_message_scanner_unittest.cc",
"proxy/pdf_resource_unittest.cc",
"proxy/plugin_dispatcher_unittest.cc",
"proxy/plugin_resource_tracker_unittest.cc",
"proxy/plugin_var_tracker_unittest.cc",
"proxy/ppb_var_unittest.cc",
"proxy/ppp_instance_private_proxy_unittest.cc",
"proxy/ppp_instance_proxy_unittest.cc",
"proxy/ppp_messaging_proxy_unittest.cc",
"proxy/printing_resource_unittest.cc",
"proxy/raw_var_data_unittest.cc",
"proxy/serialized_var_unittest.cc",
"proxy/talk_resource_unittest.cc",
"proxy/video_decoder_resource_unittest.cc",
"proxy/video_encoder_resource_unittest.cc",
"proxy/websocket_resource_unittest.cc",
"shared_impl/media_stream_audio_track_shared_unittest.cc",
"shared_impl/media_stream_buffer_manager_unittest.cc",
"shared_impl/media_stream_video_track_shared_unittest.cc",
"shared_impl/proxy_lock_unittest.cc",
"shared_impl/resource_tracker_unittest.cc",
"shared_impl/thread_aware_callback_unittest.cc",
"shared_impl/time_conversion_unittest.cc",
"shared_impl/tracked_callback_unittest.cc",
"shared_impl/var_tracker_unittest.cc",
]
deps = [
"//base/allocator",
"//base/test:run_all_unittests",
"//base/test:test_support",
"//gpu/ipc",
"//ipc",
"//ipc:test_support",
"//media:shared_memory_support",
"//ppapi/host",
"//ppapi/proxy",
"//ppapi/proxy:test_support",
"//ppapi/shared_impl",
"//ppapi/shared_impl:test_support",
"//testing/gmock",
"//testing/gtest",
"//ui/surface",
]
}
test("ppapi_perftests") {
sources = [
"proxy/ppapi_perftests.cc",
"proxy/ppp_messaging_proxy_perftest.cc",
]
deps = [
"//base/allocator",
"//base/test:test_support",
"//ppapi/proxy",
"//ppapi/proxy:test_support",
"//ppapi/shared_impl",
"//ppapi/shared_impl:test_support",
"//testing/gtest",
]
}
......@@ -5,7 +5,7 @@
{
'targets': [
{
# GN version: //ppapi:ppapi_host
# GN version: //ppapi/host
'target_name': 'ppapi_host',
'type': '<(component)',
'dependencies': [
......
......@@ -5,6 +5,7 @@
{
'targets': [
{
# GN version: //ppapi:ppapi_tests
'target_name': 'ppapi_tests',
'type': 'loadable_module',
'include_dirs': [
......@@ -106,6 +107,7 @@
},
{
# GN version: //ppapi:ppapi_perftests
'target_name': 'ppapi_perftests',
'type': 'executable',
'variables': {
......@@ -132,6 +134,7 @@
],
},
{
# GN version: //ppapi:ppapi_unittests
'target_name': 'ppapi_unittests',
'type': 'executable',
'variables': {
......@@ -153,6 +156,7 @@
'../ui/surface/surface.gyp:surface',
],
'sources': [
# Note: sources list duplicated in GN build.
'host/resource_message_filter_unittest.cc',
'proxy/device_enumeration_resource_helper_unittest.cc',
'proxy/file_chooser_resource_unittest.cc',
......
# Copyright 2015 The Chromium 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/config/features.gni")
import("//build/config/ui.gni")
import("//remoting/remoting_version.gni")
import("//testing/test.gni")
enable_remoting_host = is_win || is_mac || is_chromeos || use_x11
# Various remoting targets need this version definition.
config("version") {
defines = [ "VERSION=$version_full" ]
}
# GYP version: remoting/remoting_test.gypi:remoting_test_common
source_set("test_support") {
testonly = true
sources = [
# Files from remoting_test_common not in separate test_support targets.
"signaling/fake_signal_strategy.cc",
"signaling/fake_signal_strategy.h",
"signaling/mock_signal_strategy.cc",
"signaling/mock_signal_strategy.h",
"test/access_token_fetcher.cc",
"test/app_remoting_test_driver_environment.cc",
"test/fake_access_token_fetcher.cc",
"test/fake_network_dispatcher.cc",
"test/fake_network_dispatcher.h",
"test/fake_network_manager.cc",
"test/fake_network_manager.h",
"test/fake_port_allocator.cc",
"test/fake_port_allocator.h",
"test/fake_socket_factory.cc",
"test/fake_socket_factory.h",
"test/leaky_bucket.cc",
"test/leaky_bucket.h",
"test/mock_access_token_fetcher.cc",
"test/refresh_token_store.cc",
]
deps = [
"//base",
"//components/policy:test_support",
"//net",
"//remoting/base",
"//remoting/client",
"//remoting/codec",
"//remoting/protocol:test_support",
"//remoting/resources",
"//testing/gmock",
"//testing/gtest",
]
if (enable_remoting_host) {
deps += [ "//remoting/host:test_support" ]
}
}
test("remoting_unittests") {
# Sources not included in one of the more specific unit_tests deps.
sources = [
"signaling/iq_sender_unittest.cc",
"signaling/log_to_server_unittest.cc",
"signaling/server_log_entry_unittest.cc",
"signaling/server_log_entry_unittest.h",
"test/access_token_fetcher_unittest.cc",
"test/app_remoting_test_driver_environment_unittest.cc",
]
deps = [
":test_support",
"//base/allocator",
"//google_apis",
"//remoting/base:unit_tests",
"//remoting/client:unit_tests",
"//remoting/protocol:unit_tests",
"//testing/gmock",
"//testing/gtest",
"//third_party/webrtc",
]
if (is_android) {
deps += [ "//testing/android:native_test_native_code" ]
} else {
deps += [ "//remoting/client/plugin" ]
}
if (enable_remoting_host) {
deps += [
"//remoting/codec:unit_tests",
"//remoting/host:unit_tests",
]
}
if (enable_webrtc) {
deps += [
"//third_party/libjingle:libjingle_webrtc",
"//third_party/libjingle:libpeerconnection",
]
}
}
......@@ -2,13 +2,12 @@
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
static_library("base") {
gypi_values = exec_script("//build/gypi_to_gn.py",
[ rebase_path("../remoting_srcs.gypi") ],
"scope",
[ "../remoting_srcs.gypi" ])
import("//remoting/remoting_srcs.gni")
sources = rebase_path(gypi_values.remoting_base_sources, ".", "//remoting")
source_set("base") {
sources = rebase_path(remoting_srcs_gypi_values.remoting_base_sources,
".",
"//remoting")
configs += [ "//build/config/compiler:wexit_time_destructors" ]
......@@ -25,10 +24,41 @@ static_library("base") {
"//remoting/resources",
"//third_party/libvpx",
"//third_party/libyuv",
"//third_party/opus",
"//third_party/webrtc/modules/desktop_capture",
"//ui/base",
"//ui/gfx",
"//ui/gfx/geometry",
]
}
source_set("unit_tests") {
testonly = true
sources = [
"auto_thread_task_runner_unittest.cc",
"auto_thread_unittest.cc",
"breakpad_win_unittest.cc",
"buffered_socket_writer_unittest.cc",
"capabilities_unittest.cc",
"compound_buffer_unittest.cc",
"rate_counter_unittest.cc",
"rsa_key_pair_unittest.cc",
"run_all_unittests.cc",
"running_average_unittest.cc",
"test_rsa_key_pair.h",
"typed_buffer_unittest.cc",
"util_unittest.cc",
]
if (is_win || is_mac || is_chromeos) {
sources += [ "resources_unittest.cc" ]
}
deps = [
":base",
"//base",
"//net:test_support",
"//testing/gmock",
"//testing/gtest",
"//third_party/libyuv",
"//third_party/webrtc/modules/desktop_capture",
]
}
......@@ -2,24 +2,48 @@
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
import("//remoting/remoting_version.gni")
import("//remoting/remoting_srcs.gni")
static_library("client") {
gypi_values = exec_script("//build/gypi_to_gn.py",
[ rebase_path("../remoting_srcs.gypi") ],
"scope",
[ "../remoting_srcs.gypi" ])
source_set("client") {
sources = rebase_path(remoting_srcs_gypi_values.remoting_client_sources,
".",
"//remoting")
sources = rebase_path(gypi_values.remoting_client_sources, ".", "//remoting")
configs += [ "//build/config/compiler:wexit_time_destructors" ]
defines = [ "VERSION=$version_full" ]
configs += [
"//build/config/compiler:wexit_time_destructors",
"//remoting:version",
]
deps = [
"//remoting/base",
"//remoting/codec",
"//remoting/protocol",
"//third_party/libyuv",
"//third_party/webrtc/modules/desktop_capture",
]
}
source_set("unit_tests") {
testonly = true
sources = [
"audio_player_unittest.cc",
"client_status_logger_unittest.cc",
"key_event_mapper_unittest.cc",
"plugin/empty_cursor_filter_unittest.cc",
"plugin/normalizing_input_filter_mac_unittest.cc",
"server_log_entry_client_unittest.cc",
]
if (is_chromeos) {
sources += [ "plugin/normalizing_input_filter_cros_unittest.cc" ]
}
deps = [
":client",
"//remoting/proto",
"//testing/gmock",
"//testing/gtest",
"//third_party/webrtc",
]
}
......@@ -2,16 +2,22 @@
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
static_library("plugin") {
gypi_values = exec_script("//build/gypi_to_gn.py",
[ rebase_path("../../remoting_srcs.gypi") ],
"scope",
[ "../../remoting_srcs.gypi" ])
import("//remoting/remoting_srcs.gni")
source_set("plugin") {
sources =
rebase_path(gypi_values.remoting_client_plugin_sources, ".", "//remoting")
rebase_path(remoting_srcs_gypi_values.remoting_client_plugin_sources,
".",
"//remoting")
# TODO(brettw) when a nacl version of this target is made, these files
if (!is_chromeos) {
sources -= [
"normalizing_input_filter_cros.cc",
"normalizing_input_filter_cros.h",
]
}
# TODO(GYP) when a nacl version of this target is made, these files
# won't be part of it.
sources += [
"pepper_entrypoints.cc",
......@@ -28,6 +34,7 @@ static_library("plugin") {
"//ppapi/cpp/private:internal_module",
"//remoting/base",
"//remoting/client",
"//remoting/codec",
"//remoting/protocol",
"//third_party/webrtc/modules/desktop_capture",
"//ui/events:dom4_keycode_converter",
......
# Copyright 2015 The Chromium 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("//remoting/remoting_srcs.gni")
source_set("codec") {
sources = rebase_path(remoting_srcs_gypi_values.remoting_codec_sources,
".",
"//remoting")
configs += [ "//build/config/compiler:wexit_time_destructors" ]
deps = [
"//base/third_party/dynamic_annotations",
"//media",
"//media:shared_memory_support",
"//remoting/proto",
"//remoting/resources",
"//third_party/libvpx",
"//third_party/libyuv",
"//third_party/opus",
"//third_party/webrtc/modules/desktop_capture",
]
}
source_set("unit_tests") {
testonly = true
sources = [
"audio_encoder_opus_unittest.cc",
"codec_test.cc",
"codec_test.h",
"video_decoder_vpx_unittest.cc",
"video_encoder_helper_unittest.cc",
"video_encoder_verbatim_unittest.cc",
"video_encoder_vpx_unittest.cc",
]
deps = [
":codec",
"//base",
"//remoting/proto",
"//testing/gtest",
"//third_party/webrtc/modules/desktop_capture",
]
}
......@@ -4,15 +4,19 @@
import("//build/config/features.gni")
import("//build/config/ui.gni")
import("//remoting/remoting_version.gni")
import("//remoting/remoting_srcs.gni")
# This must be a static library instead of a source set because
# remoting_unittests requires that remoting_me2me_host.cc not be pulled in,
# which in turn depends on remoting_me2me_host_static which isn't part of that
# build.
#
# TODO fix this, successful builds should not depend on static libraries
# stripping code.
static_library("host") {
gypi_values = exec_script("//build/gypi_to_gn.py",
[ rebase_path("../remoting_host_srcs.gypi") ],
"scope",
[ "../remoting_host_srcs.gypi" ])
sources = rebase_path(gypi_values.remoting_host_sources, ".", "//remoting")
sources = rebase_path(remoting_host_srcs_gypi_values.remoting_host_sources,
".",
"//remoting")
libs = []
......@@ -40,15 +44,21 @@ static_library("host") {
if (use_x11) {
configs += [
#TODO : (kelvinp) Add GTK to the configs.
"//build/config/linux:x11",
"//build/config/linux:xrandr",
]
if (!is_chromeos) {
deps += [ "//build/config/linux/gtk" ]
}
} else {
sources -= [
"clipboard_x11.cc",
"linux/x_server_clipboard.cc",
"linux/x_server_clipboard.h",
]
sources -= [ "clipboard_x11.cc" ]
if (is_linux) {
# These will already be filtered out on non-Linux.
sources -= [
"linux/x_server_clipboard.cc",
"linux/x_server_clipboard.h",
]
}
}
if (is_chromeos) {
......@@ -88,10 +98,16 @@ static_library("host") {
}
if (is_mac) {
defines += [
"HOST_BUNDLE_NAME=\"$host_bundle_name\"",
"PREFPANE_BUNDLE_NAME=\"$prefpane_bundle_name\"",
]
# TODO(GYP) Mac host_bundle_name and prefpane_bundle_name.
# Note if you are looking at this: It really sucks to have to synchronously
# call into python twice to get these values. They should instead be
# written into a generated header via the process_version template, and we
# change the source files to include that header rather than rely on these
# defines being set in the build.
#defines += [
# "HOST_BUNDLE_NAME=\"$host_bundle_name\"",
# "PREFPANE_BUNDLE_NAME=\"$prefpane_bundle_name\"",
#]
libs += [
"Accelerate.framework",
......@@ -107,6 +123,116 @@ static_library("host") {
"//third_party/webrtc/modules/desktop_capture",
]
sources += rebase_path(gypi_values.remoting_cast_sources, ".", "//remoting")
sources += rebase_path(remoting_host_srcs_gypi_values.remoting_cast_sources,
".",
"//remoting")
}
}
source_set("test_support") {
testonly = true
sources = [
"fake_desktop_capturer.cc",
"fake_desktop_capturer.h",
"fake_desktop_environment.cc",
"fake_desktop_environment.h",
"fake_host_extension.cc",
"fake_host_extension.h",
"fake_host_status_monitor.h",
"fake_host_status_monitor.h",
"fake_mouse_cursor_monitor.cc",
"fake_mouse_cursor_monitor.h",
]
deps = [
"//remoting/proto",
]
public_deps = [
":host",
]
if (enable_webrtc) {
public_deps += [
"//third_party/libjingle:libpeerconnection",
"//third_party/webrtc/modules/desktop_capture",
]
}
}
# The host portions of the remoting unit tests.
source_set("unit_tests") {
testonly = true
sources = [
"audio_pump_unittest.cc",
"audio_silence_detector_unittest.cc",
"capture_scheduler_unittest.cc",
"chromeos/aura_desktop_capturer_unittest.cc",
"chromeos/clipboard_aura_unittest.cc",
"chromoting_host_context_unittest.cc",
"chromoting_host_unittest.cc",
"client_session_unittest.cc",
"config_file_watcher_unittest.cc",
"daemon_process_unittest.cc",
"desktop_process_unittest.cc",
"desktop_shape_tracker_unittest.cc",
"gnubby_auth_handler_posix_unittest.cc",
"heartbeat_sender_unittest.cc",
"host_change_notification_listener_unittest.cc",
"host_config_unittest.cc",
"host_extension_session_manager_unittest.cc",
"host_mock_objects.cc",
"host_status_logger_unittest.cc",
"ipc_desktop_environment_unittest.cc",
"it2me/it2me_confirmation_dialog_proxy_unittest.cc",
"it2me/it2me_native_messaging_host_unittest.cc",
"linux/audio_pipe_reader_unittest.cc",
"linux/unicode_to_keysym_unittest.cc",
"linux/x_server_clipboard_unittest.cc",
"local_input_monitor_unittest.cc",
"mouse_shape_pump_unittest.cc",
"native_messaging/native_messaging_reader_unittest.cc",
"native_messaging/native_messaging_writer_unittest.cc",
"pairing_registry_delegate_linux_unittest.cc",
"pairing_registry_delegate_win_unittest.cc",
"pin_hash_unittest.cc",
"policy_watcher_unittest.cc",
"register_support_host_request_unittest.cc",
"remote_input_filter_unittest.cc",
"resizing_host_observer_unittest.cc",
"screen_resolution_unittest.cc",
"server_log_entry_host_unittest.cc",
"setup/me2me_native_messaging_host_unittest.cc",
"setup/oauth_helper_unittest.cc",
"setup/pin_validator_unittest.cc",
"shaped_desktop_capturer_unittest.cc",
"token_validator_factory_impl_unittest.cc",
"video_frame_pump_unittest.cc",
"video_frame_recorder_unittest.cc",
"win/rdp_client_unittest.cc",
"win/worker_process_launcher.cc",
"win/worker_process_launcher.h",
"win/worker_process_launcher_unittest.cc",
]
if (use_ozone || is_chromeos) {
sources -= [ "local_input_monitor_unittest.cc" ]
}
if (is_chromeos) {
sources -= [ "linux/x_server_clipboard_unittest.cc" ]
}
deps = [
":host",
":test_support",
"//components/policy:policy_component_test_support",
"//remoting/host/setup",
"//remoting/host/it2me:common",
"//remoting/host/native_messaging",
"//remoting/proto",
"//skia",
"//testing/gmock",
"//testing/gtest",
]
}
......@@ -3,20 +3,18 @@
# found in the LICENSE file.
import("//build/config/features.gni")
import("//build/config/ui.gni")
import("//remoting/remoting_version.gni")
import("//remoting/remoting_srcs.gni")
static_library("common") {
gypi_values = exec_script("//build/gypi_to_gn.py",
[ rebase_path("../../remoting_host_srcs.gypi") ],
"scope",
[ "../../remoting_host_srcs.gypi" ])
source_set("common") {
sources = rebase_path(
remoting_host_srcs_gypi_values.remoting_it2me_host_static_sources,
".",
"//remoting")
sources = rebase_path(gypi_values.remoting_it2me_host_static_sources,
".",
"//remoting")
configs += [ "//build/config/compiler:wexit_time_destructors" ]
configs += [
"//build/config/compiler:wexit_time_destructors",
"//remoting:version",
]
deps = [
"//base:i18n",
......@@ -26,6 +24,4 @@ static_library("common") {
"//remoting/protocol",
"//remoting/resources",
]
defines = [ "VERSION=$version_full" ]
}
# Copyright 2015 The Chromium 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("//remoting/remoting_srcs.gni")
# GYP version: remoting/remoting_host.gypi:remoting_native_messaging_base
source_set("native_messaging") {
sources = rebase_path(
remoting_host_srcs_gypi_values.remoting_host_native_messaging_sources,
".",
"//remoting")
configs += [ "//build/config/compiler:wexit_time_destructors" ]
deps = [
"//base",
]
}
# Copyright 2015 The Chromium 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("//remoting/remoting_srcs.gni")
source_set("setup") {
sources =
rebase_path(remoting_host_srcs_gypi_values.remoting_host_setup_sources,
".",
"//remoting")
configs += [
# TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
"//build/config/compiler:no_size_t_to_int_warning",
"//build/config/compiler:wexit_time_destructors",
"//remoting:version",
]
deps = [
"//base",
"//google_apis",
"//remoting/host",
]
if (is_win) {
deps += [
#remoting_lib_idl", TODO(GYP) Windows target for remoting.
"//google_update",
]
}
}
......@@ -2,14 +2,12 @@
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
static_library("protocol") {
gypi_values = exec_script("//build/gypi_to_gn.py",
[ rebase_path("../remoting_srcs.gypi") ],
"scope",
[ "../remoting_srcs.gypi" ])
import("//remoting/remoting_srcs.gni")
sources =
rebase_path(gypi_values.remoting_protocol_sources, ".", "//remoting")
source_set("protocol") {
sources = rebase_path(remoting_srcs_gypi_values.remoting_protocol_sources,
".",
"//remoting")
configs += [
"//build/config/compiler:no_size_t_to_int_warning",
......@@ -17,6 +15,7 @@ static_library("protocol") {
]
public_deps = [
"//remoting/proto",
"//third_party/libjingle",
]
deps = [
......@@ -26,5 +25,67 @@ static_library("protocol") {
"//jingle:notifier",
"//net",
"//remoting/base",
"//remoting/codec",
]
}
source_set("test_support") {
testonly = true
sources = [
"fake_authenticator.cc",
"fake_authenticator.h",
"fake_datagram_socket.cc",
"fake_datagram_socket.h",
"fake_session.cc",
"fake_session.h",
"fake_stream_socket.cc",
"fake_stream_socket.h",
"protocol_mock_objects.cc",
"protocol_mock_objects.h",
]
public_deps = [
":protocol",
"//testing/gmock",
]
}
source_set("unit_tests") {
testonly = true
sources = [
"authenticator_test_base.cc",
"authenticator_test_base.h",
"channel_multiplexer_unittest.cc",
"chromium_socket_factory_unittest.cc",
"client_video_dispatcher_unittest.cc",
"clipboard_echo_filter_unittest.cc",
"clipboard_filter_unittest.cc",
"connection_tester.cc",
"connection_tester.h",
"connection_to_client_unittest.cc",
"content_description_unittest.cc",
"input_event_tracker_unittest.cc",
"input_filter_unittest.cc",
"jingle_messages_unittest.cc",
"jingle_session_unittest.cc",
"message_decoder_unittest.cc",
"message_reader_unittest.cc",
"monitored_video_stub_unittest.cc",
"mouse_input_filter_unittest.cc",
"negotiating_authenticator_unittest.cc",
"network_settings_unittest.cc",
"pairing_registry_unittest.cc",
"ppapi_module_stub.cc",
"ssl_hmac_channel_authenticator_unittest.cc",
"third_party_authenticator_unittest.cc",
"v2_authenticator_unittest.cc",
]
deps = [
":test_support",
"//testing/gmock",
"//testing/gtest",
]
}
......@@ -213,7 +213,7 @@
}, # end of target 'remoting_resources'
{
# GN version: //remoting/base
# GN version: //remoting/base and //remoting/codec
'target_name': 'remoting_base',
'type': 'static_library',
'variables': { 'enable_wexit_time_destructors': 1, },
......@@ -245,6 +245,7 @@
'hard_dependency': 1,
'sources': [
'<@(remoting_base_sources)',
'<@(remoting_codec_sources)',
],
}, # end of target 'remoting_base'
......
......@@ -211,6 +211,7 @@
}, # end of target 'remoting_host'
{
# GN version: //remoting/host/native_messaging
'target_name': 'remoting_native_messaging_base',
'type': 'static_library',
'variables': { 'enable_wexit_time_destructors': 1, },
......@@ -218,18 +219,12 @@
'../base/base.gyp:base',
],
'sources': [
'host/native_messaging/native_messaging_pipe.cc',
'host/native_messaging/native_messaging_pipe.h',
'host/native_messaging/native_messaging_reader.cc',
'host/native_messaging/native_messaging_reader.h',
'host/native_messaging/native_messaging_writer.cc',
'host/native_messaging/native_messaging_writer.h',
'host/native_messaging/pipe_messaging_channel.cc',
'host/native_messaging/pipe_messaging_channel.h',
'<@(remoting_host_native_messaging_sources)',
],
}, # end of target 'remoting_native_messaging_base'
{
# GN version: //remoting/host/setup
'target_name': 'remoting_host_setup_base',
'type': 'static_library',
'variables': { 'enable_wexit_time_destructors': 1, },
......@@ -242,28 +237,7 @@
'VERSION=<(version_full)',
],
'sources': [
'host/setup/daemon_controller.cc',
'host/setup/daemon_controller.h',
'host/setup/daemon_controller_delegate_linux.cc',
'host/setup/daemon_controller_delegate_linux.h',
'host/setup/daemon_controller_delegate_mac.h',
'host/setup/daemon_controller_delegate_mac.mm',
'host/setup/daemon_controller_delegate_win.cc',
'host/setup/daemon_controller_delegate_win.h',
'host/setup/me2me_native_messaging_host.cc',
'host/setup/me2me_native_messaging_host.h',
'host/setup/oauth_client.cc',
'host/setup/oauth_client.h',
'host/setup/oauth_helper.cc',
'host/setup/oauth_helper.h',
'host/setup/pin_validator.cc',
'host/setup/pin_validator.h',
'host/setup/service_client.cc',
'host/setup/service_client.h',
'host/setup/test_util.cc',
'host/setup/test_util.h',
'host/setup/win/auth_code_getter.cc',
'host/setup/win/auth_code_getter.h',
'<@(remoting_host_setup_sources)',
],
'conditions': [
['OS=="win"', {
......
......@@ -259,7 +259,41 @@
'host/win/wts_terminal_monitor.h',
'host/win/wts_terminal_observer.h',
],
'remoting_cast_sources' : [
'remoting_host_setup_sources': [
'host/setup/daemon_controller.cc',
'host/setup/daemon_controller.h',
'host/setup/daemon_controller_delegate_linux.cc',
'host/setup/daemon_controller_delegate_linux.h',
'host/setup/daemon_controller_delegate_mac.h',
'host/setup/daemon_controller_delegate_mac.mm',
'host/setup/daemon_controller_delegate_win.cc',
'host/setup/daemon_controller_delegate_win.h',
'host/setup/me2me_native_messaging_host.cc',
'host/setup/me2me_native_messaging_host.h',
'host/setup/oauth_client.cc',
'host/setup/oauth_client.h',
'host/setup/oauth_helper.cc',
'host/setup/oauth_helper.h',
'host/setup/pin_validator.cc',
'host/setup/pin_validator.h',
'host/setup/service_client.cc',
'host/setup/service_client.h',
'host/setup/test_util.cc',
'host/setup/test_util.h',
'host/setup/win/auth_code_getter.cc',
'host/setup/win/auth_code_getter.h',
],
'remoting_host_native_messaging_sources': [
'host/native_messaging/native_messaging_pipe.cc',
'host/native_messaging/native_messaging_pipe.h',
'host/native_messaging/native_messaging_reader.cc',
'host/native_messaging/native_messaging_reader.h',
'host/native_messaging/native_messaging_writer.cc',
'host/native_messaging/native_messaging_writer.h',
'host/native_messaging/pipe_messaging_channel.cc',
'host/native_messaging/pipe_messaging_channel.h',
],
'remoting_cast_sources': [
'host/cast_extension.cc',
'host/cast_extension.h',
'host/cast_extension_session.cc',
......
......@@ -116,6 +116,7 @@
'sources': [
'../ui/events/keycodes/dom4/keycode_converter.cc',
'<@(remoting_base_sources)',
'<@(remoting_codec_sources)',
'<@(remoting_client_plugin_sources)',
'<@(remoting_client_sources)',
'<@(remoting_protocol_sources)',
......
# Copyright 2015 The Chromium Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
remoting_srcs_gypi_values = exec_script("//build/gypi_to_gn.py",
[ rebase_path("remoting_srcs.gypi") ],
"scope",
[ "remoting_srcs.gypi" ])
remoting_host_srcs_gypi_values =
exec_script("//build/gypi_to_gn.py",
[ rebase_path("remoting_host_srcs.gypi") ],
"scope",
[ "remoting_host_srcs.gypi" ])
......@@ -41,6 +41,8 @@
'base/util.h',
'base/vlog_net_log.cc',
'base/vlog_net_log.h',
],
'remoting_codec_sources': [
'codec/audio_decoder.cc',
'codec/audio_decoder.h',
'codec/audio_decoder_opus.cc',
......
......@@ -5,6 +5,7 @@
{
'targets': [
{
# GN version: //remoting:test_support
'target_name': 'remoting_test_common',
'type': 'static_library',
'dependencies': [
......@@ -20,6 +21,7 @@
'remoting_resources',
],
'sources': [
# Note: sources list duplicated in GN build.
'host/fake_desktop_capturer.cc',
'host/fake_desktop_capturer.h',
'host/fake_desktop_environment.cc',
......@@ -71,6 +73,9 @@
# Remoting unit tests
{
# GN version: //remoting:remoting_unittests
# Note that many of the sources are broken out into subdir-specific unit
# test source set targets that then GN version then brings together.
'target_name': 'remoting_unittests',
'type': '<(gtest_target_type)',
'dependencies': [
......@@ -107,6 +112,7 @@
'../testing/gmock/include',
],
'sources': [
# Note: sources list duplicated in GN build.
'base/auto_thread_task_runner_unittest.cc',
'base/auto_thread_unittest.cc',
'base/breakpad_win_unittest.cc',
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment