electron/chromium_src/BUILD.gn

141 lines
5.1 KiB
Text
Raw Normal View History

# Copyright (c) 2018 GitHub, Inc.
# Use of this source code is governed by the MIT license that can be
# found in the LICENSE file.
import("//build/config/ui.gni")
import("//electron/buildflags/buildflags.gni")
import("//third_party/widevine/cdm/widevine.gni")
# Builds some of the chrome sources that Electron depends on.
static_library("chrome") {
visibility = [ "//electron:electron_lib" ]
sources = [
"//chrome/browser/browser_process.cc",
"//chrome/browser/browser_process.h",
"//chrome/browser/devtools/devtools_contents_resizing_strategy.cc",
"//chrome/browser/devtools/devtools_contents_resizing_strategy.h",
"//chrome/browser/devtools/devtools_embedder_message_dispatcher.cc",
"//chrome/browser/devtools/devtools_embedder_message_dispatcher.h",
"//chrome/browser/devtools/devtools_file_system_indexer.cc",
"//chrome/browser/devtools/devtools_file_system_indexer.h",
"//chrome/browser/extensions/global_shortcut_listener.cc",
"//chrome/browser/extensions/global_shortcut_listener.h",
"//chrome/browser/extensions/global_shortcut_listener_mac.h",
"//chrome/browser/extensions/global_shortcut_listener_mac.mm",
"//chrome/browser/extensions/global_shortcut_listener_win.cc",
"//chrome/browser/extensions/global_shortcut_listener_win.h",
"//chrome/browser/icon_loader.cc",
"//chrome/browser/icon_loader.h",
"//chrome/browser/icon_loader_mac.mm",
"//chrome/browser/icon_loader_win.cc",
"//chrome/browser/icon_manager.cc",
"//chrome/browser/icon_manager.h",
"//chrome/browser/net/chrome_mojo_proxy_resolver_factory.cc",
"//chrome/browser/net/chrome_mojo_proxy_resolver_factory.h",
"//chrome/browser/net/chrome_net_log_helper.cc",
"//chrome/browser/net/chrome_net_log_helper.h",
"//chrome/browser/net/proxy_config_monitor.cc",
"//chrome/browser/net/proxy_config_monitor.h",
"//chrome/browser/net/proxy_service_factory.cc",
"//chrome/browser/net/proxy_service_factory.h",
"//chrome/browser/ssl/security_state_tab_helper.cc",
"//chrome/browser/ssl/security_state_tab_helper.h",
"//extensions/browser/app_window/size_constraints.cc",
"//extensions/browser/app_window/size_constraints.h",
]
public_deps = [
"//content/public/browser",
]
deps = [
"//chrome/common",
"//components/keyed_service/content",
"//components/proxy_config",
"//components/security_state/content",
]
if (is_linux) {
sources += [ "//chrome/browser/icon_loader_auralinux.cc" ]
sources += [
"//chrome/browser/extensions/global_shortcut_listener_x11.cc",
"//chrome/browser/extensions/global_shortcut_listener_x11.h",
]
}
if (enable_desktop_capturer) {
sources += [
"//chrome/browser/media/webrtc/desktop_media_list.h",
"//chrome/browser/media/webrtc/desktop_media_list_base.cc",
"//chrome/browser/media/webrtc/desktop_media_list_base.h",
"//chrome/browser/media/webrtc/desktop_media_list_observer.h",
"//chrome/browser/media/webrtc/native_desktop_media_list.cc",
"//chrome/browser/media/webrtc/native_desktop_media_list.h",
]
deps += [ "//ui/snapshot" ]
}
if (enable_color_chooser) {
sources += [
"//chrome/browser/platform_util.cc",
"//chrome/browser/platform_util.h",
"//chrome/browser/ui/browser_dialogs.h",
]
if (use_aura) {
sources += [
"//chrome/browser/platform_util_aura.cc",
"//chrome/browser/ui/views/color_chooser_aura.cc",
"//chrome/browser/ui/views/color_chooser_aura.h",
]
}
if (is_mac) {
sources += [
"//chrome/browser/ui/cocoa/color_chooser_mac.h",
"//chrome/browser/ui/cocoa/color_chooser_mac.mm",
]
}
if (is_win) {
sources += [
"//chrome/browser/ui/views/color_chooser_dialog.cc",
"//chrome/browser/ui/views/color_chooser_dialog.h",
"//chrome/browser/ui/views/color_chooser_win.cc",
]
}
}
if (enable_tts) {
sources += [
"//chrome/browser/speech/tts_controller.h",
"//chrome/browser/speech/tts_controller_impl.cc",
"//chrome/browser/speech/tts_controller_impl.h",
"//chrome/browser/speech/tts_mac.mm",
"//chrome/browser/speech/tts_message_filter.cc",
"//chrome/browser/speech/tts_message_filter.h",
"//chrome/browser/speech/tts_platform.cc",
"//chrome/browser/speech/tts_platform.h",
"//chrome/browser/speech/tts_win.cc",
"//chrome/common/tts_messages.h",
"//chrome/common/tts_utterance_request.cc",
"//chrome/common/tts_utterance_request.h",
"//chrome/renderer/tts_dispatcher.cc",
"//chrome/renderer/tts_dispatcher.h",
]
if (is_linux) {
sources += [ "//chrome/browser/speech/tts_linux.cc" ]
deps += [ "//third_party/speech-dispatcher" ]
}
}
if (enable_widevine) {
sources += [
"//chrome/renderer/media/chrome_key_systems.cc",
"//chrome/renderer/media/chrome_key_systems.h",
"//chrome/renderer/media/chrome_key_systems_provider.cc",
"//chrome/renderer/media/chrome_key_systems_provider.h",
]
deps += [ "//components/cdm/renderer" ]
}
}