blob: ce32356b65b7fd059574f86bc721994ad634f3a7 [file] [log] [blame]
[email protected]77ce8022014-06-16 19:29:561# 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.
4
brettw2b2364b2015-05-01 22:36:235import("//build/config/chrome_build.gni")
[email protected]dffd8a912014-06-30 23:24:316import("//build/config/crypto.gni")
7import("//build/config/features.gni")
8import("//build/config/ui.gni")
pkotwicz127726f2015-05-29 15:20:129import("//third_party/protobuf/proto_library.gni")
scottmga266f952014-12-03 20:47:1010
James Robinson2ed4d692014-09-17 05:20:5811# //build/config/android/rules.gni imports //tools/grit/grit_rule.gni, which
12# produces a conflict for the "grit" template so we have to only include one.
13if (is_android) {
14 import("//build/config/android/rules.gni")
15} else {
16 import("//tools/grit/grit_rule.gni")
17}
cmasone0a9e4ca2014-10-16 16:40:4918if (is_desktop_linux) {
19 import("//build/config/linux/pkg_config.gni")
20}
[email protected]77ce8022014-06-16 19:29:5621
amistryf269d3b2015-06-09 19:18:3922declare_args() {
mgiuca0366a512015-06-24 05:41:3323 # 'Ok Google' hotwording is disabled by default in open source builds. Set to
24 # true to enable. (This will download a closed-source NaCl module at startup.)
25 # Chrome-branded builds have this enabled by default.
26 enable_hotwording = is_chrome_branded
amistryf269d3b2015-06-09 19:18:3927}
28
[email protected]77ce8022014-06-16 19:29:5629about_credits_file = "$target_gen_dir/about_credits.html"
30additional_modules_list_file =
31 "$root_gen_dir/chrome/browser/internal/additional_modules_list.txt"
32
scottmga266f952014-12-03 20:47:1033gypi_values = exec_script("//build/gypi_to_gn.py",
34 [ rebase_path("../chrome_browser.gypi") ],
35 "scope",
36 [ "../chrome_browser.gypi" ])
[email protected]dffd8a912014-06-30 23:24:3137
cmasone0a9e4ca2014-10-16 16:40:4938if (is_desktop_linux) {
brettwa68ea2b2015-02-01 02:54:0739 # Gnome-keyring is normally dynamically loaded. The gnome_keyring config
40 # will set this up.
cmasone0a9e4ca2014-10-16 16:40:4941 pkg_config("gnome_keyring") {
42 packages = [ "gnome-keyring-1" ]
brettwa68ea2b2015-02-01 02:54:0743 defines = [
44 "USE_GNOME_KEYRING",
45 "DLOPEN_GNOME_KEYRING",
46 ]
47 ignore_libs = true
48 }
49
50 # If you want to link gnome-keyring directly (use only for unit tests)
51 # ADDITIONALLY add this config on top of ":gnome_keyring". pkg-config is a
52 # bit slow, so prefer not to run it again. In practice, gnome-keyring's libs
53 # are just itself and common gnome ones we link already, so we can get away
54 # with additionally just coding the library name here.
55 config("gnome_keyring_direct") {
56 libs = [ "gnome-keyring" ]
cmasone0a9e4ca2014-10-16 16:40:4957 }
58}
59
brettw44a5cf82015-04-08 19:48:2260source_set("browser") {
apavlove749bca2014-09-30 11:07:4161 configs += [
62 "//build/config/compiler:wexit_time_destructors",
63 "//third_party/WebKit/public:debug_devtools",
64 ]
[email protected]dffd8a912014-06-30 23:24:3165 defines = []
66 sources = []
67 libs = []
68 ldflags = []
69
70 # iOS/non-iOS shared deps. New dependencies should generally be added in the
71 # non-iOS deps below.
Brett Wilsone53895272014-09-23 23:41:4672 public_deps = [
73 "//components/autofill/core/browser",
74 "//content/public/browser",
75 "//sql",
76 "//sync",
77 ]
[email protected]dffd8a912014-06-30 23:24:3178 deps = [
79 "//base/allocator",
80 "//chrome:extra_resources",
81 "//chrome:resources",
82 "//chrome:strings",
[email protected]797b25042014-07-01 23:54:1783 "//chrome/app:generated_resources_map",
[email protected]855b7de2014-07-08 21:02:4584 "//chrome/app/resources:platform_locale_settings",
[email protected]797b25042014-07-01 23:54:1785 "//chrome/app/theme:theme_resources",
estark4282f1172015-05-13 22:01:5586 "//chrome/browser/net:encrypted_cert_logger_proto",
[email protected]797b25042014-07-01 23:54:1787 "//chrome/browser/net:probe_message_proto",
fgorskife7b92f2015-06-15 19:19:4088 "//chrome/browser/offline_pages:offline_pages_proto",
estark4282f1172015-05-13 22:01:5589 "//chrome/browser/ssl:cert_logger_proto",
[email protected]abd4b682014-07-16 20:26:3090 "//chrome/browser/ui",
[email protected]dffd8a912014-06-30 23:24:3191 "//chrome/common",
92 "//chrome/common/net",
[email protected]604828c2014-07-02 20:39:1293 "//components/autofill/core/browser",
Brett Wilson1c693992014-08-25 19:10:0194 "//components/bookmarks/browser",
treiba9ea2fb2015-03-20 10:06:0395 "//components/bookmarks/managed",
[email protected]b9f4c682014-07-10 22:00:3796 "//components/captive_portal",
[email protected]fca567b2014-07-02 17:37:3497 "//components/cloud_devices/common",
Brett Wilson1c693992014-08-25 19:10:0198 "//components/component_updater",
vabrfc325fa2015-04-10 16:24:4599 "//components/content_settings/content/common",
vasiliiac461392014-09-18 11:35:17100 "//components/content_settings/core/browser",
[email protected]08f71012014-07-25 10:27:54101 "//components/content_settings/core/common",
[email protected]478ed232014-08-19 02:10:55102 "//components/crx_file",
megjablon3476e042014-10-14 19:21:59103 "//components/data_reduction_proxy/core/browser",
reillyg4a849272015-02-20 21:38:43104 "//components/device_event_log",
[email protected]273ae5ab2014-07-09 21:10:25105 "//components/domain_reliability",
noyaudaaac3a2014-10-08 11:11:11106 "//components/enhanced_bookmarks",
sdefresnecbacfd72015-03-20 12:11:32107 "//components/favicon/core",
sdefresne001b10de2015-03-20 18:41:46108 "//components/favicon_base",
[email protected]abd4b682014-07-16 20:26:30109 "//components/gcm_driver",
jianli2104ce612015-05-06 00:24:34110 "//components/gcm_driver/instance_id",
Brett Wilson1c693992014-08-25 19:10:01111 "//components/google/core/browser",
fsamuelaf5bf6d12015-05-28 16:29:54112 "//components/guest_view/browser",
erikchen332265b2014-11-14 19:59:52113 "//components/handoff",
[email protected]273ae5ab2014-07-09 21:10:25114 "//components/history/core/browser",
115 "//components/history/core/common",
Brett Wilson1c693992014-08-25 19:10:01116 "//components/infobars/core",
knn062cdbb2015-06-26 18:18:42117 "//components/invalidation/impl",
gunsch1afc65172014-09-16 00:03:32118 "//components/metrics:gpu",
[email protected]fca567b2014-07-02 17:37:34119 "//components/metrics:net",
gunsch840bc412014-09-18 19:38:06120 "//components/metrics:profiler",
Brett Wilson1c693992014-08-25 19:10:01121 "//components/metrics/proto:proto",
rsleevic327b48f82015-04-30 02:03:25122 "//components/mime_util",
[email protected]fca567b2014-07-02 17:37:34123 "//components/navigation_metrics",
Brett Wilson1c693992014-08-25 19:10:01124 "//components/network_time",
fgorskife7b92f2015-06-15 19:19:40125 "//components/offline_pages",
[email protected]b1c5ab682014-08-07 11:53:17126 "//components/omnibox",
[email protected]fca567b2014-07-02 17:37:34127 "//components/os_crypt",
haavardmdfdf28f2015-01-08 21:05:00128 "//components/packed_ct_ev_whitelist",
Brett Wilson1c693992014-08-25 19:10:01129 "//components/password_manager/core/browser",
130 "//components/password_manager/core/common",
[email protected]fca567b2014-07-02 17:37:34131 "//components/policy:policy_component",
stevenjbb237e2ae2015-07-02 22:02:11132 "//components/proxy_config",
[email protected]fca567b2014-07-02 17:37:34133 "//components/query_parser",
[email protected]b9f4c682014-07-10 22:00:37134 "//components/rappor",
Brett Wilson1c693992014-08-25 19:10:01135 "//components/renderer_context_menu",
[email protected]720b10492014-07-23 08:48:40136 "//components/search",
Brett Wilson1c693992014-08-25 19:10:01137 "//components/search_engines",
138 "//components/search_provider_logos",
[email protected]abd4b682014-07-16 20:26:30139 "//components/signin/core/browser",
140 "//components/startup_metric_utils",
[email protected]797b25042014-07-01 23:54:17141 "//components/strings",
mathp60143a32014-10-08 14:52:45142 "//components/suggestions",
Brett Wilson1c693992014-08-25 19:10:01143 "//components/sync_driver",
[email protected]b9f4c682014-07-10 22:00:37144 "//components/translate/core/browser",
145 "//components/translate/core/common",
wjmaclean7f63c6b2014-12-09 14:59:55146 "//components/ui/zoom:ui_zoom",
sdefresnec083d1f2015-04-17 21:12:18147 "//components/undo",
sorin39eab2f2015-01-06 01:09:08148 "//components/update_client",
[email protected]273ae5ab2014-07-09 21:10:25149 "//components/url_fixer",
[email protected]fca567b2014-07-02 17:37:34150 "//components/user_prefs",
isherman3be67db2014-10-24 05:57:44151 "//components/variations",
152 "//components/variations/net",
[email protected]bf4545f2014-07-11 19:49:46153 "//components/webdata/common",
sdefresnecb955cd2014-12-15 23:21:56154 "//components/webdata_services",
drogerf8479942014-11-21 17:47:53155 "//components/web_resource",
[email protected]dffd8a912014-06-30 23:24:31156 "//content/public/browser",
157 "//content/public/common",
[email protected]604828c2014-07-02 20:39:12158 "//courgette:courgette_lib",
[email protected]dffd8a912014-06-30 23:24:31159 "//crypto",
[email protected]604828c2014-07-02 20:39:12160 "//google_apis",
Brett Wilson8f1323042014-09-11 16:58:56161 "//gpu/config",
[email protected]dffd8a912014-06-30 23:24:31162 "//skia",
163 "//sql",
164 "//sync",
[email protected]797b25042014-07-01 23:54:17165 "//third_party/cacheinvalidation",
[email protected]dffd8a912014-06-30 23:24:31166 "//third_party/icu",
167 "//third_party/libxml",
ajwongf7b1cb692014-08-23 21:36:22168 "//third_party/libjingle",
[email protected]dffd8a912014-06-30 23:24:31169 "//third_party/widevine/cdm:version_h",
170 "//third_party/zlib",
171 "//third_party/zlib:minizip",
172 "//third_party/zlib:zip",
173 "//ui/base",
cjhopman09981a92014-10-27 17:11:18174 "//ui/events:events_base",
[email protected]dffd8a912014-06-30 23:24:31175 "//ui/gfx",
176 "//ui/gfx/geometry",
[email protected]a1d7d4f2014-07-16 21:33:36177 "//ui/message_center",
178 "//ui/shell_dialogs",
[email protected]dffd8a912014-06-30 23:24:31179 "//ui/strings",
[email protected]797b25042014-07-01 23:54:17180 "//ui/resources",
[email protected]dffd8a912014-06-30 23:24:31181 ]
182
scottmga266f952014-12-03 20:47:10183 sources +=
184 rebase_path(gypi_values.chrome_browser_undo_sources, ".", "//chrome")
danduongd81789642014-09-23 02:50:00185
[email protected]dffd8a912014-06-30 23:24:31186 if (!is_ios) {
scottmga266f952014-12-03 20:47:10187 sources +=
188 rebase_path(gypi_values.chrome_browser_non_ios_sources, ".", "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59189 sources += rebase_path(gypi_values.chrome_browser_autocomplete_sources,
scottmga266f952014-12-03 20:47:10190 ".",
191 "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59192 sources += rebase_path(gypi_values.chrome_browser_bookmark_sources,
scottmga266f952014-12-03 20:47:10193 ".",
194 "//chrome")
stuartmorgan997cf23d2014-12-04 21:01:18195 sources += rebase_path(gypi_values.chrome_browser_browser_process_sources,
196 ".",
197 "//chrome")
198 sources += rebase_path(gypi_values.chrome_browser_content_settings_sources,
199 ".",
200 "//chrome")
benwellsedf5e082015-04-23 02:45:14201 sources += rebase_path(gypi_values.chrome_browser_engagement_sources,
202 ".",
203 "//chrome")
scottmga266f952014-12-03 20:47:10204 sources +=
205 rebase_path(gypi_values.chrome_browser_favicon_sources, ".", "//chrome")
206 sources +=
207 rebase_path(gypi_values.chrome_browser_google_sources, ".", "//chrome")
208 sources +=
209 rebase_path(gypi_values.chrome_browser_history_sources, ".", "//chrome")
210 sources +=
211 rebase_path(gypi_values.chrome_browser_metrics_sources, ".", "//chrome")
212 sources +=
213 rebase_path(gypi_values.chrome_browser_net_sources, ".", "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59214 sources += rebase_path(gypi_values.chrome_browser_password_manager_sources,
scottmga266f952014-12-03 20:47:10215 ".",
216 "//chrome")
mlamouri4e372022015-03-29 14:51:06217 sources += rebase_path(gypi_values.chrome_browser_permissions_sources,
218 ".",
219 "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59220 sources += rebase_path(gypi_values.chrome_browser_predictor_sources,
scottmga266f952014-12-03 20:47:10221 ".",
222 "//chrome")
223 sources +=
224 rebase_path(gypi_values.chrome_browser_pref_sources, ".", "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59225 sources += rebase_path(gypi_values.chrome_browser_profiles_sources,
scottmga266f952014-12-03 20:47:10226 ".",
227 "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59228 sources += rebase_path(gypi_values.chrome_browser_search_engines_sources,
scottmga266f952014-12-03 20:47:10229 ".",
230 "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59231 sources += rebase_path(gypi_values.chrome_browser_services_sources,
scottmga266f952014-12-03 20:47:10232 ".",
233 "//chrome")
234 sources +=
stuartmorgan997cf23d2014-12-04 21:01:18235 rebase_path(gypi_values.chrome_browser_session_sources, ".", "//chrome")
236 sources +=
scottmga266f952014-12-03 20:47:10237 rebase_path(gypi_values.chrome_browser_signin_sources, ".", "//chrome")
238 sources +=
stuartmorgan997cf23d2014-12-04 21:01:18239 rebase_path(gypi_values.chrome_browser_ssl_sources, ".", "//chrome")
240 sources +=
scottmga266f952014-12-03 20:47:10241 rebase_path(gypi_values.chrome_browser_sync_sources, ".", "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59242 sources += rebase_path(gypi_values.chrome_browser_web_resource_sources,
scottmga266f952014-12-03 20:47:10243 ".",
244 "//chrome")
245
[email protected]dffd8a912014-06-30 23:24:31246 deps += [
Brett Wilson1c693992014-08-25 19:10:01247 "//apps",
[email protected]dffd8a912014-06-30 23:24:31248 "//cc",
brettwca934582015-02-24 21:50:27249 "//chrome/app:generated_resources_map",
250 "//chrome/app/theme:theme_resources",
[email protected]55699f392014-08-20 22:16:30251 "//chrome/browser/devtools",
brettwca934582015-02-24 21:50:27252 "//chrome/browser/resources:component_extension_resources",
[email protected]55699f392014-08-20 22:16:30253 "//chrome/installer/util",
oshimaf65398422014-11-18 23:30:42254 "//components/app_modal",
[email protected]b9f4c682014-07-10 22:00:37255 "//components/autofill/content/browser",
lazyboy14082d22015-04-02 01:04:58256 "//components/browsing_data",
jeremyim364ac1182015-03-03 18:49:43257 "//components/data_reduction_proxy/content/browser",
dgozmanec2b982a2015-04-28 10:36:39258 "//components/devtools_discovery",
dgozman102fee92015-04-20 15:45:46259 "//components/devtools_http_handler",
[email protected]b9f4c682014-07-10 22:00:37260 "//components/dom_distiller/content",
sdefresne001b10de2015-03-20 18:41:46261 "//components/favicon/content",
sdefresne715246622015-01-12 16:24:04262 "//components/history/content/browser",
[email protected]fca567b2014-07-02 17:37:34263 "//components/keyed_service/content",
[email protected]55699f392014-08-20 22:16:30264 "//components/navigation_interception",
265 "//components/password_manager/content/browser",
dbeam155ac972015-04-20 15:34:48266 "//components/plugins/common",
bauerbf0e64aa2015-06-25 15:54:07267 "//components/safe_json",
brettwa22cb3b2015-04-30 20:23:12268 "//components/sessions",
[email protected]abd4b682014-07-16 20:26:30269 "//components/storage_monitor",
[email protected]b9f4c682014-07-10 22:00:37270 "//components/translate/content/browser",
[email protected]fca567b2014-07-02 17:37:34271 "//components/url_matcher",
[email protected]dffd8a912014-06-30 23:24:31272 "//components/visitedlink/browser",
273 "//components/visitedlink/common",
hanxi149b92d2014-09-11 21:57:18274 "//components/web_cache/browser",
[email protected]b9f4c682014-07-10 22:00:37275 "//components/web_modal",
[email protected]a9ca8d52014-08-22 10:21:08276 "//content/app/resources",
[email protected]55699f392014-08-20 22:16:30277 "//media",
rockot50dc5692015-07-08 01:57:26278 "//mojo/application/public/cpp",
cjhopman09981a92014-10-27 17:11:18279 "//mojo/common",
[email protected]604828c2014-07-02 20:39:12280 "//mojo/environment:chromium",
Brett Wilson83fd4242014-09-02 19:45:33281 "//net:extras",
[email protected]dffd8a912014-06-30 23:24:31282 "//net:net_with_v8",
pilgrim4af8c212014-09-05 17:30:15283 "//storage/browser",
pilgrimf55d19fc2014-09-04 00:05:24284 "//storage/common",
erga3c614c92015-04-03 17:47:51285 "//third_party/WebKit/public:image_resources",
[email protected]4eebe74d2014-08-13 02:54:46286 "//third_party/WebKit/public:resources",
[email protected]dffd8a912014-06-30 23:24:31287 "//third_party/expat",
288 "//third_party/leveldatabase",
[email protected]fca567b2014-07-02 17:37:34289 "//third_party/libaddressinput",
[email protected]dffd8a912014-06-30 23:24:31290 "//third_party/libyuv",
blundell70fb547672015-01-19 17:18:33291 "//third_party/mojo/src/mojo/edk/system",
292 "//third_party/mojo/src/mojo/public/cpp/bindings",
293 "//third_party/mojo/src/mojo/public/js",
[email protected]dffd8a912014-06-30 23:24:31294 "//third_party/re2",
295 "//third_party/smhasher:cityhash",
Brett Wilson83fd4242014-09-02 19:45:33296 "//third_party/webrtc/modules/desktop_capture",
spang1c36fac2015-02-05 19:55:12297 "//ui/base/ime",
[email protected]dffd8a912014-06-30 23:24:31298 "//ui/gl",
brettwca934582015-02-24 21:50:27299 "//ui/resources",
[email protected]dffd8a912014-06-30 23:24:31300 "//ui/surface",
[email protected]604828c2014-07-02 20:39:12301 "//ui/web_dialogs",
[email protected]fca567b2014-07-02 17:37:34302 "//v8",
[email protected]dffd8a912014-06-30 23:24:31303 ]
paulmeyer27b328b2015-06-17 21:26:12304
305 if (toolkit_views) {
306 deps += [ "//ui/views" ]
307 }
[email protected]dffd8a912014-06-30 23:24:31308 } else { # iOS
scottmga266f952014-12-03 20:47:10309 sources +=
310 rebase_path(gypi_values.chrome_browser_ios_sources, ".", "//chrome")
311 sources +=
312 rebase_path(gypi_values.chrome_browser_google_sources, ".", "//chrome")
313 deps += [ "//net" ]
[email protected]dffd8a912014-06-30 23:24:31314 libs += [
315 "CoreTelephony.framework",
316 "CoreText.framework",
317 "MobileCoreServices.framework",
318 "QuartzCore.framework",
319 ]
scottmga266f952014-12-03 20:47:10320 ldflags += [
321 "-weak_framework",
322 "CoreImage",
323 ]
[email protected]dffd8a912014-06-30 23:24:31324 }
325
326 if (is_win || is_mac) {
scottmga266f952014-12-03 20:47:10327 sources +=
328 rebase_path(gypi_values.chrome_browser_win_mac_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31329 }
330 if (!is_android && !is_ios && !is_chromeos && enable_configuration_policy) {
331 sources += [
332 "net/disk_cache_dir_policy_handler.cc",
333 "net/disk_cache_dir_policy_handler.h",
334 ]
335 }
336 if (!is_android && !is_ios && enable_configuration_policy) {
337 sources += [
338 "download/download_dir_policy_handler.cc",
339 "download/download_dir_policy_handler.h",
340 ]
341 }
342 if (is_mac) {
scottmga266f952014-12-03 20:47:10343 sources +=
344 rebase_path(gypi_values.chrome_browser_mac_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31345 deps += [
346 #"app_shim" TODO(GYP)
tapted63829f72014-09-24 23:50:50347 #"browser_app_shim" TODO(GYP)
[email protected]dffd8a912014-06-30 23:24:31348 ]
349 }
[email protected]dffd8a912014-06-30 23:24:31350 if (enable_extensions) {
Brett Wilsone53895272014-09-23 23:41:46351 public_deps += [ "//chrome/browser/extensions" ]
[email protected]cc5b3be2014-08-15 23:24:52352 deps += [
[email protected]cc5b3be2014-08-15 23:24:52353 "//chrome/browser/sync_file_system/drive_backend:sync_file_system_drive_proto",
thestige33aa2422014-09-22 22:16:30354 "//chrome/common/extensions/api",
355 "//chrome/common/extensions/api:api_registration",
msarda4c408ff2015-04-22 14:27:56356 "//components/proximity_auth/ble",
tengs4758c082014-12-19 18:51:44357 "//components/proximity_auth/cryptauth",
oshima758abebc2014-11-06 10:55:50358 "//extensions/components/javascript_dialog_extensions_client",
thestig73f4cdc2015-01-15 01:51:06359 "//media/cast:net",
[email protected]cc5b3be2014-08-15 23:24:52360 ]
[email protected]dffd8a912014-06-30 23:24:31361 sources += rebase_path(gypi_values.chrome_browser_extensions_sources,
scottmga266f952014-12-03 20:47:10362 ".",
363 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31364 }
365 if (enable_background) {
366 sources += rebase_path(gypi_values.chrome_browser_background_sources,
scottmga266f952014-12-03 20:47:10367 ".",
368 "//chrome")
jamesr29ea2d122014-10-23 10:30:27369 if (!use_aura || is_win || is_chromeos) {
[email protected]dffd8a912014-06-30 23:24:31370 sources -= [ "background/background_mode_manager_aura.cc" ]
371 }
372 }
373 if (enable_task_manager) {
374 sources += rebase_path(gypi_values.chrome_browser_task_manager_sources,
scottmga266f952014-12-03 20:47:10375 ".",
376 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31377 }
378 if (enable_spellcheck) {
379 sources += rebase_path(gypi_values.chrome_browser_spellchecker_sources,
scottmga266f952014-12-03 20:47:10380 ".",
381 "//chrome")
tfarinae4a03f8f2015-05-18 05:55:26382 deps += [ "//third_party/hunspell" ]
[email protected]dffd8a912014-06-30 23:24:31383 }
384 if (enable_nacl) {
scottmga266f952014-12-03 20:47:10385 sources +=
386 rebase_path(gypi_values.chrome_browser_nacl_sources, ".", "//chrome")
dpranke6065cf72015-02-26 03:30:58387 deps += [ "//components/nacl:nacl_browser" ]
[email protected]dffd8a912014-06-30 23:24:31388 }
apavlove749bca2014-09-30 11:07:41389
[email protected]dffd8a912014-06-30 23:24:31390 if (enable_configuration_policy) {
scottmga266f952014-12-03 20:47:10391 sources +=
392 rebase_path(gypi_values.chrome_browser_policy_shared_with_ios_sources,
393 ".",
394 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31395 deps += [
[email protected]604828c2014-07-02 20:39:12396 "//components/policy",
[email protected]797b25042014-07-01 23:54:17397 "//components/policy/proto",
[email protected]dffd8a912014-06-30 23:24:31398 ]
399 if (!is_ios) {
scottmga266f952014-12-03 20:47:10400 sources += rebase_path(gypi_values.chrome_browser_policy_non_ios_sources,
401 ".",
402 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31403 }
404 if (!is_chromeos) {
405 sources += rebase_path(
scottmga266f952014-12-03 20:47:10406 gypi_values.chrome_browser_policy_shared_with_ios_not_chromeos_sources,
407 ".",
408 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31409 }
410 if (is_win || is_mac || is_desktop_linux) {
411 sources += rebase_path(gypi_values.chrome_browser_policy_desktop_sources,
scottmga266f952014-12-03 20:47:10412 ".",
413 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31414 }
cjhopman09981a92014-10-27 17:11:18415 if (is_android || is_ios) {
416 sources += rebase_path(gypi_values.chrome_browser_policy_mobile_sources,
scottmga266f952014-12-03 20:47:10417 ".",
418 "//chrome")
cjhopman09981a92014-10-27 17:11:18419 } else {
amistry6e1ed1b2015-03-12 05:24:01420 deps += [
421 "//chrome/browser/policy:path_parser",
422 "//net:net_browser_services",
423 ]
[email protected]dffd8a912014-06-30 23:24:31424 }
425 } else {
426 # Configuration policy disabled.
427 sources += rebase_path(gypi_values.chrome_browser_policy_disabled_sources,
scottmga266f952014-12-03 20:47:10428 ".",
429 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31430 }
431
432 if (enable_plugins) {
scottmga266f952014-12-03 20:47:10433 sources +=
434 rebase_path(gypi_values.chrome_browser_plugins_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31435 deps += [
James Robinson2ed4d692014-09-17 05:20:58436 "//components/pdf/browser",
brettwf7eb6ca2015-02-14 01:37:31437 "//ppapi/proxy:ipc",
thestig11b815e92014-08-26 00:32:14438 "//third_party/adobe/flash:flapper_version_h",
[email protected]dffd8a912014-06-30 23:24:31439 ]
440 }
441 if (safe_browsing_mode != 0) {
scottmga266f952014-12-03 20:47:10442 sources +=
stuartmorgan1b3df822014-12-08 14:36:11443 rebase_path(gypi_values.chrome_browser_safe_browsing_basic_sources,
scottmga266f952014-12-03 20:47:10444 ".",
445 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31446 deps += [
[email protected]fca567b2014-07-02 17:37:34447 "//chrome/browser/safe_browsing:chunk_proto",
mattm022138b52014-09-23 01:05:45448 "//chrome/browser/safe_browsing:metadata_proto",
[email protected]fca567b2014-07-02 17:37:34449 "//chrome/browser/safe_browsing:report_proto",
[email protected]dffd8a912014-06-30 23:24:31450 ]
451 if (safe_browsing_mode == 1) {
scottmga266f952014-12-03 20:47:10452 sources +=
stuartmorgan1b3df822014-12-08 14:36:11453 rebase_path(gypi_values.chrome_browser_safe_browsing_full_sources,
scottmga266f952014-12-03 20:47:10454 ".",
455 "//chrome")
scottmga266f952014-12-03 20:47:10456 deps += [ "//chrome/common/safe_browsing:proto" ]
nparkerb2cd5ee2015-05-13 01:12:01457 } else if (safe_browsing_mode == 3) {
458 sources += rebase_path(
459 gypi_values.chrome_browser_safe_browsing_mobile_extended_sources,
460 ".",
461 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31462 }
463 }
464
amistryf269d3b2015-06-09 19:18:39465 if (enable_hotwording) {
466 defines += [ "ENABLE_HOTWORDING" ]
467 }
468
[email protected]dffd8a912014-06-30 23:24:31469 if (is_linux) {
thestigee816c272014-11-22 02:47:51470 deps += [
471 "//device/media_transfer_protocol",
scottmga266f952014-12-03 20:47:10472 "//device/udev_linux",
thestigee816c272014-11-22 02:47:51473 ]
[email protected]dffd8a912014-06-30 23:24:31474 }
475 if (is_linux && !is_chromeos) {
[email protected]fd98b612014-07-09 22:11:47476 deps += [ "//third_party/speech-dispatcher" ]
[email protected]dffd8a912014-06-30 23:24:31477 }
478
479 if (is_chromeos) {
480 sources += rebase_path(gypi_values.chrome_browser_chromeos_sources,
scottmga266f952014-12-03 20:47:10481 ".",
482 "//chrome")
483 deps += [ "//chrome/browser/chromeos" ]
[email protected]dffd8a912014-06-30 23:24:31484 } else {
485 # Non-ChromeOS.
486 sources += rebase_path(gypi_values.chrome_browser_non_chromeos_sources,
scottmga266f952014-12-03 20:47:10487 ".",
488 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31489 }
490
yiyaoliubcd08dc22014-12-10 05:56:10491 if (is_ios) {
492 sources -= [
493 "metrics/signin_status_metrics_provider_base.cc",
494 "metrics/signin_status_metrics_provider_base.h",
495 ]
496 }
497
mukai8c99b882014-10-15 03:07:59498 if (is_chromeos || is_ios) {
499 sources -= [
500 "metrics/signin_status_metrics_provider.cc",
501 "metrics/signin_status_metrics_provider.h",
502 ]
503 }
504
[email protected]dffd8a912014-06-30 23:24:31505 if (use_cups) {
[email protected]604828c2014-07-02 20:39:12506 configs += [ "//printing:cups" ]
[email protected]dffd8a912014-06-30 23:24:31507 }
508 if (is_desktop_linux) {
509 sources += rebase_path(gypi_values.chrome_browser_gnome_keyring_sources,
scottmga266f952014-12-03 20:47:10510 ".",
511 "//chrome")
cmasone0a9e4ca2014-10-16 16:40:49512 configs += [ ":gnome_keyring" ]
[email protected]dffd8a912014-06-30 23:24:31513 }
dvadym34532022015-01-22 15:42:51514 if (is_desktop_linux) {
515 sources += rebase_path(gypi_values.chrome_browser_libsecret_sources,
516 ".",
517 "//chrome")
518 defines += [ "USE_LIBSECRET" ]
519 }
[email protected]dffd8a912014-06-30 23:24:31520 if (use_aura) {
scottmga266f952014-12-03 20:47:10521 sources +=
522 rebase_path(gypi_values.chrome_browser_aura_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31523 deps += [
[email protected]fca567b2014-07-02 17:37:34524 "//ui/aura",
525 "//ui/compositor",
[email protected]604828c2014-07-02 20:39:12526 "//ui/keyboard",
[email protected]dffd8a912014-06-30 23:24:31527 ]
528 }
529 if (ui_compositor_image_transport) {
530 deps += [ "//ui/gl" ]
531 }
532
[email protected]855b7de2014-07-08 21:02:45533 if (use_ash) {
scottmga266f952014-12-03 20:47:10534 sources +=
535 rebase_path(gypi_values.chrome_browser_ash_sources, ".", "//chrome")
[email protected]855b7de2014-07-08 21:02:45536 }
537
[email protected]dffd8a912014-06-30 23:24:31538 if (use_x11) {
scottmga266f952014-12-03 20:47:10539 sources +=
540 rebase_path(gypi_values.chrome_browser_x11_sources, ".", "//chrome")
vchigrinbbc23e72015-01-21 22:49:23541 } else {
542 sources -= [ "password_manager/password_store_x.cc" ]
[email protected]dffd8a912014-06-30 23:24:31543 }
544 if (is_posix && !is_mac && !is_ios) {
545 sources += [
rseseka0a7a042014-09-18 23:59:20546 "//chrome/app/chrome_crash_reporter_client.cc",
547 "//chrome/app/chrome_crash_reporter_client.h",
[email protected]dffd8a912014-06-30 23:24:31548 ]
549 deps += [
Robert Sesekabcd8102014-08-27 16:12:44550 "//components/crash/app",
551 "//components/crash/browser",
[email protected]dffd8a912014-06-30 23:24:31552 ]
553 }
554 if (use_nss_certs) {
scottmga266f952014-12-03 20:47:10555 sources +=
556 rebase_path(gypi_values.chrome_browser_nss_sources, ".", "//chrome")
mukai8c99b882014-10-15 03:07:59557 if (is_chromeos) {
558 sources -= [ "net/nss_context_linux.cc" ]
559 }
[email protected]dffd8a912014-06-30 23:24:31560 }
561 if (enable_notifications) {
562 sources += rebase_path(gypi_values.chrome_browser_notifications_sources,
scottmga266f952014-12-03 20:47:10563 ".",
564 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31565 if (!is_android) {
566 sources += rebase_path(
stuartmorgan1b3df822014-12-08 14:36:11567 gypi_values.chrome_browser_notifications_non_android_sources,
scottmga266f952014-12-03 20:47:10568 ".",
569 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31570 }
571 }
572 if (enable_themes) {
scottmga266f952014-12-03 20:47:10573 sources +=
574 rebase_path(gypi_values.chrome_browser_themes_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31575 }
576
vitalybuka93eea402014-11-05 23:47:15577 if (enable_basic_printing || enable_print_preview) {
[email protected]dffd8a912014-06-30 23:24:31578 # Some form of printing support.
stuartmorgan1b3df822014-12-08 14:36:11579 sources += rebase_path(gypi_values.chrome_browser_printing_basic_sources,
scottmga266f952014-12-03 20:47:10580 ".",
581 "//chrome")
582 deps += [ "//printing" ]
vitalybuka36259ca2014-08-28 23:42:24583 if (is_win) {
[email protected]dffd8a912014-06-30 23:24:31584 sources += rebase_path(gypi_values.chrome_browser_printing_emf_sources,
scottmga266f952014-12-03 20:47:10585 ".",
586 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31587 }
vitalybuka93eea402014-11-05 23:47:15588 if (enable_print_preview) {
[email protected]dffd8a912014-06-30 23:24:31589 # Full printing on top of the above.
stuartmorgan1b3df822014-12-08 14:36:11590 sources += rebase_path(gypi_values.chrome_browser_printing_full_sources,
scottmga266f952014-12-03 20:47:10591 ".",
592 "//chrome")
vitalybuka93eea402014-11-05 23:47:15593 } else {
[email protected]dffd8a912014-06-30 23:24:31594 # Partial-only printing support.
scottmga266f952014-12-03 20:47:10595 sources +=
stuartmorgan1b3df822014-12-08 14:36:11596 rebase_path(gypi_values.chrome_browser_printing_basic_only_sources,
scottmga266f952014-12-03 20:47:10597 ".",
598 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31599 }
600 }
601 if (enable_captive_portal_detection) {
602 sources += rebase_path(gypi_values.chrome_browser_captive_portal_sources,
scottmga266f952014-12-03 20:47:10603 ".",
604 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31605 }
606 if (enable_session_service) {
607 sources += rebase_path(gypi_values.chrome_browser_session_service_sources,
scottmga266f952014-12-03 20:47:10608 ".",
609 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31610 }
611
thestigdc377202014-10-28 22:06:02612 if (!is_android && !is_ios && !is_chromeos) {
scottmga266f952014-12-03 20:47:10613 sources +=
614 rebase_path(gypi_values.chrome_browser_desktop_sources, ".", "//chrome")
thestigdc377202014-10-28 22:06:02615 }
616
[email protected]dffd8a912014-06-30 23:24:31617 if (is_android || is_ios) {
618 # Mobile.
scottmga266f952014-12-03 20:47:10619 sources +=
620 rebase_path(gypi_values.chrome_browser_mobile_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31621 } else {
622 # Non-mobile.
623 sources += rebase_path(gypi_values.chrome_browser_non_mobile_sources,
scottmga266f952014-12-03 20:47:10624 ".",
625 "//chrome")
reillyge471fab2014-08-29 01:58:43626 deps += [
sdefresnebbf563c2015-03-17 11:09:09627 "//components/feedback",
reillyge471fab2014-08-29 01:58:43628 "//device/core",
rockot50dc5692015-07-08 01:57:26629 "//device/devices_app/public/cpp",
630 "//device/devices_app/public/cpp:factory",
reillygd77718d2014-09-04 00:57:56631 "//device/usb",
reillyge471fab2014-08-29 01:58:43632 ]
[email protected]dffd8a912014-06-30 23:24:31633 }
634
635 if (is_android) {
scottmga266f952014-12-03 20:47:10636 sources +=
637 rebase_path(gypi_values.chrome_browser_android_sources, ".", "//chrome")
twellingtoncaf0eb752015-06-01 16:19:50638 sources += rebase_path(gypi_values.chrome_browser_bookmark_android_sources,
639 ".",
640 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31641 deps += [
pkotwicz127726f2015-05-29 15:20:12642 ":client_discourse_context_proto",
643 ":delta_file_proto",
James Robinson2ed4d692014-09-17 05:20:58644 ":jni_headers",
[email protected]55699f392014-08-20 22:16:30645 "//components/cdm/browser",
cjhopman09981a92014-10-27 17:11:18646 "//components/enhanced_bookmarks",
twifkak8c9f7502015-06-25 02:12:57647 "//components/precache/content",
648 "//components/precache/core",
estadee37f8222014-11-07 21:35:22649 "//components/resources:components_resources",
mathiash3ecfdfa2015-04-13 15:06:07650 "//components/service_tab_launcher",
cjhopman09981a92014-10-27 17:11:18651 "//components/web_contents_delegate_android",
652 "//third_party/android_opengl/etc1",
fdegans34f31e272015-05-22 16:59:03653 "//third_party/android_tools:cpu_features",
twellington0bc61492015-01-30 20:14:13654 "//third_party/libaddressinput:util",
[email protected]dffd8a912014-06-30 23:24:31655 ]
656 deps -= [
[email protected]fca567b2014-07-02 17:37:34657 "//third_party/libaddressinput",
[email protected]abd4b682014-07-16 20:26:30658 "//components/storage_monitor",
[email protected]abd4b682014-07-16 20:26:30659 "//components/web_modal",
[email protected]dffd8a912014-06-30 23:24:31660 ]
megjablon5effca2e2015-02-13 23:54:07661 defines += [ "ENABLE_DATA_REDUCTION_PROXY_DEBUGGING" ]
rseseke59ea892015-03-19 22:27:44662
663 if (use_seccomp_bpf) {
664 defines += [ "USE_SECCOMP_BPF" ]
rsesek65d31352015-06-08 22:53:44665 deps += [ "//sandbox/linux:seccomp_bpf" ]
rseseke59ea892015-03-19 22:27:44666 }
[email protected]dffd8a912014-06-30 23:24:31667 }
668
669 if (is_mac) {
670 deps += [
[email protected]6b5d2f92014-07-30 00:40:03671 "//third_party/google_toolbox_for_mac",
tfarina22896302015-02-23 21:18:03672 "//third_party/mozilla",
[email protected]dffd8a912014-06-30 23:24:31673 ]
674 libs += [
675 "Accelerate.framework",
676 "AddressBook.framework",
677 "AudioUnit.framework",
678 "DiskArbitration.framework",
679 "IOKit.framework",
680 "ImageCaptureCore.framework",
681 "OpenGL.framework",
682 "QuartzCore.framework",
683 "SecurityInterface.framework",
684 ]
685 }
686
687 if (enable_rlz) {
scottmga266f952014-12-03 20:47:10688 sources +=
689 rebase_path(gypi_values.chrome_browser_rlz_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31690 deps += [ "//rlz:rlz_lib" ]
691 }
692
693 # TODO(GYP)
694 # Temporary fix to break the browser target into smaller chunks so it
695 # will link with goma builds.
696 #["OS=="win" and chromium_win_pch==0", {
697 # "msvs_shard": 4,
698 #}],
699
700 if (is_win) {
scottmga266f952014-12-03 20:47:10701 sources +=
702 rebase_path(gypi_values.chrome_browser_win_sources, ".", "//chrome")
Brett Wilsone53895272014-09-23 23:41:46703 public_deps += [
704 "//ui/views",
705 "//ui/views/controls/webview",
706 ]
[email protected]dffd8a912014-06-30 23:24:31707 deps += [
vchigrin9593e7a2015-01-27 10:08:19708 ":chrome_process_finder",
[email protected]55699f392014-08-20 22:16:30709 "//chrome:version_header",
710 "//chrome/installer/util:strings",
vchigrinf2b90aa2015-01-23 11:12:19711 "//chrome_elf",
712 "//chrome_elf:constants",
713 "//chrome_elf:dll_hash",
vchigrin61944ae2015-01-30 23:51:32714 "//components/browser_watcher",
715 "//components/browser_watcher:browser_watcher_client",
vchigrinbbc23e72015-01-21 22:49:23716 "//google_update",
[email protected]55699f392014-08-20 22:16:30717 "//third_party/iaccessible2",
718 "//third_party/isimpledom",
[email protected]dffd8a912014-06-30 23:24:31719 "//third_party/wtl",
vchigrin88ed6f42015-01-17 11:56:42720 "//ui/metro_viewer",
721 "//win8:metro_viewer",
[email protected]dffd8a912014-06-30 23:24:31722 ]
brettw44a5cf82015-04-08 19:48:22723 libs += [
724 "credui.lib",
725 "netapi32.lib",
726 ]
grt235b3f092015-05-27 21:42:48727 if (!is_chrome_branded) {
728 deps -= [ "//google_update" ]
729 sources -= [
730 "google/did_run_updater_win.cc",
731 "google/did_run_updater_win.h",
732 "google/google_update_win.cc",
733 "google/google_update_win.h",
734 ]
735 }
[email protected]dffd8a912014-06-30 23:24:31736 } else {
737 # Non-Windows.
scottmga266f952014-12-03 20:47:10738 sources +=
739 rebase_path(gypi_values.chrome_browser_non_win_sources, ".", "//chrome")
[email protected]f6dc4ae2014-07-30 00:10:37740 if (toolkit_views) {
[email protected]dffd8a912014-06-30 23:24:31741 deps += [
scottmga266f952014-12-03 20:47:10742 "//ui/views",
743 "//ui/views/controls/webview",
[email protected]dffd8a912014-06-30 23:24:31744 ]
[email protected]dffd8a912014-06-30 23:24:31745 }
746 }
747
748 if (is_linux) {
scottmga266f952014-12-03 20:47:10749 sources +=
750 rebase_path(gypi_values.chrome_browser_linux_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31751 if (use_aura) {
752 configs += [
753 "//build/config/linux:dbus",
754 "//build/config/linux:fontconfig",
755 ]
scottmga266f952014-12-03 20:47:10756 deps += [ "//dbus" ]
[email protected]dffd8a912014-06-30 23:24:31757 }
758 if (use_x11) {
759 configs += [ "//build/config/linux:x11" ]
760 deps += [ "//ui/gfx/x" ]
761 }
762 }
763
764 if (is_desktop_linux) {
stuartmorgan7f569a822014-12-08 20:10:54765 sources += rebase_path(gypi_values.chrome_browser_linux_desktop_sources,
scottmga266f952014-12-03 20:47:10766 ".",
767 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31768 }
769 if (enable_plugin_installation) {
scottmga266f952014-12-03 20:47:10770 sources +=
771 rebase_path(gypi_values.chrome_browser_plugin_installation_sources,
772 ".",
773 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31774 }
775 if (enable_app_list) {
scottmga266f952014-12-03 20:47:10776 deps += [ "//ui/app_list" ]
[email protected]dffd8a912014-06-30 23:24:31777 }
treib87bb89cbb2014-12-01 16:01:47778 if (enable_supervised_users) {
scottmga266f952014-12-03 20:47:10779 sources += rebase_path(gypi_values.chrome_browser_supervised_user_sources,
780 ".",
781 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31782 }
bauerb7f3b8542015-06-29 19:56:19783 if (enable_supervised_users && !is_android && !is_ios) {
784 sources +=
785 rebase_path(gypi_values.chrome_browser_supervised_user_legacy_sources,
786 ".",
787 "//chrome")
788 }
treib87bb89cbb2014-12-01 16:01:47789 if (enable_supervised_users && enable_themes) {
thestig169a6362014-11-13 20:47:59790 sources += rebase_path(
scottmga266f952014-12-03 20:47:10791 gypi_values.chrome_browser_supervised_user_and_themes_sources,
792 ".",
793 "//chrome")
thestig169a6362014-11-13 20:47:59794 }
[email protected]dffd8a912014-06-30 23:24:31795 if (enable_webrtc) {
scottmga266f952014-12-03 20:47:10796 sources +=
797 rebase_path(gypi_values.chrome_browser_webrtc_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31798 }
799 if (enable_service_discovery) {
scottmga266f952014-12-03 20:47:10800 sources += rebase_path(gypi_values.chrome_browser_service_discovery_sources,
801 ".",
802 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31803 }
804 if (enable_mdns) {
scottmga266f952014-12-03 20:47:10805 sources +=
806 rebase_path(gypi_values.chrome_browser_mdns_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31807 }
808 if (!enable_autofill_dialog || is_android || is_ios) {
809 sources -= [
810 "autofill/validation_rules_storage_factory.cc",
811 "autofill/validation_rules_storage_factory.h",
812 ]
813 }
814 if (enable_wifi_bootstrapping) {
scottmga266f952014-12-03 20:47:10815 sources +=
816 rebase_path(gypi_values.chrome_browser_wifi_bootstrapping_sources,
817 ".",
818 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31819 if (is_win || is_mac) {
820 # TODO(brettw) as of this writing wifi bootstrapping is set on Windows
821 # and Mac, so this test is meaningless. Can we merge these lists?
822 sources += rebase_path(
stuartmorgan1b3df822014-12-08 14:36:11823 gypi_values.chrome_browser_wifi_bootstrapping_win_mac_sources,
scottmga266f952014-12-03 20:47:10824 ".",
825 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31826 }
827 }
mfoltz150bb8b2015-04-09 22:30:05828 if (enable_media_router) {
imchengb6b09239f2015-05-15 21:41:55829 deps += [ "//chrome/browser/media/router" ]
mfoltz150bb8b2015-04-09 22:30:05830 }
[email protected]dffd8a912014-06-30 23:24:31831}
832
James Robinson2ed4d692014-09-17 05:20:58833if (is_android) {
834 # GYP version: chrome/chrome_browser.gypi:chrome_browser_jni_headers
835 generate_jni("jni_headers") {
scottmga266f952014-12-03 20:47:10836 sources =
837 rebase_path(gypi_values.chrome_browser_jni_sources, ".", "//chrome")
James Robinson2ed4d692014-09-17 05:20:58838 jni_package = "chrome"
839 }
pkotwicz127726f2015-05-29 15:20:12840
841 #GYP: '//chrome/chrome_browser.gypi:client_discourse_context_proto'
842 proto_library("client_discourse_context_proto") {
843 sources = [
844 "android/proto/client_discourse_context.proto",
845 ]
846 }
847
848 #GYP: '//chrome/chrome_browser.gypi:delta_file_proto'
849 proto_library("delta_file_proto") {
850 sources = [
851 "android/proto/delta_file.proto",
852 ]
853 }
James Robinson2ed4d692014-09-17 05:20:58854}
855
vchigrin9593e7a2015-01-27 10:08:19856if (is_win) {
857 source_set("chrome_process_finder") {
858 sources = [
859 "chrome_process_finder_win.cc",
860 "chrome_process_finder_win.h",
861 ]
862 deps = [
863 "//base",
864 "//chrome/browser/metro_utils",
865 "//chrome/common:constants",
866 ]
867 if (enable_configuration_policy) {
868 deps += [ "//chrome/browser/policy:path_parser" ]
869 }
870 }
871}
872
[email protected]77ce8022014-06-16 19:29:56873# GYP version: chrome/chrome_resources.gyp:chrome_resources
874# (generate_browser_resources action)
875grit("resources") {
876 source = "browser_resources.grd"
[email protected]48885492014-08-13 11:22:41877 output_dir = "$root_gen_dir/chrome"
[email protected]cb0c67a2014-07-22 16:37:26878 outputs = [
879 "grit/browser_resources.h",
880 "browser_resources.pak",
881 ]
[email protected]77ce8022014-06-16 19:29:56882
scottmga266f952014-12-03 20:47:10883 omnibox_mojom_file =
884 "$root_gen_dir/chrome/browser/ui/webui/omnibox/omnibox.mojom.js"
[email protected]77ce8022014-06-16 19:29:56885
886 grit_flags = [
scottmga266f952014-12-03 20:47:10887 "-E",
888 "about_credits_file=" + rebase_path(about_credits_file, root_build_dir),
889 "-E",
890 "additional_modules_list_file=" +
891 rebase_path(additional_modules_list_file, root_build_dir),
892 "-E",
893 "omnibox_mojom_file=" + rebase_path(omnibox_mojom_file, root_build_dir),
[email protected]77ce8022014-06-16 19:29:56894 ]
895
896 deps = [
897 ":about_credits",
898 ":chrome_internal_resources_gen",
brettwde262b02015-05-27 19:41:42899
900 # Depend only on the generated mojo bindings since we read the .mojom.js
901 # file, rather than the whole mojo target which will link the C++ bindings.
902 "//chrome/browser/ui/webui/omnibox:mojo_bindings__generator",
vchigrin8eede942015-01-29 09:28:15903 ]
904 inputs = [
905 omnibox_mojom_file,
[email protected]77ce8022014-06-16 19:29:56906 ]
907}
908
909# GYP version: chrome/chrome_resource.gyp:about_credits
910action("about_credits") {
911 script = "//tools/licenses.py"
912
dbeamc7776c72014-12-17 02:24:05913 inputs = [
914 # This is not a complete list. TODO(phajdan.jr, dbeam): licenses.py needs to
915 # generate a .d file with all the licenses/credits that about:credits uses.
916 # Then about:credits will automatically rebuild when one of them changes.
917 # See: depfile in gn's documentation (gn help depfile).
918 "resources/about_credits.tmpl",
919 "resources/about_credits_entry.tmpl",
920 ]
921
scottmga266f952014-12-03 20:47:10922 outputs = [
923 about_credits_file,
924 ]
[email protected]77ce8022014-06-16 19:29:56925
926 args = [
927 "credits",
928 rebase_path(about_credits_file, root_build_dir),
929 ]
930}
931
932# GYP version: chrome/chrome_resource.gyp:chrome_internal_resources_gen
engedy99d0e11b2014-09-30 13:32:41933if (is_chrome_branded) {
[email protected]77ce8022014-06-16 19:29:56934 action("chrome_internal_resources_gen") {
engedy99d0e11b2014-09-30 13:32:41935 script = "internal/transform_additional_modules_list.py"
scottmga266f952014-12-03 20:47:10936 sources = [
937 "internal/resources/additional_modules_list.input",
938 ]
939 outputs = [
940 additional_modules_list_file,
941 ]
engedy99d0e11b2014-09-30 13:32:41942 args = rebase_path(sources, root_build_dir) +
943 rebase_path(outputs, root_build_dir)
[email protected]77ce8022014-06-16 19:29:56944 }
945} else {
946 group("chrome_internal_resources_gen") {
947 # Empty placeholder.
948 }
949}
Brett Wilson052ce132014-09-12 19:46:29950
951# In GYP this is part of test_support_common.
952source_set("test_support") {
953 testonly = true
954
955 # Always include this via the main test support target.
956 visibility = [ "//chrome/test:test_support" ]
957
958 sources = [
959 "browsing_data/mock_browsing_data_appcache_helper.cc",
960 "browsing_data/mock_browsing_data_appcache_helper.h",
961 "browsing_data/mock_browsing_data_channel_id_helper.cc",
962 "browsing_data/mock_browsing_data_channel_id_helper.h",
963 "browsing_data/mock_browsing_data_cookie_helper.cc",
964 "browsing_data/mock_browsing_data_cookie_helper.h",
965 "browsing_data/mock_browsing_data_database_helper.cc",
966 "browsing_data/mock_browsing_data_database_helper.h",
967 "browsing_data/mock_browsing_data_file_system_helper.cc",
968 "browsing_data/mock_browsing_data_file_system_helper.h",
969 "browsing_data/mock_browsing_data_flash_lso_helper.cc",
970 "browsing_data/mock_browsing_data_flash_lso_helper.h",
971 "browsing_data/mock_browsing_data_indexed_db_helper.cc",
972 "browsing_data/mock_browsing_data_indexed_db_helper.h",
973 "browsing_data/mock_browsing_data_local_storage_helper.cc",
974 "browsing_data/mock_browsing_data_local_storage_helper.h",
975 "browsing_data/mock_browsing_data_quota_helper.cc",
976 "browsing_data/mock_browsing_data_quota_helper.h",
977 "browsing_data/mock_browsing_data_service_worker_helper.cc",
978 "browsing_data/mock_browsing_data_service_worker_helper.h",
979 "download/download_test_file_activity_observer.cc",
980 "download/download_test_file_activity_observer.h",
981 "download/test_download_shelf.cc",
982 "download/test_download_shelf.h",
Brett Wilson052ce132014-09-12 19:46:29983 "invalidation/fake_invalidation_service.cc",
984 "invalidation/fake_invalidation_service.h",
985 "media/fake_desktop_media_list.cc",
986 "media/fake_desktop_media_list.h",
987 "net/dns_probe_test_util.cc",
988 "net/dns_probe_test_util.h",
989 "net/url_request_mock_util.cc",
990 "net/url_request_mock_util.h",
991 "notifications/notification_test_util.cc",
992 "notifications/notification_test_util.h",
993 "password_manager/mock_password_store_service.cc",
994 "password_manager/mock_password_store_service.h",
995 "password_manager/null_password_store_service.cc",
996 "password_manager/null_password_store_service.h",
997 "password_manager/test_password_store_service.cc",
998 "password_manager/test_password_store_service.h",
999 "prefs/pref_service_mock_factory.cc",
1000 "prefs/pref_service_mock_factory.h",
1001 "profile_resetter/profile_resetter_test_base.cc",
1002 "profile_resetter/profile_resetter_test_base.h",
1003 "search_engines/template_url_service_factory_test_util.cc",
1004 "search_engines/template_url_service_factory_test_util.h",
1005 "search_engines/template_url_service_test_util.cc",
1006 "search_engines/template_url_service_test_util.h",
squef7d723a2015-01-26 22:13:451007 "sessions/session_restore_test_helper.cc",
1008 "sessions/session_restore_test_helper.h",
Brett Wilson052ce132014-09-12 19:46:291009 "sessions/session_service_test_helper.cc",
1010 "sessions/session_service_test_helper.h",
Brett Wilson052ce132014-09-12 19:46:291011 "signin/fake_account_tracker_service.cc",
1012 "signin/fake_account_tracker_service.h",
mlerman2933d012015-04-24 18:34:271013 "signin/fake_gaia_cookie_manager_service.cc",
1014 "signin/fake_gaia_cookie_manager_service.h",
Brett Wilson052ce132014-09-12 19:46:291015 "signin/fake_profile_oauth2_token_service.cc",
1016 "signin/fake_profile_oauth2_token_service.h",
1017 "signin/fake_profile_oauth2_token_service_builder.cc",
1018 "signin/fake_profile_oauth2_token_service_builder.h",
1019 "signin/fake_signin_manager.cc",
1020 "signin/fake_signin_manager.h",
1021 "ssl/ssl_client_auth_requestor_mock.cc",
1022 "ssl/ssl_client_auth_requestor_mock.h",
Brett Wilson052ce132014-09-12 19:46:291023 "sync/profile_sync_components_factory_mock.cc",
1024 "sync/profile_sync_components_factory_mock.h",
1025 "sync/profile_sync_service_mock.cc",
1026 "sync/profile_sync_service_mock.h",
shadi2f257fc2014-12-03 18:04:121027 "ui/webui/signin/login_ui_test_utils.cc",
1028 "ui/webui/signin/login_ui_test_utils.h",
Brett Wilson052ce132014-09-12 19:46:291029 ]
1030
Brett Wilsone53895272014-09-23 23:41:461031 public_deps = [
Brett Wilson052ce132014-09-12 19:46:291032 ":browser",
Brett Wilsone53895272014-09-23 23:41:461033 "//chrome/browser/ui:test_support",
1034 ]
1035 deps = [
Brett Wilson052ce132014-09-12 19:46:291036 "//base:prefs_test_support",
1037 "//chrome/browser",
Brett Wilson052ce132014-09-12 19:46:291038 "//chrome/common",
1039 "//chrome/common/safe_browsing:proto",
knn062cdbb2015-06-26 18:18:421040 "//components/invalidation/impl",
1041 "//components/invalidation/impl:test_support",
Brett Wilson052ce132014-09-12 19:46:291042 "//components/password_manager/core/browser:test_support",
1043 "//components/search_engines:test_support",
1044 "//content/test:test_support",
1045 "//chrome/app/theme:theme_resources",
1046 "//net:test_support",
1047 "//skia",
1048 "//testing/gmock",
1049 "//testing/gtest",
1050 "//ui/gfx",
1051 ]
1052
Brett Wilson052ce132014-09-12 19:46:291053 if (!is_ios) {
1054 deps += [
1055 "//components/sessions:test_support",
Brett Wilson052ce132014-09-12 19:46:291056 "//google_apis:test_support",
1057 ]
1058 }
1059
James Robinson2ed4d692014-09-17 05:20:581060 if (enable_extensions) {
thestig52a87b3b2014-10-23 22:02:381061 sources += [
1062 "extensions/extension_action_test_util.cc",
1063 "extensions/extension_action_test_util.h",
1064 ]
scottmga266f952014-12-03 20:47:101065 deps += [ "//extensions:test_support" ]
James Robinson2ed4d692014-09-17 05:20:581066 }
1067
Brett Wilson052ce132014-09-12 19:46:291068 if (is_chromeos) {
1069 sources += [
1070 "chromeos/app_mode/fake_cws.cc",
1071 "chromeos/app_mode/fake_cws.h",
1072 "chromeos/file_manager/fake_disk_mount_manager.cc",
1073 "chromeos/file_manager/fake_disk_mount_manager.h",
1074 "chromeos/input_method/mock_candidate_window_controller.cc",
1075 "chromeos/input_method/mock_candidate_window_controller.h",
1076 "chromeos/input_method/mock_input_method_engine.cc",
1077 "chromeos/input_method/mock_input_method_engine.h",
1078 "chromeos/input_method/mock_input_method_manager.cc",
1079 "chromeos/input_method/mock_input_method_manager.h",
brettw7d6ec2462015-01-07 13:00:511080 "chromeos/login/screens/mock_device_disabled_screen_actor.cc",
1081 "chromeos/login/screens/mock_device_disabled_screen_actor.h",
nkostylev393309f2015-02-05 13:57:391082 "chromeos/login/session/user_session_manager_test_api.cc",
1083 "chromeos/login/session/user_session_manager_test_api.h",
Brett Wilson052ce132014-09-12 19:46:291084 "chromeos/login/test/js_checker.cc",
1085 "chromeos/login/test/js_checker.h",
satoruxb7a72ea2015-02-13 07:19:591086 "chromeos/login/test/oobe_screen_waiter.cc",
1087 "chromeos/login/test/oobe_screen_waiter.h",
Brett Wilson052ce132014-09-12 19:46:291088 "chromeos/login/ui/mock_login_display.cc",
1089 "chromeos/login/ui/mock_login_display.h",
1090 "chromeos/login/ui/mock_login_display_host.cc",
1091 "chromeos/login/ui/mock_login_display_host.h",
brettw7d6ec2462015-01-07 13:00:511092 "chromeos/login/users/avatar/mock_user_image_manager.cc",
1093 "chromeos/login/users/avatar/mock_user_image_manager.h",
merkulova793f3022015-02-04 10:18:301094 "chromeos/login/users/fake_chrome_user_manager.cc",
1095 "chromeos/login/users/fake_chrome_user_manager.h",
brettw7d6ec2462015-01-07 13:00:511096 "chromeos/login/users/fake_supervised_user_manager.cc",
1097 "chromeos/login/users/fake_supervised_user_manager.h",
brettw7d6ec2462015-01-07 13:00:511098 "chromeos/login/users/mock_user_manager.cc",
1099 "chromeos/login/users/mock_user_manager.h",
Brett Wilson052ce132014-09-12 19:46:291100 "chromeos/net/network_portal_detector_test_utils.cc",
1101 "chromeos/net/network_portal_detector_test_utils.h",
1102 "chromeos/policy/cloud_external_data_manager_base_test_util.cc",
1103 "chromeos/policy/cloud_external_data_manager_base_test_util.h",
1104 "chromeos/policy/device_policy_builder.cc",
1105 "chromeos/policy/device_policy_builder.h",
brettwa68ea2b2015-02-01 02:54:071106 "chromeos/policy/fake_consumer_management_service.cc",
1107 "chromeos/policy/fake_consumer_management_service.h",
Brett Wilson052ce132014-09-12 19:46:291108 "chromeos/policy/fake_device_cloud_policy_initializer.cc",
1109 "chromeos/policy/fake_device_cloud_policy_initializer.h",
brettwa68ea2b2015-02-01 02:54:071110 "chromeos/policy/fake_device_cloud_policy_manager.cc",
1111 "chromeos/policy/fake_device_cloud_policy_manager.h",
Brett Wilson052ce132014-09-12 19:46:291112 "chromeos/policy/stub_enterprise_install_attributes.cc",
1113 "chromeos/policy/stub_enterprise_install_attributes.h",
1114 "chromeos/settings/device_settings_test_helper.cc",
1115 "chromeos/settings/device_settings_test_helper.h",
1116 "chromeos/system/fake_input_device_settings.cc",
1117 "chromeos/system/fake_input_device_settings.h",
1118 ]
1119 configs += [ "//build/config/linux:dbus" ]
mukai6ba73552014-10-09 19:05:171120 deps += [ "//chromeos:test_support" ]
Brett Wilson052ce132014-09-12 19:46:291121 }
1122
1123 if (enable_configuration_policy) {
1124 sources += [
1125 "policy/test/local_policy_test_server.cc",
1126 "policy/test/local_policy_test_server.h",
1127 ]
Brett Wilsone53895272014-09-23 23:41:461128 public_deps += [
Brett Wilson052ce132014-09-12 19:46:291129 "//components/policy:policy_component_test_support",
1130 "//components/policy:test_support",
1131 ]
Brett Wilson052ce132014-09-12 19:46:291132 }
1133
1134 if (safe_browsing_mode == 1) {
1135 sources += [
1136 "extensions/fake_safe_browsing_database_manager.cc",
1137 "extensions/fake_safe_browsing_database_manager.h",
1138 ]
1139 }
1140
1141 if (enable_extensions) {
1142 sources += [
1143 "drive/dummy_drive_service.cc",
1144 "drive/dummy_drive_service.h",
1145 "drive/fake_drive_service.cc",
1146 "drive/fake_drive_service.h",
1147 "drive/test_util.cc",
1148 "drive/test_util.h",
1149 "extensions/api/messaging/native_messaging_test_util.cc",
1150 "extensions/api/messaging/native_messaging_test_util.h",
1151 "extensions/extension_notification_observer.cc",
1152 "extensions/extension_notification_observer.h",
Brett Wilson052ce132014-09-12 19:46:291153 "extensions/mock_extension_special_storage_policy.cc",
1154 "extensions/mock_extension_special_storage_policy.h",
1155 "extensions/test_blacklist.cc",
1156 "extensions/test_blacklist.h",
1157 "extensions/test_blacklist_state_fetcher.cc",
1158 "extensions/test_blacklist_state_fetcher.h",
brettw7d6ec2462015-01-07 13:00:511159 "extensions/test_extension_dir.cc",
1160 "extensions/test_extension_dir.h",
satoruxb7a72ea2015-02-13 07:19:591161 "extensions/test_extension_environment.cc",
1162 "extensions/test_extension_environment.h",
Brett Wilson052ce132014-09-12 19:46:291163 "extensions/test_extension_prefs.cc",
1164 "extensions/test_extension_prefs.h",
1165 "extensions/test_extension_service.cc",
1166 "extensions/test_extension_service.h",
1167 "extensions/test_extension_system.cc",
1168 "extensions/test_extension_system.h",
1169 "media_galleries/media_galleries_test_util.cc",
1170 "media_galleries/media_galleries_test_util.h",
1171 ]
scottmga266f952014-12-03 20:47:101172 deps += [ "//components/storage_monitor:test_support" ]
Brett Wilson052ce132014-09-12 19:46:291173 }
1174
1175 if (enable_mdns) {
1176 sources += [
1177 "local_discovery/test_service_discovery_client.cc",
1178 "local_discovery/test_service_discovery_client.h",
1179 ]
1180 }
1181
1182 if (enable_app_list) {
1183 sources += [
1184 "ui/app_list/test/chrome_app_list_test_support.cc",
1185 "ui/app_list/test/chrome_app_list_test_support.h",
brettw7d6ec2462015-01-07 13:00:511186 "ui/app_list/test/test_app_list_controller_delegate.cc",
1187 "ui/app_list/test/test_app_list_controller_delegate.h",
Brett Wilson052ce132014-09-12 19:46:291188 ]
1189 }
1190
1191 if (enable_wifi_bootstrapping) {
1192 sources += [
1193 "local_discovery/wifi/mock_wifi_manager.cc",
1194 "local_discovery/wifi/mock_wifi_manager.h",
1195 ]
1196 }
1197}