Removing uses of X11 native key events.
[chromium-blink-merge.git] / content / child / BUILD.gn
blob1342dc90788f78b387b6fe3e3a2e5bb61a0aef8d
1 # Copyright 2014 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file.
5 import("//build/config/crypto.gni")
6 import("//build/config/features.gni")
7 import("//build/config/ui.gni")
8 import("//content/child/child.gni")
10 source_set("child") {
11   # Only the public target should depend on this. All other targets (even
12   # internal content ones) should depend on the public one.
13   visibility = [ "//content/public/child:child_sources" ]
15   sources = rebase_path(content_child_gypi_values.private_child_sources,
16                         ".", "//content")
18   deps = [
19     "//base",
20     "//components/tracing",
21     "//mojo/environment:chromium",
22     "//mojo/public/interfaces/application",
23     "//skia",
24     "//third_party/icu",
25     "//ui/base",
26     "//ui/gfx",
27     "//ui/gfx/geometry",
28     "//url",
29   ]
31   if (!use_default_render_theme) {
32     sources -= [
33       "webthemeengine_impl_default.cc",
34       "webthemeengine_impl_default.h",
35     ]
36   }
38   if (is_android) {
39     deps += [
40       "//third_party/android_tools:cpu_features",
41     ]
42   }
44   if (!enable_plugins) {
45     sources -= [
46       "browser_font_resource_trusted.cc",
47       "npapi/plugin_host.cc",
48       "npapi/plugin_host.h",
49       "npapi/plugin_instance.cc",
50       "npapi/plugin_instance.h",
51       "npapi/plugin_lib.cc",
52       "npapi/plugin_lib.h",
53       "npapi/plugin_stream.cc",
54       "npapi/plugin_stream.h",
55       "npapi/plugin_stream_posix.cc",
56       "npapi/plugin_stream_url.cc",
57       "npapi/plugin_stream_url.h",
58       "npapi/plugin_string_stream.cc",
59       "npapi/plugin_string_stream.h",
60       "npapi/plugin_url_fetcher.cc",
61       "npapi/plugin_url_fetcher.h",
62       "npapi/webplugin.h",
63       "npapi/webplugin_delegate.h",
64       "npapi/webplugin_delegate_impl.cc",
65       "npapi/webplugin_delegate_impl.h",
66       "npapi/webplugin_resource_client.h",
67     ]
69     if (is_mac) {
70       sources -= [
71         "npapi/plugin_instance_mac.mm",
72         "npapi/plugin_web_event_converter_mac.h",
73         "npapi/plugin_web_event_converter_mac.mm",
74         "npapi/webplugin_accelerated_surface_mac.h",
75         "npapi/webplugin_delegate_impl_mac.mm",
76       ]
77     } else if (is_win) {
78       sources -= [
79         "npapi/plugin_stream_win.cc",
80         "npapi/webplugin_delegate_impl_win.cc",
81         "npapi/webplugin_ime_win.cc",
82         "npapi/webplugin_ime_win.h",
83       ]
84     } else if (is_android) {
85       sources -= [
86         "npapi/webplugin_delegate_impl_android.cc",
87       ]
88     }
89     if (use_aura) {
90       sources -= [
91         "npapi/webplugin_delegate_impl_aura.cc",
92       ]
93     }
94   }
96   configs += [
97     "//content:content_implementation",
98   ]
100   if (is_ios) {
101     # iOS only needs a small portion of content; exclude all the
102     # implementation, and re-include what is used.
103     sources = []
104   } else {
105     deps += [
106       "//content/app/resources",
107       "//content/app/strings",
108       "//crypto:platform",
109       "//storage/common",
110       "//third_party/WebKit/public:blink",
111       "//third_party/WebKit/public:resources",
112       "//third_party/npapi",
113     ]
114   }
116   if (use_aura && is_mac) {
117     # This file is already excluded on non-Mac.
118     sources -= [ "npapi/webplugin_delegate_impl_mac.mm" ]
119   }
121   if (is_win || !use_aura) {
122     sources -= [ "npapi/webplugin_delegate_impl_aura.cc" ]
123   }
125   if (!use_openssl) {
126     sources += rebase_path(content_child_gypi_values.webcrypto_nss_sources,
127                            ".", "//content")
128   } else {
129     sources += rebase_path(content_child_gypi_values.webcrypto_openssl_sources,
130                            ".", "//content")
131   }