blob: 76e58efc114fd9144848caf9bab8583368b93a1a [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() {
mgiuca3cd6a822015-08-07 00:46:1323 # 'Ok Google' hotwording is disabled by default. Set to true to enable. (This
24 # will download a closed-source NaCl module at startup.) Chrome-branded
25 # ChromeOS builds have this enabled by default.
26 enable_hotwording = is_chrome_branded && is_chromeos
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
mmenkede134672015-08-18 01:33:3938if (is_win) {
39 # This is in a separate config so the flags can be applied to dependents.
40 # ldflags in GN aren't automatically inherited.
41 config("browser_win_linker_flags") {
42 libs = [
43 "credui.lib",
44 "netapi32.lib",
45 "ndfapi.lib", # Used by browser/net/net_error_diagnostics_dialog_win.h
46 ]
47 ldflags = [ "/DELAYLOAD:ndfapi.dll" ]
48 }
49}
50
cmasone0a9e4ca2014-10-16 16:40:4951if (is_desktop_linux) {
brettwa68ea2b2015-02-01 02:54:0752 # Gnome-keyring is normally dynamically loaded. The gnome_keyring config
53 # will set this up.
cmasone0a9e4ca2014-10-16 16:40:4954 pkg_config("gnome_keyring") {
55 packages = [ "gnome-keyring-1" ]
brettwa68ea2b2015-02-01 02:54:0756 defines = [
57 "USE_GNOME_KEYRING",
58 "DLOPEN_GNOME_KEYRING",
59 ]
60 ignore_libs = true
61 }
62
63 # If you want to link gnome-keyring directly (use only for unit tests)
64 # ADDITIONALLY add this config on top of ":gnome_keyring". pkg-config is a
65 # bit slow, so prefer not to run it again. In practice, gnome-keyring's libs
66 # are just itself and common gnome ones we link already, so we can get away
67 # with additionally just coding the library name here.
68 config("gnome_keyring_direct") {
69 libs = [ "gnome-keyring" ]
cmasone0a9e4ca2014-10-16 16:40:4970 }
71}
72
brettw44a5cf82015-04-08 19:48:2273source_set("browser") {
apavlove749bca2014-09-30 11:07:4174 configs += [
75 "//build/config/compiler:wexit_time_destructors",
brettwbc8b2a22015-07-28 18:24:4276 "//build/config:precompiled_headers",
apavlove749bca2014-09-30 11:07:4177 "//third_party/WebKit/public:debug_devtools",
78 ]
[email protected]dffd8a912014-06-30 23:24:3179 defines = []
80 sources = []
81 libs = []
82 ldflags = []
83
84 # iOS/non-iOS shared deps. New dependencies should generally be added in the
85 # non-iOS deps below.
Brett Wilsone53895272014-09-23 23:41:4686 public_deps = [
87 "//components/autofill/core/browser",
88 "//content/public/browser",
89 "//sql",
90 "//sync",
91 ]
[email protected]dffd8a912014-06-30 23:24:3192 deps = [
93 "//base/allocator",
94 "//chrome:extra_resources",
95 "//chrome:resources",
96 "//chrome:strings",
[email protected]797b25042014-07-01 23:54:1797 "//chrome/app:generated_resources_map",
[email protected]855b7de2014-07-08 21:02:4598 "//chrome/app/resources:platform_locale_settings",
[email protected]797b25042014-07-01 23:54:1799 "//chrome/app/theme:theme_resources",
estark4282f1172015-05-13 22:01:55100 "//chrome/browser/net:encrypted_cert_logger_proto",
[email protected]797b25042014-07-01 23:54:17101 "//chrome/browser/net:probe_message_proto",
estark4282f1172015-05-13 22:01:55102 "//chrome/browser/ssl:cert_logger_proto",
[email protected]abd4b682014-07-16 20:26:30103 "//chrome/browser/ui",
[email protected]dffd8a912014-06-30 23:24:31104 "//chrome/common",
[email protected]604828c2014-07-02 20:39:12105 "//components/autofill/core/browser",
Brett Wilson1c693992014-08-25 19:10:01106 "//components/bookmarks/browser",
treiba9ea2fb2015-03-20 10:06:03107 "//components/bookmarks/managed",
[email protected]b9f4c682014-07-10 22:00:37108 "//components/captive_portal",
[email protected]fca567b2014-07-02 17:37:34109 "//components/cloud_devices/common",
Brett Wilson1c693992014-08-25 19:10:01110 "//components/component_updater",
vabrfc325fa2015-04-10 16:24:45111 "//components/content_settings/content/common",
vasiliiac461392014-09-18 11:35:17112 "//components/content_settings/core/browser",
[email protected]08f71012014-07-25 10:27:54113 "//components/content_settings/core/common",
[email protected]478ed232014-08-19 02:10:55114 "//components/crx_file",
megjablon3476e042014-10-14 19:21:59115 "//components/data_reduction_proxy/core/browser",
reillyg4a849272015-02-20 21:38:43116 "//components/device_event_log",
[email protected]273ae5ab2014-07-09 21:10:25117 "//components/domain_reliability",
noyaudaaac3a2014-10-08 11:11:11118 "//components/enhanced_bookmarks",
sdefresnecbacfd72015-03-20 12:11:32119 "//components/favicon/core",
sdefresne001b10de2015-03-20 18:41:46120 "//components/favicon_base",
[email protected]abd4b682014-07-16 20:26:30121 "//components/gcm_driver",
jianli2104ce612015-05-06 00:24:34122 "//components/gcm_driver/instance_id",
Brett Wilson1c693992014-08-25 19:10:01123 "//components/google/core/browser",
fsamuelaf5bf6d12015-05-28 16:29:54124 "//components/guest_view/browser",
erikchen332265b2014-11-14 19:59:52125 "//components/handoff",
[email protected]273ae5ab2014-07-09 21:10:25126 "//components/history/core/browser",
127 "//components/history/core/common",
Brett Wilson1c693992014-08-25 19:10:01128 "//components/infobars/core",
knn062cdbb2015-06-26 18:18:42129 "//components/invalidation/impl",
gunsch1afc65172014-09-16 00:03:32130 "//components/metrics:gpu",
[email protected]fca567b2014-07-02 17:37:34131 "//components/metrics:net",
gunsch840bc412014-09-18 19:38:06132 "//components/metrics:profiler",
Brett Wilson1c693992014-08-25 19:10:01133 "//components/metrics/proto:proto",
rsleevic327b48f82015-04-30 02:03:25134 "//components/mime_util",
[email protected]fca567b2014-07-02 17:37:34135 "//components/navigation_metrics",
Brett Wilson1c693992014-08-25 19:10:01136 "//components/network_time",
fgorskife7b92f2015-06-15 19:19:40137 "//components/offline_pages",
blundell2102f7c2015-07-09 10:00:53138 "//components/omnibox/browser",
[email protected]fca567b2014-07-02 17:37:34139 "//components/os_crypt",
haavardmdfdf28f2015-01-08 21:05:00140 "//components/packed_ct_ev_whitelist",
Brett Wilson1c693992014-08-25 19:10:01141 "//components/password_manager/core/browser",
142 "//components/password_manager/core/common",
[email protected]fca567b2014-07-02 17:37:34143 "//components/policy:policy_component",
stevenjbb237e2ae2015-07-02 22:02:11144 "//components/proxy_config",
[email protected]fca567b2014-07-02 17:37:34145 "//components/query_parser",
[email protected]b9f4c682014-07-10 22:00:37146 "//components/rappor",
Brett Wilson1c693992014-08-25 19:10:01147 "//components/renderer_context_menu",
[email protected]720b10492014-07-23 08:48:40148 "//components/search",
Brett Wilson1c693992014-08-25 19:10:01149 "//components/search_engines",
150 "//components/search_provider_logos",
felt20e0f2002015-07-31 15:27:36151 "//components/security_interstitials/core",
[email protected]abd4b682014-07-16 20:26:30152 "//components/signin/core/browser",
153 "//components/startup_metric_utils",
[email protected]797b25042014-07-01 23:54:17154 "//components/strings",
mathp60143a32014-10-08 14:52:45155 "//components/suggestions",
Brett Wilson1c693992014-08-25 19:10:01156 "//components/sync_driver",
[email protected]b9f4c682014-07-10 22:00:37157 "//components/translate/core/browser",
158 "//components/translate/core/common",
wjmaclean7f63c6b2014-12-09 14:59:55159 "//components/ui/zoom:ui_zoom",
sdefresnec083d1f2015-04-17 21:12:18160 "//components/undo",
sorin39eab2f2015-01-06 01:09:08161 "//components/update_client",
rsleevi24f64dc22015-08-07 21:39:21162 "//components/url_formatter",
[email protected]fca567b2014-07-02 17:37:34163 "//components/user_prefs",
jitendra.ks94c0b962015-08-10 08:24:09164 "//components/user_prefs/tracked:user_prefs_tracked",
isherman3be67db2014-10-24 05:57:44165 "//components/variations",
166 "//components/variations/net",
[email protected]bf4545f2014-07-11 19:49:46167 "//components/webdata/common",
sdefresnecb955cd2014-12-15 23:21:56168 "//components/webdata_services",
drogerf8479942014-11-21 17:47:53169 "//components/web_resource",
[email protected]dffd8a912014-06-30 23:24:31170 "//content/public/browser",
171 "//content/public/common",
[email protected]604828c2014-07-02 20:39:12172 "//courgette:courgette_lib",
[email protected]dffd8a912014-06-30 23:24:31173 "//crypto",
[email protected]604828c2014-07-02 20:39:12174 "//google_apis",
Brett Wilson8f1323042014-09-11 16:58:56175 "//gpu/config",
[email protected]dffd8a912014-06-30 23:24:31176 "//skia",
177 "//sql",
178 "//sync",
[email protected]797b25042014-07-01 23:54:17179 "//third_party/cacheinvalidation",
[email protected]dffd8a912014-06-30 23:24:31180 "//third_party/icu",
181 "//third_party/libxml",
ajwongf7b1cb692014-08-23 21:36:22182 "//third_party/libjingle",
[email protected]dffd8a912014-06-30 23:24:31183 "//third_party/widevine/cdm:version_h",
184 "//third_party/zlib",
185 "//third_party/zlib:minizip",
186 "//third_party/zlib:zip",
187 "//ui/base",
cjhopman09981a92014-10-27 17:11:18188 "//ui/events:events_base",
[email protected]dffd8a912014-06-30 23:24:31189 "//ui/gfx",
190 "//ui/gfx/geometry",
[email protected]a1d7d4f2014-07-16 21:33:36191 "//ui/message_center",
192 "//ui/shell_dialogs",
[email protected]dffd8a912014-06-30 23:24:31193 "//ui/strings",
[email protected]797b25042014-07-01 23:54:17194 "//ui/resources",
[email protected]dffd8a912014-06-30 23:24:31195 ]
196
scottmga266f952014-12-03 20:47:10197 sources +=
198 rebase_path(gypi_values.chrome_browser_undo_sources, ".", "//chrome")
danduongd81789642014-09-23 02:50:00199
[email protected]dffd8a912014-06-30 23:24:31200 if (!is_ios) {
scottmga266f952014-12-03 20:47:10201 sources +=
202 rebase_path(gypi_values.chrome_browser_non_ios_sources, ".", "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59203 sources += rebase_path(gypi_values.chrome_browser_autocomplete_sources,
scottmga266f952014-12-03 20:47:10204 ".",
205 "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59206 sources += rebase_path(gypi_values.chrome_browser_bookmark_sources,
scottmga266f952014-12-03 20:47:10207 ".",
208 "//chrome")
stuartmorgan997cf23d2014-12-04 21:01:18209 sources += rebase_path(gypi_values.chrome_browser_browser_process_sources,
210 ".",
211 "//chrome")
212 sources += rebase_path(gypi_values.chrome_browser_content_settings_sources,
213 ".",
214 "//chrome")
benwellsedf5e082015-04-23 02:45:14215 sources += rebase_path(gypi_values.chrome_browser_engagement_sources,
216 ".",
217 "//chrome")
scottmga266f952014-12-03 20:47:10218 sources +=
219 rebase_path(gypi_values.chrome_browser_favicon_sources, ".", "//chrome")
220 sources +=
221 rebase_path(gypi_values.chrome_browser_google_sources, ".", "//chrome")
222 sources +=
223 rebase_path(gypi_values.chrome_browser_history_sources, ".", "//chrome")
224 sources +=
225 rebase_path(gypi_values.chrome_browser_metrics_sources, ".", "//chrome")
226 sources +=
227 rebase_path(gypi_values.chrome_browser_net_sources, ".", "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59228 sources += rebase_path(gypi_values.chrome_browser_password_manager_sources,
scottmga266f952014-12-03 20:47:10229 ".",
230 "//chrome")
mlamouri4e372022015-03-29 14:51:06231 sources += rebase_path(gypi_values.chrome_browser_permissions_sources,
232 ".",
233 "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59234 sources += rebase_path(gypi_values.chrome_browser_predictor_sources,
scottmga266f952014-12-03 20:47:10235 ".",
236 "//chrome")
237 sources +=
238 rebase_path(gypi_values.chrome_browser_pref_sources, ".", "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59239 sources += rebase_path(gypi_values.chrome_browser_profiles_sources,
scottmga266f952014-12-03 20:47:10240 ".",
241 "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59242 sources += rebase_path(gypi_values.chrome_browser_search_engines_sources,
scottmga266f952014-12-03 20:47:10243 ".",
244 "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59245 sources += rebase_path(gypi_values.chrome_browser_services_sources,
scottmga266f952014-12-03 20:47:10246 ".",
247 "//chrome")
248 sources +=
stuartmorgan997cf23d2014-12-04 21:01:18249 rebase_path(gypi_values.chrome_browser_session_sources, ".", "//chrome")
250 sources +=
scottmga266f952014-12-03 20:47:10251 rebase_path(gypi_values.chrome_browser_signin_sources, ".", "//chrome")
252 sources +=
stuartmorgan997cf23d2014-12-04 21:01:18253 rebase_path(gypi_values.chrome_browser_ssl_sources, ".", "//chrome")
254 sources +=
scottmga266f952014-12-03 20:47:10255 rebase_path(gypi_values.chrome_browser_sync_sources, ".", "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59256 sources += rebase_path(gypi_values.chrome_browser_web_resource_sources,
scottmga266f952014-12-03 20:47:10257 ".",
258 "//chrome")
259
[email protected]dffd8a912014-06-30 23:24:31260 deps += [
Brett Wilson1c693992014-08-25 19:10:01261 "//apps",
[email protected]dffd8a912014-06-30 23:24:31262 "//cc",
brettwca934582015-02-24 21:50:27263 "//chrome/app:generated_resources_map",
264 "//chrome/app/theme:theme_resources",
[email protected]55699f392014-08-20 22:16:30265 "//chrome/browser/devtools",
brettwca934582015-02-24 21:50:27266 "//chrome/browser/resources:component_extension_resources",
tfarina04d426612015-08-18 16:42:33267 "//chrome/common/net",
[email protected]55699f392014-08-20 22:16:30268 "//chrome/installer/util",
jitendra.ks4f2e9112015-08-14 11:40:26269 "//components/about_handler",
oshimaf65398422014-11-18 23:30:42270 "//components/app_modal",
[email protected]b9f4c682014-07-10 22:00:37271 "//components/autofill/content/browser",
lazyboy14082d22015-04-02 01:04:58272 "//components/browsing_data",
jeremyim364ac1182015-03-03 18:49:43273 "//components/data_reduction_proxy/content/browser",
dgozmanec2b982a2015-04-28 10:36:39274 "//components/devtools_discovery",
dgozman102fee92015-04-20 15:45:46275 "//components/devtools_http_handler",
mdjones1c47b052015-07-22 19:15:39276 "//components/dom_distiller/content:content_browser",
sdefresne001b10de2015-03-20 18:41:46277 "//components/favicon/content",
sdefresne715246622015-01-12 16:24:04278 "//components/history/content/browser",
[email protected]fca567b2014-07-02 17:37:34279 "//components/keyed_service/content",
[email protected]55699f392014-08-20 22:16:30280 "//components/navigation_interception",
281 "//components/password_manager/content/browser",
vabr5410d0b2015-08-07 11:02:04282 "//components/password_manager/sync/browser",
dbeam155ac972015-04-20 15:34:48283 "//components/plugins/common",
bauerbf0e64aa2015-06-25 15:54:07284 "//components/safe_json",
brettwa22cb3b2015-04-30 20:23:12285 "//components/sessions",
[email protected]abd4b682014-07-16 20:26:30286 "//components/storage_monitor",
[email protected]b9f4c682014-07-10 22:00:37287 "//components/translate/content/browser",
sdefresne44eb1f22015-08-06 08:51:55288 "//components/upload_list",
[email protected]fca567b2014-07-02 17:37:34289 "//components/url_matcher",
[email protected]dffd8a912014-06-30 23:24:31290 "//components/visitedlink/browser",
291 "//components/visitedlink/common",
hanxi149b92d2014-09-11 21:57:18292 "//components/web_cache/browser",
[email protected]b9f4c682014-07-10 22:00:37293 "//components/web_modal",
[email protected]a9ca8d52014-08-22 10:21:08294 "//content/app/resources",
[email protected]55699f392014-08-20 22:16:30295 "//media",
rockot50dc5692015-07-08 01:57:26296 "//mojo/application/public/cpp",
cjhopman09981a92014-10-27 17:11:18297 "//mojo/common",
[email protected]604828c2014-07-02 20:39:12298 "//mojo/environment:chromium",
Brett Wilson83fd4242014-09-02 19:45:33299 "//net:extras",
[email protected]dffd8a912014-06-30 23:24:31300 "//net:net_with_v8",
pilgrim4af8c212014-09-05 17:30:15301 "//storage/browser",
pilgrimf55d19fc2014-09-04 00:05:24302 "//storage/common",
erga3c614c92015-04-03 17:47:51303 "//third_party/WebKit/public:image_resources",
[email protected]4eebe74d2014-08-13 02:54:46304 "//third_party/WebKit/public:resources",
[email protected]dffd8a912014-06-30 23:24:31305 "//third_party/leveldatabase",
[email protected]fca567b2014-07-02 17:37:34306 "//third_party/libaddressinput",
[email protected]dffd8a912014-06-30 23:24:31307 "//third_party/libyuv",
blundell70fb547672015-01-19 17:18:33308 "//third_party/mojo/src/mojo/edk/system",
309 "//third_party/mojo/src/mojo/public/cpp/bindings",
310 "//third_party/mojo/src/mojo/public/js",
[email protected]dffd8a912014-06-30 23:24:31311 "//third_party/re2",
312 "//third_party/smhasher:cityhash",
Brett Wilson83fd4242014-09-02 19:45:33313 "//third_party/webrtc/modules/desktop_capture",
spang1c36fac2015-02-05 19:55:12314 "//ui/base/ime",
[email protected]dffd8a912014-06-30 23:24:31315 "//ui/gl",
brettwca934582015-02-24 21:50:27316 "//ui/resources",
[email protected]dffd8a912014-06-30 23:24:31317 "//ui/surface",
[email protected]604828c2014-07-02 20:39:12318 "//ui/web_dialogs",
[email protected]fca567b2014-07-02 17:37:34319 "//v8",
[email protected]dffd8a912014-06-30 23:24:31320 ]
paulmeyer27b328b2015-06-17 21:26:12321
322 if (toolkit_views) {
323 deps += [ "//ui/views" ]
324 }
[email protected]dffd8a912014-06-30 23:24:31325 } else { # iOS
scottmga266f952014-12-03 20:47:10326 sources +=
327 rebase_path(gypi_values.chrome_browser_ios_sources, ".", "//chrome")
328 sources +=
329 rebase_path(gypi_values.chrome_browser_google_sources, ".", "//chrome")
330 deps += [ "//net" ]
[email protected]dffd8a912014-06-30 23:24:31331 libs += [
332 "CoreTelephony.framework",
333 "CoreText.framework",
334 "MobileCoreServices.framework",
335 "QuartzCore.framework",
336 ]
scottmga266f952014-12-03 20:47:10337 ldflags += [
338 "-weak_framework",
339 "CoreImage",
340 ]
[email protected]dffd8a912014-06-30 23:24:31341 }
342
343 if (is_win || is_mac) {
scottmga266f952014-12-03 20:47:10344 sources +=
345 rebase_path(gypi_values.chrome_browser_win_mac_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31346 }
mmenkede134672015-08-18 01:33:39347 if (!is_win && !is_mac && !is_ios) {
348 sources += [ "net/net_error_diagnostics_dialog_generic.cc" ]
349 }
[email protected]dffd8a912014-06-30 23:24:31350 if (!is_android && !is_ios && !is_chromeos && enable_configuration_policy) {
351 sources += [
352 "net/disk_cache_dir_policy_handler.cc",
353 "net/disk_cache_dir_policy_handler.h",
354 ]
355 }
356 if (!is_android && !is_ios && enable_configuration_policy) {
357 sources += [
358 "download/download_dir_policy_handler.cc",
359 "download/download_dir_policy_handler.h",
360 ]
361 }
362 if (is_mac) {
scottmga266f952014-12-03 20:47:10363 sources +=
364 rebase_path(gypi_values.chrome_browser_mac_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31365 deps += [
brettw624c82d2015-07-23 00:31:50366 #"app_shim" TODO(GYP) bug 512600
367 #"browser_app_shim" TODO(GYP) bug 512600
[email protected]dffd8a912014-06-30 23:24:31368 ]
369 }
[email protected]dffd8a912014-06-30 23:24:31370 if (enable_extensions) {
Brett Wilsone53895272014-09-23 23:41:46371 public_deps += [ "//chrome/browser/extensions" ]
[email protected]cc5b3be2014-08-15 23:24:52372 deps += [
[email protected]cc5b3be2014-08-15 23:24:52373 "//chrome/browser/sync_file_system/drive_backend:sync_file_system_drive_proto",
thestige33aa2422014-09-22 22:16:30374 "//chrome/common/extensions/api",
375 "//chrome/common/extensions/api:api_registration",
lukasza8acc4eb2015-07-20 20:57:20376 "//components/drive:drive",
msarda4c408ff2015-04-22 14:27:56377 "//components/proximity_auth/ble",
tengs4758c082014-12-19 18:51:44378 "//components/proximity_auth/cryptauth",
oshima758abebc2014-11-06 10:55:50379 "//extensions/components/javascript_dialog_extensions_client",
thestig73f4cdc2015-01-15 01:51:06380 "//media/cast:net",
[email protected]cc5b3be2014-08-15 23:24:52381 ]
[email protected]dffd8a912014-06-30 23:24:31382 sources += rebase_path(gypi_values.chrome_browser_extensions_sources,
scottmga266f952014-12-03 20:47:10383 ".",
384 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31385 }
386 if (enable_background) {
387 sources += rebase_path(gypi_values.chrome_browser_background_sources,
scottmga266f952014-12-03 20:47:10388 ".",
389 "//chrome")
jamesr29ea2d122014-10-23 10:30:27390 if (!use_aura || is_win || is_chromeos) {
[email protected]dffd8a912014-06-30 23:24:31391 sources -= [ "background/background_mode_manager_aura.cc" ]
392 }
393 }
394 if (enable_task_manager) {
395 sources += rebase_path(gypi_values.chrome_browser_task_manager_sources,
scottmga266f952014-12-03 20:47:10396 ".",
397 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31398 }
399 if (enable_spellcheck) {
400 sources += rebase_path(gypi_values.chrome_browser_spellchecker_sources,
scottmga266f952014-12-03 20:47:10401 ".",
402 "//chrome")
dylanking34c72442015-07-23 23:19:58403 if (!is_android) {
404 deps += [ "//third_party/hunspell" ]
405 }
[email protected]dffd8a912014-06-30 23:24:31406 }
407 if (enable_nacl) {
scottmga266f952014-12-03 20:47:10408 sources +=
409 rebase_path(gypi_values.chrome_browser_nacl_sources, ".", "//chrome")
dpranke6065cf72015-02-26 03:30:58410 deps += [ "//components/nacl:nacl_browser" ]
[email protected]dffd8a912014-06-30 23:24:31411 }
apavlove749bca2014-09-30 11:07:41412
[email protected]dffd8a912014-06-30 23:24:31413 if (enable_configuration_policy) {
scottmga266f952014-12-03 20:47:10414 sources +=
415 rebase_path(gypi_values.chrome_browser_policy_shared_with_ios_sources,
416 ".",
417 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31418 deps += [
[email protected]604828c2014-07-02 20:39:12419 "//components/policy",
[email protected]797b25042014-07-01 23:54:17420 "//components/policy/proto",
[email protected]dffd8a912014-06-30 23:24:31421 ]
422 if (!is_ios) {
scottmga266f952014-12-03 20:47:10423 sources += rebase_path(gypi_values.chrome_browser_policy_non_ios_sources,
424 ".",
425 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31426 }
427 if (!is_chromeos) {
428 sources += rebase_path(
scottmga266f952014-12-03 20:47:10429 gypi_values.chrome_browser_policy_shared_with_ios_not_chromeos_sources,
430 ".",
431 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31432 }
433 if (is_win || is_mac || is_desktop_linux) {
434 sources += rebase_path(gypi_values.chrome_browser_policy_desktop_sources,
scottmga266f952014-12-03 20:47:10435 ".",
436 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31437 }
cjhopman09981a92014-10-27 17:11:18438 if (is_android || is_ios) {
439 sources += rebase_path(gypi_values.chrome_browser_policy_mobile_sources,
scottmga266f952014-12-03 20:47:10440 ".",
441 "//chrome")
cjhopman09981a92014-10-27 17:11:18442 } else {
amistry6e1ed1b2015-03-12 05:24:01443 deps += [
444 "//chrome/browser/policy:path_parser",
445 "//net:net_browser_services",
446 ]
[email protected]dffd8a912014-06-30 23:24:31447 }
448 } else {
449 # Configuration policy disabled.
450 sources += rebase_path(gypi_values.chrome_browser_policy_disabled_sources,
scottmga266f952014-12-03 20:47:10451 ".",
452 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31453 }
454
455 if (enable_plugins) {
scottmga266f952014-12-03 20:47:10456 sources +=
457 rebase_path(gypi_values.chrome_browser_plugins_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31458 deps += [
James Robinson2ed4d692014-09-17 05:20:58459 "//components/pdf/browser",
brettwf7eb6ca2015-02-14 01:37:31460 "//ppapi/proxy:ipc",
thestig11b815e92014-08-26 00:32:14461 "//third_party/adobe/flash:flapper_version_h",
[email protected]dffd8a912014-06-30 23:24:31462 ]
463 }
464 if (safe_browsing_mode != 0) {
scottmga266f952014-12-03 20:47:10465 sources +=
stuartmorgan1b3df822014-12-08 14:36:11466 rebase_path(gypi_values.chrome_browser_safe_browsing_basic_sources,
scottmga266f952014-12-03 20:47:10467 ".",
468 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31469 deps += [
[email protected]fca567b2014-07-02 17:37:34470 "//chrome/browser/safe_browsing:chunk_proto",
mattm022138b52014-09-23 01:05:45471 "//chrome/browser/safe_browsing:metadata_proto",
[email protected]fca567b2014-07-02 17:37:34472 "//chrome/browser/safe_browsing:report_proto",
[email protected]dffd8a912014-06-30 23:24:31473 ]
474 if (safe_browsing_mode == 1) {
scottmga266f952014-12-03 20:47:10475 sources +=
stuartmorgan1b3df822014-12-08 14:36:11476 rebase_path(gypi_values.chrome_browser_safe_browsing_full_sources,
scottmga266f952014-12-03 20:47:10477 ".",
478 "//chrome")
scottmga266f952014-12-03 20:47:10479 deps += [ "//chrome/common/safe_browsing:proto" ]
nparkerb2cd5ee2015-05-13 01:12:01480 } else if (safe_browsing_mode == 3) {
481 sources += rebase_path(
482 gypi_values.chrome_browser_safe_browsing_mobile_extended_sources,
483 ".",
484 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31485 }
486 }
487
amistryf269d3b2015-06-09 19:18:39488 if (enable_hotwording) {
489 defines += [ "ENABLE_HOTWORDING" ]
490 }
491
[email protected]dffd8a912014-06-30 23:24:31492 if (is_linux) {
thestigee816c272014-11-22 02:47:51493 deps += [
494 "//device/media_transfer_protocol",
scottmga266f952014-12-03 20:47:10495 "//device/udev_linux",
thestigee816c272014-11-22 02:47:51496 ]
[email protected]dffd8a912014-06-30 23:24:31497 }
498 if (is_linux && !is_chromeos) {
[email protected]fd98b612014-07-09 22:11:47499 deps += [ "//third_party/speech-dispatcher" ]
[email protected]dffd8a912014-06-30 23:24:31500 }
501
502 if (is_chromeos) {
503 sources += rebase_path(gypi_values.chrome_browser_chromeos_sources,
scottmga266f952014-12-03 20:47:10504 ".",
505 "//chrome")
506 deps += [ "//chrome/browser/chromeos" ]
[email protected]dffd8a912014-06-30 23:24:31507 } else {
508 # Non-ChromeOS.
509 sources += rebase_path(gypi_values.chrome_browser_non_chromeos_sources,
scottmga266f952014-12-03 20:47:10510 ".",
511 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31512 }
513
yiyaoliubcd08dc22014-12-10 05:56:10514 if (is_ios) {
515 sources -= [
516 "metrics/signin_status_metrics_provider_base.cc",
517 "metrics/signin_status_metrics_provider_base.h",
518 ]
519 }
520
mukai8c99b882014-10-15 03:07:59521 if (is_chromeos || is_ios) {
522 sources -= [
523 "metrics/signin_status_metrics_provider.cc",
524 "metrics/signin_status_metrics_provider.h",
525 ]
526 }
527
[email protected]dffd8a912014-06-30 23:24:31528 if (use_cups) {
[email protected]604828c2014-07-02 20:39:12529 configs += [ "//printing:cups" ]
[email protected]dffd8a912014-06-30 23:24:31530 }
531 if (is_desktop_linux) {
532 sources += rebase_path(gypi_values.chrome_browser_gnome_keyring_sources,
scottmga266f952014-12-03 20:47:10533 ".",
534 "//chrome")
cmasone0a9e4ca2014-10-16 16:40:49535 configs += [ ":gnome_keyring" ]
[email protected]dffd8a912014-06-30 23:24:31536 }
dvadym34532022015-01-22 15:42:51537 if (is_desktop_linux) {
538 sources += rebase_path(gypi_values.chrome_browser_libsecret_sources,
539 ".",
540 "//chrome")
541 defines += [ "USE_LIBSECRET" ]
542 }
[email protected]dffd8a912014-06-30 23:24:31543 if (use_aura) {
scottmga266f952014-12-03 20:47:10544 sources +=
545 rebase_path(gypi_values.chrome_browser_aura_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31546 deps += [
[email protected]fca567b2014-07-02 17:37:34547 "//ui/aura",
548 "//ui/compositor",
[email protected]604828c2014-07-02 20:39:12549 "//ui/keyboard",
[email protected]dffd8a912014-06-30 23:24:31550 ]
551 }
552 if (ui_compositor_image_transport) {
553 deps += [ "//ui/gl" ]
554 }
555
[email protected]855b7de2014-07-08 21:02:45556 if (use_ash) {
scottmga266f952014-12-03 20:47:10557 sources +=
558 rebase_path(gypi_values.chrome_browser_ash_sources, ".", "//chrome")
[email protected]855b7de2014-07-08 21:02:45559 }
560
[email protected]dffd8a912014-06-30 23:24:31561 if (use_x11) {
scottmga266f952014-12-03 20:47:10562 sources +=
563 rebase_path(gypi_values.chrome_browser_x11_sources, ".", "//chrome")
vchigrinbbc23e72015-01-21 22:49:23564 } else {
565 sources -= [ "password_manager/password_store_x.cc" ]
[email protected]dffd8a912014-06-30 23:24:31566 }
567 if (is_posix && !is_mac && !is_ios) {
568 sources += [
rseseka0a7a042014-09-18 23:59:20569 "//chrome/app/chrome_crash_reporter_client.cc",
570 "//chrome/app/chrome_crash_reporter_client.h",
[email protected]dffd8a912014-06-30 23:24:31571 ]
572 deps += [
Robert Sesekabcd8102014-08-27 16:12:44573 "//components/crash/app",
574 "//components/crash/browser",
[email protected]dffd8a912014-06-30 23:24:31575 ]
576 }
577 if (use_nss_certs) {
scottmga266f952014-12-03 20:47:10578 sources +=
579 rebase_path(gypi_values.chrome_browser_nss_sources, ".", "//chrome")
mukai8c99b882014-10-15 03:07:59580 if (is_chromeos) {
581 sources -= [ "net/nss_context_linux.cc" ]
582 }
[email protected]dffd8a912014-06-30 23:24:31583 }
584 if (enable_notifications) {
585 sources += rebase_path(gypi_values.chrome_browser_notifications_sources,
scottmga266f952014-12-03 20:47:10586 ".",
587 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31588 if (!is_android) {
589 sources += rebase_path(
stuartmorgan1b3df822014-12-08 14:36:11590 gypi_values.chrome_browser_notifications_non_android_sources,
scottmga266f952014-12-03 20:47:10591 ".",
592 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31593 }
594 }
595 if (enable_themes) {
scottmga266f952014-12-03 20:47:10596 sources +=
597 rebase_path(gypi_values.chrome_browser_themes_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31598 }
599
vitalybuka93eea402014-11-05 23:47:15600 if (enable_basic_printing || enable_print_preview) {
[email protected]dffd8a912014-06-30 23:24:31601 # Some form of printing support.
stuartmorgan1b3df822014-12-08 14:36:11602 sources += rebase_path(gypi_values.chrome_browser_printing_basic_sources,
scottmga266f952014-12-03 20:47:10603 ".",
604 "//chrome")
spang5cc72542015-08-04 19:47:11605 deps += [
606 "//printing",
brettwd649f6b2015-08-18 20:58:51607 "//components/printing/browser",
spang5cc72542015-08-04 19:47:11608 ]
609
vitalybuka36259ca2014-08-28 23:42:24610 if (is_win) {
[email protected]dffd8a912014-06-30 23:24:31611 sources += rebase_path(gypi_values.chrome_browser_printing_emf_sources,
scottmga266f952014-12-03 20:47:10612 ".",
613 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31614 }
vitalybuka93eea402014-11-05 23:47:15615 if (enable_print_preview) {
[email protected]dffd8a912014-06-30 23:24:31616 # Full printing on top of the above.
stuartmorgan1b3df822014-12-08 14:36:11617 sources += rebase_path(gypi_values.chrome_browser_printing_full_sources,
scottmga266f952014-12-03 20:47:10618 ".",
619 "//chrome")
vitalybuka93eea402014-11-05 23:47:15620 } else {
[email protected]dffd8a912014-06-30 23:24:31621 # Partial-only printing support.
scottmga266f952014-12-03 20:47:10622 sources +=
stuartmorgan1b3df822014-12-08 14:36:11623 rebase_path(gypi_values.chrome_browser_printing_basic_only_sources,
scottmga266f952014-12-03 20:47:10624 ".",
625 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31626 }
627 }
628 if (enable_captive_portal_detection) {
629 sources += rebase_path(gypi_values.chrome_browser_captive_portal_sources,
scottmga266f952014-12-03 20:47:10630 ".",
631 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31632 }
633 if (enable_session_service) {
634 sources += rebase_path(gypi_values.chrome_browser_session_service_sources,
scottmga266f952014-12-03 20:47:10635 ".",
636 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31637 }
638
thestigdc377202014-10-28 22:06:02639 if (!is_android && !is_ios && !is_chromeos) {
scottmga266f952014-12-03 20:47:10640 sources +=
641 rebase_path(gypi_values.chrome_browser_desktop_sources, ".", "//chrome")
thestigdc377202014-10-28 22:06:02642 }
643
[email protected]dffd8a912014-06-30 23:24:31644 if (is_android || is_ios) {
645 # Mobile.
scottmga266f952014-12-03 20:47:10646 sources +=
647 rebase_path(gypi_values.chrome_browser_mobile_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31648 } else {
649 # Non-mobile.
650 sources += rebase_path(gypi_values.chrome_browser_non_mobile_sources,
scottmga266f952014-12-03 20:47:10651 ".",
652 "//chrome")
reillyge471fab2014-08-29 01:58:43653 deps += [
sdefresnebbf563c2015-03-17 11:09:09654 "//components/feedback",
reillyge471fab2014-08-29 01:58:43655 "//device/core",
rockot50dc5692015-07-08 01:57:26656 "//device/devices_app/public/cpp",
657 "//device/devices_app/public/cpp:factory",
reillygd77718d2014-09-04 00:57:56658 "//device/usb",
reillyge471fab2014-08-29 01:58:43659 ]
[email protected]dffd8a912014-06-30 23:24:31660 }
661
fserb1c2db4c2015-07-16 17:14:49662 if (!is_official_build) {
663 sources += [
664 "search/local_files_ntp_source.cc",
665 "search/local_files_ntp_source.h",
666 ]
667 }
668
[email protected]dffd8a912014-06-30 23:24:31669 if (is_android) {
scottmga266f952014-12-03 20:47:10670 sources +=
671 rebase_path(gypi_values.chrome_browser_android_sources, ".", "//chrome")
twellingtoncaf0eb752015-06-01 16:19:50672 sources += rebase_path(gypi_values.chrome_browser_bookmark_android_sources,
673 ".",
674 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31675 deps += [
pkotwicz127726f2015-05-29 15:20:12676 ":client_discourse_context_proto",
677 ":delta_file_proto",
James Robinson2ed4d692014-09-17 05:20:58678 ":jni_headers",
[email protected]55699f392014-08-20 22:16:30679 "//components/cdm/browser",
cjhopman09981a92014-10-27 17:11:18680 "//components/enhanced_bookmarks",
twifkak8c9f7502015-06-25 02:12:57681 "//components/precache/content",
682 "//components/precache/core",
estadee37f8222014-11-07 21:35:22683 "//components/resources:components_resources",
mathiash3ecfdfa2015-04-13 15:06:07684 "//components/service_tab_launcher",
blundell11d93bc2015-07-31 12:33:12685 "//components/toolbar",
cjhopman09981a92014-10-27 17:11:18686 "//components/web_contents_delegate_android",
687 "//third_party/android_opengl/etc1",
fdegans34f31e272015-05-22 16:59:03688 "//third_party/android_tools:cpu_features",
twellington0bc61492015-01-30 20:14:13689 "//third_party/libaddressinput:util",
[email protected]dffd8a912014-06-30 23:24:31690 ]
691 deps -= [
[email protected]fca567b2014-07-02 17:37:34692 "//third_party/libaddressinput",
[email protected]abd4b682014-07-16 20:26:30693 "//components/storage_monitor",
[email protected]abd4b682014-07-16 20:26:30694 "//components/web_modal",
[email protected]dffd8a912014-06-30 23:24:31695 ]
megjablon5effca2e2015-02-13 23:54:07696 defines += [ "ENABLE_DATA_REDUCTION_PROXY_DEBUGGING" ]
rseseke59ea892015-03-19 22:27:44697
698 if (use_seccomp_bpf) {
699 defines += [ "USE_SECCOMP_BPF" ]
rsesek65d31352015-06-08 22:53:44700 deps += [ "//sandbox/linux:seccomp_bpf" ]
rseseke59ea892015-03-19 22:27:44701 }
[email protected]dffd8a912014-06-30 23:24:31702 }
703
704 if (is_mac) {
705 deps += [
[email protected]6b5d2f92014-07-30 00:40:03706 "//third_party/google_toolbox_for_mac",
tfarina22896302015-02-23 21:18:03707 "//third_party/mozilla",
[email protected]dffd8a912014-06-30 23:24:31708 ]
709 libs += [
710 "Accelerate.framework",
711 "AddressBook.framework",
712 "AudioUnit.framework",
713 "DiskArbitration.framework",
714 "IOKit.framework",
715 "ImageCaptureCore.framework",
716 "OpenGL.framework",
717 "QuartzCore.framework",
718 "SecurityInterface.framework",
719 ]
720 }
721
722 if (enable_rlz) {
sdefresned967d552015-07-16 08:34:35723 deps += [ ":rlz" ]
[email protected]dffd8a912014-06-30 23:24:31724 }
725
726 # TODO(GYP)
727 # Temporary fix to break the browser target into smaller chunks so it
728 # will link with goma builds.
729 #["OS=="win" and chromium_win_pch==0", {
730 # "msvs_shard": 4,
731 #}],
732
733 if (is_win) {
scottmga266f952014-12-03 20:47:10734 sources +=
735 rebase_path(gypi_values.chrome_browser_win_sources, ".", "//chrome")
Brett Wilsone53895272014-09-23 23:41:46736 public_deps += [
737 "//ui/views",
738 "//ui/views/controls/webview",
739 ]
[email protected]dffd8a912014-06-30 23:24:31740 deps += [
vchigrin9593e7a2015-01-27 10:08:19741 ":chrome_process_finder",
[email protected]55699f392014-08-20 22:16:30742 "//chrome:version_header",
743 "//chrome/installer/util:strings",
vchigrinf2b90aa2015-01-23 11:12:19744 "//chrome_elf",
745 "//chrome_elf:constants",
746 "//chrome_elf:dll_hash",
vchigrin61944ae2015-01-30 23:51:32747 "//components/browser_watcher",
748 "//components/browser_watcher:browser_watcher_client",
vchigrinbbc23e72015-01-21 22:49:23749 "//google_update",
[email protected]55699f392014-08-20 22:16:30750 "//third_party/iaccessible2",
751 "//third_party/isimpledom",
[email protected]dffd8a912014-06-30 23:24:31752 "//third_party/wtl",
vchigrin88ed6f42015-01-17 11:56:42753 "//ui/metro_viewer",
754 "//win8:metro_viewer",
[email protected]dffd8a912014-06-30 23:24:31755 ]
mmenkede134672015-08-18 01:33:39756
757 all_dependent_configs = [ ":browser_win_linker_flags" ]
758
grt235b3f092015-05-27 21:42:48759 if (!is_chrome_branded) {
760 deps -= [ "//google_update" ]
761 sources -= [
762 "google/did_run_updater_win.cc",
763 "google/did_run_updater_win.h",
764 "google/google_update_win.cc",
765 "google/google_update_win.h",
766 ]
767 }
[email protected]dffd8a912014-06-30 23:24:31768 } else {
769 # Non-Windows.
scottmga266f952014-12-03 20:47:10770 sources +=
771 rebase_path(gypi_values.chrome_browser_non_win_sources, ".", "//chrome")
[email protected]f6dc4ae2014-07-30 00:10:37772 if (toolkit_views) {
[email protected]dffd8a912014-06-30 23:24:31773 deps += [
scottmga266f952014-12-03 20:47:10774 "//ui/views",
775 "//ui/views/controls/webview",
[email protected]dffd8a912014-06-30 23:24:31776 ]
[email protected]dffd8a912014-06-30 23:24:31777 }
778 }
779
780 if (is_linux) {
scottmga266f952014-12-03 20:47:10781 sources +=
782 rebase_path(gypi_values.chrome_browser_linux_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31783 if (use_aura) {
784 configs += [
785 "//build/config/linux:dbus",
786 "//build/config/linux:fontconfig",
787 ]
scottmga266f952014-12-03 20:47:10788 deps += [ "//dbus" ]
[email protected]dffd8a912014-06-30 23:24:31789 }
790 if (use_x11) {
791 configs += [ "//build/config/linux:x11" ]
792 deps += [ "//ui/gfx/x" ]
793 }
794 }
795
796 if (is_desktop_linux) {
stuartmorgan7f569a822014-12-08 20:10:54797 sources += rebase_path(gypi_values.chrome_browser_linux_desktop_sources,
scottmga266f952014-12-03 20:47:10798 ".",
799 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31800 }
801 if (enable_plugin_installation) {
scottmga266f952014-12-03 20:47:10802 sources +=
803 rebase_path(gypi_values.chrome_browser_plugin_installation_sources,
804 ".",
805 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31806 }
807 if (enable_app_list) {
scottmga266f952014-12-03 20:47:10808 deps += [ "//ui/app_list" ]
[email protected]dffd8a912014-06-30 23:24:31809 }
treib87bb89cbb2014-12-01 16:01:47810 if (enable_supervised_users) {
scottmga266f952014-12-03 20:47:10811 sources += rebase_path(gypi_values.chrome_browser_supervised_user_sources,
812 ".",
813 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31814 }
bauerb7f3b8542015-06-29 19:56:19815 if (enable_supervised_users && !is_android && !is_ios) {
816 sources +=
817 rebase_path(gypi_values.chrome_browser_supervised_user_legacy_sources,
818 ".",
819 "//chrome")
820 }
treib87bb89cbb2014-12-01 16:01:47821 if (enable_supervised_users && enable_themes) {
thestig169a6362014-11-13 20:47:59822 sources += rebase_path(
scottmga266f952014-12-03 20:47:10823 gypi_values.chrome_browser_supervised_user_and_themes_sources,
824 ".",
825 "//chrome")
thestig169a6362014-11-13 20:47:59826 }
[email protected]dffd8a912014-06-30 23:24:31827 if (enable_webrtc) {
scottmga266f952014-12-03 20:47:10828 sources +=
829 rebase_path(gypi_values.chrome_browser_webrtc_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31830 }
831 if (enable_service_discovery) {
scottmga266f952014-12-03 20:47:10832 sources += rebase_path(gypi_values.chrome_browser_service_discovery_sources,
833 ".",
834 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31835 }
836 if (enable_mdns) {
scottmga266f952014-12-03 20:47:10837 sources +=
838 rebase_path(gypi_values.chrome_browser_mdns_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31839 }
840 if (!enable_autofill_dialog || is_android || is_ios) {
841 sources -= [
842 "autofill/validation_rules_storage_factory.cc",
843 "autofill/validation_rules_storage_factory.h",
844 ]
845 }
846 if (enable_wifi_bootstrapping) {
scottmga266f952014-12-03 20:47:10847 sources +=
848 rebase_path(gypi_values.chrome_browser_wifi_bootstrapping_sources,
849 ".",
850 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31851 if (is_win || is_mac) {
852 # TODO(brettw) as of this writing wifi bootstrapping is set on Windows
853 # and Mac, so this test is meaningless. Can we merge these lists?
854 sources += rebase_path(
stuartmorgan1b3df822014-12-08 14:36:11855 gypi_values.chrome_browser_wifi_bootstrapping_win_mac_sources,
scottmga266f952014-12-03 20:47:10856 ".",
857 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31858 }
859 }
mfoltz150bb8b2015-04-09 22:30:05860 if (enable_media_router) {
imchengb6b09239f2015-05-15 21:41:55861 deps += [ "//chrome/browser/media/router" ]
mfoltz150bb8b2015-04-09 22:30:05862 }
[email protected]dffd8a912014-06-30 23:24:31863}
864
James Robinson2ed4d692014-09-17 05:20:58865if (is_android) {
866 # GYP version: chrome/chrome_browser.gypi:chrome_browser_jni_headers
867 generate_jni("jni_headers") {
scottmga266f952014-12-03 20:47:10868 sources =
869 rebase_path(gypi_values.chrome_browser_jni_sources, ".", "//chrome")
James Robinson2ed4d692014-09-17 05:20:58870 jni_package = "chrome"
871 }
pkotwicz127726f2015-05-29 15:20:12872
873 #GYP: '//chrome/chrome_browser.gypi:client_discourse_context_proto'
874 proto_library("client_discourse_context_proto") {
875 sources = [
876 "android/proto/client_discourse_context.proto",
877 ]
878 }
879
880 #GYP: '//chrome/chrome_browser.gypi:delta_file_proto'
881 proto_library("delta_file_proto") {
882 sources = [
883 "android/proto/delta_file.proto",
884 ]
885 }
James Robinson2ed4d692014-09-17 05:20:58886}
887
vchigrin9593e7a2015-01-27 10:08:19888if (is_win) {
889 source_set("chrome_process_finder") {
890 sources = [
891 "chrome_process_finder_win.cc",
892 "chrome_process_finder_win.h",
893 ]
894 deps = [
895 "//base",
896 "//chrome/browser/metro_utils",
897 "//chrome/common:constants",
898 ]
899 if (enable_configuration_policy) {
900 deps += [ "//chrome/browser/policy:path_parser" ]
901 }
902 }
903}
904
[email protected]77ce8022014-06-16 19:29:56905# GYP version: chrome/chrome_resources.gyp:chrome_resources
906# (generate_browser_resources action)
907grit("resources") {
908 source = "browser_resources.grd"
[email protected]48885492014-08-13 11:22:41909 output_dir = "$root_gen_dir/chrome"
[email protected]cb0c67a2014-07-22 16:37:26910 outputs = [
911 "grit/browser_resources.h",
912 "browser_resources.pak",
913 ]
[email protected]77ce8022014-06-16 19:29:56914
scottmga266f952014-12-03 20:47:10915 omnibox_mojom_file =
916 "$root_gen_dir/chrome/browser/ui/webui/omnibox/omnibox.mojom.js"
[email protected]77ce8022014-06-16 19:29:56917
918 grit_flags = [
scottmga266f952014-12-03 20:47:10919 "-E",
920 "about_credits_file=" + rebase_path(about_credits_file, root_build_dir),
921 "-E",
922 "additional_modules_list_file=" +
923 rebase_path(additional_modules_list_file, root_build_dir),
924 "-E",
925 "omnibox_mojom_file=" + rebase_path(omnibox_mojom_file, root_build_dir),
[email protected]77ce8022014-06-16 19:29:56926 ]
927
928 deps = [
929 ":about_credits",
930 ":chrome_internal_resources_gen",
brettwde262b02015-05-27 19:41:42931
932 # Depend only on the generated mojo bindings since we read the .mojom.js
933 # file, rather than the whole mojo target which will link the C++ bindings.
934 "//chrome/browser/ui/webui/omnibox:mojo_bindings__generator",
vchigrin8eede942015-01-29 09:28:15935 ]
936 inputs = [
937 omnibox_mojom_file,
[email protected]77ce8022014-06-16 19:29:56938 ]
939}
940
941# GYP version: chrome/chrome_resource.gyp:about_credits
942action("about_credits") {
943 script = "//tools/licenses.py"
944
dbeamc7776c72014-12-17 02:24:05945 inputs = [
946 # This is not a complete list. TODO(phajdan.jr, dbeam): licenses.py needs to
947 # generate a .d file with all the licenses/credits that about:credits uses.
948 # Then about:credits will automatically rebuild when one of them changes.
949 # See: depfile in gn's documentation (gn help depfile).
950 "resources/about_credits.tmpl",
951 "resources/about_credits_entry.tmpl",
952 ]
953
scottmga266f952014-12-03 20:47:10954 outputs = [
955 about_credits_file,
956 ]
[email protected]77ce8022014-06-16 19:29:56957
958 args = [
959 "credits",
960 rebase_path(about_credits_file, root_build_dir),
961 ]
962}
963
964# GYP version: chrome/chrome_resource.gyp:chrome_internal_resources_gen
engedy99d0e11b2014-09-30 13:32:41965if (is_chrome_branded) {
[email protected]77ce8022014-06-16 19:29:56966 action("chrome_internal_resources_gen") {
engedy99d0e11b2014-09-30 13:32:41967 script = "internal/transform_additional_modules_list.py"
scottmga266f952014-12-03 20:47:10968 sources = [
969 "internal/resources/additional_modules_list.input",
970 ]
971 outputs = [
972 additional_modules_list_file,
973 ]
engedy99d0e11b2014-09-30 13:32:41974 args = rebase_path(sources, root_build_dir) +
975 rebase_path(outputs, root_build_dir)
[email protected]77ce8022014-06-16 19:29:56976 }
977} else {
978 group("chrome_internal_resources_gen") {
979 # Empty placeholder.
980 }
981}
Brett Wilson052ce132014-09-12 19:46:29982
983# In GYP this is part of test_support_common.
984source_set("test_support") {
985 testonly = true
986
987 # Always include this via the main test support target.
988 visibility = [ "//chrome/test:test_support" ]
989
990 sources = [
991 "browsing_data/mock_browsing_data_appcache_helper.cc",
992 "browsing_data/mock_browsing_data_appcache_helper.h",
993 "browsing_data/mock_browsing_data_channel_id_helper.cc",
994 "browsing_data/mock_browsing_data_channel_id_helper.h",
995 "browsing_data/mock_browsing_data_cookie_helper.cc",
996 "browsing_data/mock_browsing_data_cookie_helper.h",
997 "browsing_data/mock_browsing_data_database_helper.cc",
998 "browsing_data/mock_browsing_data_database_helper.h",
999 "browsing_data/mock_browsing_data_file_system_helper.cc",
1000 "browsing_data/mock_browsing_data_file_system_helper.h",
1001 "browsing_data/mock_browsing_data_flash_lso_helper.cc",
1002 "browsing_data/mock_browsing_data_flash_lso_helper.h",
1003 "browsing_data/mock_browsing_data_indexed_db_helper.cc",
1004 "browsing_data/mock_browsing_data_indexed_db_helper.h",
1005 "browsing_data/mock_browsing_data_local_storage_helper.cc",
1006 "browsing_data/mock_browsing_data_local_storage_helper.h",
1007 "browsing_data/mock_browsing_data_quota_helper.cc",
1008 "browsing_data/mock_browsing_data_quota_helper.h",
1009 "browsing_data/mock_browsing_data_service_worker_helper.cc",
1010 "browsing_data/mock_browsing_data_service_worker_helper.h",
1011 "download/download_test_file_activity_observer.cc",
1012 "download/download_test_file_activity_observer.h",
1013 "download/test_download_shelf.cc",
1014 "download/test_download_shelf.h",
Brett Wilson052ce132014-09-12 19:46:291015 "invalidation/fake_invalidation_service.cc",
1016 "invalidation/fake_invalidation_service.h",
1017 "media/fake_desktop_media_list.cc",
1018 "media/fake_desktop_media_list.h",
1019 "net/dns_probe_test_util.cc",
1020 "net/dns_probe_test_util.h",
1021 "net/url_request_mock_util.cc",
1022 "net/url_request_mock_util.h",
1023 "notifications/notification_test_util.cc",
1024 "notifications/notification_test_util.h",
1025 "password_manager/mock_password_store_service.cc",
1026 "password_manager/mock_password_store_service.h",
1027 "password_manager/null_password_store_service.cc",
1028 "password_manager/null_password_store_service.h",
gcasto686493e72015-07-08 23:53:481029 "password_manager/password_manager_test_base.cc",
1030 "password_manager/password_manager_test_base.h",
Brett Wilson052ce132014-09-12 19:46:291031 "password_manager/test_password_store_service.cc",
1032 "password_manager/test_password_store_service.h",
1033 "prefs/pref_service_mock_factory.cc",
1034 "prefs/pref_service_mock_factory.h",
1035 "profile_resetter/profile_resetter_test_base.cc",
1036 "profile_resetter/profile_resetter_test_base.h",
1037 "search_engines/template_url_service_factory_test_util.cc",
1038 "search_engines/template_url_service_factory_test_util.h",
1039 "search_engines/template_url_service_test_util.cc",
1040 "search_engines/template_url_service_test_util.h",
squef7d723a2015-01-26 22:13:451041 "sessions/session_restore_test_helper.cc",
1042 "sessions/session_restore_test_helper.h",
Brett Wilson052ce132014-09-12 19:46:291043 "sessions/session_service_test_helper.cc",
1044 "sessions/session_service_test_helper.h",
knn523bd722015-07-30 16:27:091045 "signin/fake_account_fetcher_service_builder.cc",
1046 "signin/fake_account_fetcher_service_builder.h",
mlerman2933d012015-04-24 18:34:271047 "signin/fake_gaia_cookie_manager_service.cc",
1048 "signin/fake_gaia_cookie_manager_service.h",
Brett Wilson052ce132014-09-12 19:46:291049 "signin/fake_profile_oauth2_token_service_builder.cc",
1050 "signin/fake_profile_oauth2_token_service_builder.h",
droger4f489e62015-07-24 19:27:591051 "signin/fake_signin_manager_builder.cc",
1052 "signin/fake_signin_manager_builder.h",
Brett Wilson052ce132014-09-12 19:46:291053 "ssl/ssl_client_auth_requestor_mock.cc",
1054 "ssl/ssl_client_auth_requestor_mock.h",
Brett Wilson052ce132014-09-12 19:46:291055 "sync/profile_sync_components_factory_mock.cc",
1056 "sync/profile_sync_components_factory_mock.h",
1057 "sync/profile_sync_service_mock.cc",
1058 "sync/profile_sync_service_mock.h",
shadi2f257fc2014-12-03 18:04:121059 "ui/webui/signin/login_ui_test_utils.cc",
1060 "ui/webui/signin/login_ui_test_utils.h",
Brett Wilson052ce132014-09-12 19:46:291061 ]
1062
brettwbc8b2a22015-07-28 18:24:421063 configs += [ "//build/config:precompiled_headers" ]
1064
Brett Wilsone53895272014-09-23 23:41:461065 public_deps = [
Brett Wilson052ce132014-09-12 19:46:291066 ":browser",
Brett Wilsone53895272014-09-23 23:41:461067 "//chrome/browser/ui:test_support",
1068 ]
1069 deps = [
Brett Wilson052ce132014-09-12 19:46:291070 "//base:prefs_test_support",
1071 "//chrome/browser",
Brett Wilson052ce132014-09-12 19:46:291072 "//chrome/common",
1073 "//chrome/common/safe_browsing:proto",
knn062cdbb2015-06-26 18:18:421074 "//components/invalidation/impl",
1075 "//components/invalidation/impl:test_support",
Brett Wilson052ce132014-09-12 19:46:291076 "//components/password_manager/core/browser:test_support",
1077 "//components/search_engines:test_support",
jitendra.ks94c0b962015-08-10 08:24:091078 "//components/user_prefs/tracked:user_prefs_tracked_test_support",
Brett Wilson052ce132014-09-12 19:46:291079 "//content/test:test_support",
1080 "//chrome/app/theme:theme_resources",
1081 "//net:test_support",
1082 "//skia",
1083 "//testing/gmock",
1084 "//testing/gtest",
1085 "//ui/gfx",
1086 ]
1087
Brett Wilson052ce132014-09-12 19:46:291088 if (!is_ios) {
1089 deps += [
1090 "//components/sessions:test_support",
Brett Wilson052ce132014-09-12 19:46:291091 "//google_apis:test_support",
1092 ]
1093 }
1094
James Robinson2ed4d692014-09-17 05:20:581095 if (enable_extensions) {
thestig52a87b3b2014-10-23 22:02:381096 sources += [
1097 "extensions/extension_action_test_util.cc",
1098 "extensions/extension_action_test_util.h",
1099 ]
scottmga266f952014-12-03 20:47:101100 deps += [ "//extensions:test_support" ]
James Robinson2ed4d692014-09-17 05:20:581101 }
1102
Brett Wilson052ce132014-09-12 19:46:291103 if (is_chromeos) {
1104 sources += [
1105 "chromeos/app_mode/fake_cws.cc",
1106 "chromeos/app_mode/fake_cws.h",
1107 "chromeos/file_manager/fake_disk_mount_manager.cc",
1108 "chromeos/file_manager/fake_disk_mount_manager.h",
1109 "chromeos/input_method/mock_candidate_window_controller.cc",
1110 "chromeos/input_method/mock_candidate_window_controller.h",
1111 "chromeos/input_method/mock_input_method_engine.cc",
1112 "chromeos/input_method/mock_input_method_engine.h",
1113 "chromeos/input_method/mock_input_method_manager.cc",
1114 "chromeos/input_method/mock_input_method_manager.h",
brettw7d6ec2462015-01-07 13:00:511115 "chromeos/login/screens/mock_device_disabled_screen_actor.cc",
1116 "chromeos/login/screens/mock_device_disabled_screen_actor.h",
nkostylev393309f2015-02-05 13:57:391117 "chromeos/login/session/user_session_manager_test_api.cc",
1118 "chromeos/login/session/user_session_manager_test_api.h",
Brett Wilson052ce132014-09-12 19:46:291119 "chromeos/login/test/js_checker.cc",
1120 "chromeos/login/test/js_checker.h",
satoruxb7a72ea2015-02-13 07:19:591121 "chromeos/login/test/oobe_screen_waiter.cc",
1122 "chromeos/login/test/oobe_screen_waiter.h",
Brett Wilson052ce132014-09-12 19:46:291123 "chromeos/login/ui/mock_login_display.cc",
1124 "chromeos/login/ui/mock_login_display.h",
1125 "chromeos/login/ui/mock_login_display_host.cc",
1126 "chromeos/login/ui/mock_login_display_host.h",
brettw7d6ec2462015-01-07 13:00:511127 "chromeos/login/users/avatar/mock_user_image_manager.cc",
1128 "chromeos/login/users/avatar/mock_user_image_manager.h",
merkulova793f3022015-02-04 10:18:301129 "chromeos/login/users/fake_chrome_user_manager.cc",
1130 "chromeos/login/users/fake_chrome_user_manager.h",
brettw7d6ec2462015-01-07 13:00:511131 "chromeos/login/users/fake_supervised_user_manager.cc",
1132 "chromeos/login/users/fake_supervised_user_manager.h",
brettw7d6ec2462015-01-07 13:00:511133 "chromeos/login/users/mock_user_manager.cc",
1134 "chromeos/login/users/mock_user_manager.h",
Brett Wilson052ce132014-09-12 19:46:291135 "chromeos/net/network_portal_detector_test_utils.cc",
1136 "chromeos/net/network_portal_detector_test_utils.h",
1137 "chromeos/policy/cloud_external_data_manager_base_test_util.cc",
1138 "chromeos/policy/cloud_external_data_manager_base_test_util.h",
1139 "chromeos/policy/device_policy_builder.cc",
1140 "chromeos/policy/device_policy_builder.h",
brettwa68ea2b2015-02-01 02:54:071141 "chromeos/policy/fake_consumer_management_service.cc",
1142 "chromeos/policy/fake_consumer_management_service.h",
Brett Wilson052ce132014-09-12 19:46:291143 "chromeos/policy/fake_device_cloud_policy_initializer.cc",
1144 "chromeos/policy/fake_device_cloud_policy_initializer.h",
brettwa68ea2b2015-02-01 02:54:071145 "chromeos/policy/fake_device_cloud_policy_manager.cc",
1146 "chromeos/policy/fake_device_cloud_policy_manager.h",
Brett Wilson052ce132014-09-12 19:46:291147 "chromeos/policy/stub_enterprise_install_attributes.cc",
1148 "chromeos/policy/stub_enterprise_install_attributes.h",
1149 "chromeos/settings/device_settings_test_helper.cc",
1150 "chromeos/settings/device_settings_test_helper.h",
1151 "chromeos/system/fake_input_device_settings.cc",
1152 "chromeos/system/fake_input_device_settings.h",
1153 ]
1154 configs += [ "//build/config/linux:dbus" ]
mukai6ba73552014-10-09 19:05:171155 deps += [ "//chromeos:test_support" ]
Brett Wilson052ce132014-09-12 19:46:291156 }
1157
1158 if (enable_configuration_policy) {
1159 sources += [
1160 "policy/test/local_policy_test_server.cc",
1161 "policy/test/local_policy_test_server.h",
1162 ]
Brett Wilsone53895272014-09-23 23:41:461163 public_deps += [
Brett Wilson052ce132014-09-12 19:46:291164 "//components/policy:policy_component_test_support",
1165 "//components/policy:test_support",
1166 ]
Brett Wilson052ce132014-09-12 19:46:291167 }
1168
1169 if (safe_browsing_mode == 1) {
1170 sources += [
1171 "extensions/fake_safe_browsing_database_manager.cc",
1172 "extensions/fake_safe_browsing_database_manager.h",
1173 ]
1174 }
1175
1176 if (enable_extensions) {
1177 sources += [
Brett Wilson052ce132014-09-12 19:46:291178 "extensions/api/messaging/native_messaging_test_util.cc",
1179 "extensions/api/messaging/native_messaging_test_util.h",
1180 "extensions/extension_notification_observer.cc",
1181 "extensions/extension_notification_observer.h",
Brett Wilson052ce132014-09-12 19:46:291182 "extensions/mock_extension_special_storage_policy.cc",
1183 "extensions/mock_extension_special_storage_policy.h",
1184 "extensions/test_blacklist.cc",
1185 "extensions/test_blacklist.h",
1186 "extensions/test_blacklist_state_fetcher.cc",
1187 "extensions/test_blacklist_state_fetcher.h",
brettw7d6ec2462015-01-07 13:00:511188 "extensions/test_extension_dir.cc",
1189 "extensions/test_extension_dir.h",
satoruxb7a72ea2015-02-13 07:19:591190 "extensions/test_extension_environment.cc",
1191 "extensions/test_extension_environment.h",
Brett Wilson052ce132014-09-12 19:46:291192 "extensions/test_extension_prefs.cc",
1193 "extensions/test_extension_prefs.h",
1194 "extensions/test_extension_service.cc",
1195 "extensions/test_extension_service.h",
1196 "extensions/test_extension_system.cc",
1197 "extensions/test_extension_system.h",
1198 "media_galleries/media_galleries_test_util.cc",
1199 "media_galleries/media_galleries_test_util.h",
1200 ]
lukasza8acc4eb2015-07-20 20:57:201201 deps += [
1202 "//components/drive:test_support",
1203 "//components/storage_monitor:test_support",
1204 ]
Brett Wilson052ce132014-09-12 19:46:291205 }
1206
1207 if (enable_mdns) {
1208 sources += [
1209 "local_discovery/test_service_discovery_client.cc",
1210 "local_discovery/test_service_discovery_client.h",
1211 ]
1212 }
1213
1214 if (enable_app_list) {
1215 sources += [
1216 "ui/app_list/test/chrome_app_list_test_support.cc",
1217 "ui/app_list/test/chrome_app_list_test_support.h",
brettw7d6ec2462015-01-07 13:00:511218 "ui/app_list/test/test_app_list_controller_delegate.cc",
1219 "ui/app_list/test/test_app_list_controller_delegate.h",
Brett Wilson052ce132014-09-12 19:46:291220 ]
1221 }
1222
1223 if (enable_wifi_bootstrapping) {
1224 sources += [
1225 "local_discovery/wifi/mock_wifi_manager.cc",
1226 "local_discovery/wifi/mock_wifi_manager.h",
1227 ]
1228 }
1229}
sdefresned967d552015-07-16 08:34:351230
1231if (enable_rlz_support) {
1232 source_set("rlz") {
1233 sources =
1234 rebase_path(gypi_values.chrome_browser_rlz_sources, ".", "//chrome")
1235 deps = [
1236 "//components/google/core/browser",
1237 "//components/omnibox/browser",
1238 "//components/rlz",
1239 "//components/search_engines",
1240 "//rlz:rlz_lib",
1241 ]
1242 }
1243}