blob: 783d064b4740344f3f2867d2490ba8dce1eb0bf5 [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:5629additional_modules_list_file =
30 "$root_gen_dir/chrome/browser/internal/additional_modules_list.txt"
31
scottmga266f952014-12-03 20:47:1032gypi_values = exec_script("//build/gypi_to_gn.py",
33 [ rebase_path("../chrome_browser.gypi") ],
34 "scope",
35 [ "../chrome_browser.gypi" ])
[email protected]dffd8a912014-06-30 23:24:3136
mmenkede134672015-08-18 01:33:3937if (is_win) {
38 # This is in a separate config so the flags can be applied to dependents.
39 # ldflags in GN aren't automatically inherited.
40 config("browser_win_linker_flags") {
41 libs = [
42 "credui.lib",
43 "netapi32.lib",
44 "ndfapi.lib", # Used by browser/net/net_error_diagnostics_dialog_win.h
45 ]
46 ldflags = [ "/DELAYLOAD:ndfapi.dll" ]
47 }
48}
49
cmasone0a9e4ca2014-10-16 16:40:4950if (is_desktop_linux) {
brettwa68ea2b2015-02-01 02:54:0751 # Gnome-keyring is normally dynamically loaded. The gnome_keyring config
52 # will set this up.
cmasone0a9e4ca2014-10-16 16:40:4953 pkg_config("gnome_keyring") {
54 packages = [ "gnome-keyring-1" ]
brettwa68ea2b2015-02-01 02:54:0755 defines = [
56 "USE_GNOME_KEYRING",
57 "DLOPEN_GNOME_KEYRING",
58 ]
59 ignore_libs = true
60 }
61
62 # If you want to link gnome-keyring directly (use only for unit tests)
63 # ADDITIONALLY add this config on top of ":gnome_keyring". pkg-config is a
64 # bit slow, so prefer not to run it again. In practice, gnome-keyring's libs
65 # are just itself and common gnome ones we link already, so we can get away
66 # with additionally just coding the library name here.
67 config("gnome_keyring_direct") {
68 libs = [ "gnome-keyring" ]
cmasone0a9e4ca2014-10-16 16:40:4969 }
70}
71
brettw44a5cf82015-04-08 19:48:2272source_set("browser") {
apavlove749bca2014-09-30 11:07:4173 configs += [
74 "//build/config/compiler:wexit_time_destructors",
brettwbc8b2a22015-07-28 18:24:4275 "//build/config:precompiled_headers",
apavlove749bca2014-09-30 11:07:4176 "//third_party/WebKit/public:debug_devtools",
77 ]
[email protected]dffd8a912014-06-30 23:24:3178 defines = []
79 sources = []
80 libs = []
81 ldflags = []
82
83 # iOS/non-iOS shared deps. New dependencies should generally be added in the
84 # non-iOS deps below.
Brett Wilsone53895272014-09-23 23:41:4685 public_deps = [
86 "//components/autofill/core/browser",
87 "//content/public/browser",
88 "//sql",
89 "//sync",
90 ]
[email protected]dffd8a912014-06-30 23:24:3191 deps = [
92 "//base/allocator",
93 "//chrome:extra_resources",
94 "//chrome:resources",
95 "//chrome:strings",
[email protected]855b7de2014-07-08 21:02:4596 "//chrome/app/resources:platform_locale_settings",
[email protected]797b25042014-07-01 23:54:1797 "//chrome/app/theme:theme_resources",
sdefresnea213ceb2015-10-05 09:23:3998 "//chrome/browser/metrics/variations:chrome_ui_string_overrider_factory",
[email protected]797b25042014-07-01 23:54:1799 "//chrome/browser/net:probe_message_proto",
[email protected]abd4b682014-07-16 20:26:30100 "//chrome/browser/ui",
[email protected]dffd8a912014-06-30 23:24:31101 "//chrome/common",
[email protected]604828c2014-07-02 20:39:12102 "//components/autofill/core/browser",
Brett Wilson1c693992014-08-25 19:10:01103 "//components/bookmarks/browser",
treiba9ea2fb2015-03-20 10:06:03104 "//components/bookmarks/managed",
[email protected]b9f4c682014-07-10 22:00:37105 "//components/captive_portal",
estark334673f42015-09-08 14:51:39106 "//components/certificate_reporting",
[email protected]fca567b2014-07-02 17:37:34107 "//components/cloud_devices/common",
Brett Wilson1c693992014-08-25 19:10:01108 "//components/component_updater",
blundell64fedf12015-08-25 12:22:27109 "//components/compression",
vabrfc325fa2015-04-10 16:24:45110 "//components/content_settings/content/common",
vasiliiac461392014-09-18 11:35:17111 "//components/content_settings/core/browser",
[email protected]08f71012014-07-25 10:27:54112 "//components/content_settings/core/common",
[email protected]478ed232014-08-19 02:10:55113 "//components/crx_file",
megjablon3476e042014-10-14 19:21:59114 "//components/data_reduction_proxy/core/browser",
amohammadkhanf76ae112015-09-14 17:34:43115 "//components/data_use_measurement/core",
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",
droger888be0b2015-10-01 14:28:52121 "//components/flags_ui",
[email protected]abd4b682014-07-16 20:26:30122 "//components/gcm_driver",
jianli2104ce612015-05-06 00:24:34123 "//components/gcm_driver/instance_id",
Brett Wilson1c693992014-08-25 19:10:01124 "//components/google/core/browser",
fsamuelaf5bf6d12015-05-28 16:29:54125 "//components/guest_view/browser",
erikchen332265b2014-11-14 19:59:52126 "//components/handoff",
[email protected]273ae5ab2014-07-09 21:10:25127 "//components/history/core/browser",
128 "//components/history/core/common",
Brett Wilson1c693992014-08-25 19:10:01129 "//components/infobars/core",
knn062cdbb2015-06-26 18:18:42130 "//components/invalidation/impl",
gunsch1afc65172014-09-16 00:03:32131 "//components/metrics:gpu",
[email protected]fca567b2014-07-02 17:37:34132 "//components/metrics:net",
gunsch840bc412014-09-18 19:38:06133 "//components/metrics:profiler",
Brett Wilson1c693992014-08-25 19:10:01134 "//components/metrics/proto:proto",
rsleevic327b48f82015-04-30 02:03:25135 "//components/mime_util",
[email protected]fca567b2014-07-02 17:37:34136 "//components/navigation_metrics",
Brett Wilson1c693992014-08-25 19:10:01137 "//components/network_time",
fgorskife7b92f2015-06-15 19:19:40138 "//components/offline_pages",
blundell2102f7c2015-07-09 10:00:53139 "//components/omnibox/browser",
[email protected]fca567b2014-07-02 17:37:34140 "//components/os_crypt",
haavardmdfdf28f2015-01-08 21:05:00141 "//components/packed_ct_ev_whitelist",
Brett Wilson1c693992014-08-25 19:10:01142 "//components/password_manager/core/browser",
143 "//components/password_manager/core/common",
[email protected]fca567b2014-07-02 17:37:34144 "//components/policy:policy_component",
stevenjbb237e2ae2015-07-02 22:02:11145 "//components/proxy_config",
[email protected]fca567b2014-07-02 17:37:34146 "//components/query_parser",
[email protected]b9f4c682014-07-10 22:00:37147 "//components/rappor",
Brett Wilson1c693992014-08-25 19:10:01148 "//components/renderer_context_menu",
[email protected]720b10492014-07-23 08:48:40149 "//components/search",
Brett Wilson1c693992014-08-25 19:10:01150 "//components/search_engines",
151 "//components/search_provider_logos",
felt20e0f2002015-07-31 15:27:36152 "//components/security_interstitials/core",
[email protected]abd4b682014-07-16 20:26:30153 "//components/signin/core/browser",
felt2493b4452015-09-17 20:33:59154 "//components/ssl_errors",
[email protected]abd4b682014-07-16 20:26:30155 "//components/startup_metric_utils",
[email protected]797b25042014-07-01 23:54:17156 "//components/strings",
mathp60143a32014-10-08 14:52:45157 "//components/suggestions",
Brett Wilson1c693992014-08-25 19:10:01158 "//components/sync_driver",
zhenwecedcf22015-08-18 23:37:46159 "//components/tracing:startup_tracing",
[email protected]b9f4c682014-07-10 22:00:37160 "//components/translate/core/browser",
161 "//components/translate/core/common",
brettw0741cb1c2015-08-21 22:06:00162 "//components/ui/zoom",
sdefresnec083d1f2015-04-17 21:12:18163 "//components/undo",
sorin39eab2f2015-01-06 01:09:08164 "//components/update_client",
rsleevi24f64dc22015-08-07 21:39:21165 "//components/url_formatter",
[email protected]fca567b2014-07-02 17:37:34166 "//components/user_prefs",
jitendra.ks94c0b962015-08-10 08:24:09167 "//components/user_prefs/tracked:user_prefs_tracked",
isherman3be67db2014-10-24 05:57:44168 "//components/variations",
169 "//components/variations/net",
blundellb50ad702015-08-27 17:08:29170 "//components/variations/service",
[email protected]bf4545f2014-07-11 19:49:46171 "//components/webdata/common",
sdefresnecb955cd2014-12-15 23:21:56172 "//components/webdata_services",
drogerf8479942014-11-21 17:47:53173 "//components/web_resource",
[email protected]dffd8a912014-06-30 23:24:31174 "//content/public/browser",
175 "//content/public/common",
[email protected]604828c2014-07-02 20:39:12176 "//courgette:courgette_lib",
[email protected]dffd8a912014-06-30 23:24:31177 "//crypto",
[email protected]604828c2014-07-02 20:39:12178 "//google_apis",
Brett Wilson8f1323042014-09-11 16:58:56179 "//gpu/config",
[email protected]dffd8a912014-06-30 23:24:31180 "//skia",
181 "//sql",
182 "//sync",
[email protected]797b25042014-07-01 23:54:17183 "//third_party/cacheinvalidation",
[email protected]dffd8a912014-06-30 23:24:31184 "//third_party/icu",
185 "//third_party/libxml",
ajwongf7b1cb692014-08-23 21:36:22186 "//third_party/libjingle",
[email protected]dffd8a912014-06-30 23:24:31187 "//third_party/widevine/cdm:version_h",
188 "//third_party/zlib",
189 "//third_party/zlib:minizip",
190 "//third_party/zlib:zip",
191 "//ui/base",
cjhopman09981a92014-10-27 17:11:18192 "//ui/events:events_base",
[email protected]dffd8a912014-06-30 23:24:31193 "//ui/gfx",
194 "//ui/gfx/geometry",
[email protected]a1d7d4f2014-07-16 21:33:36195 "//ui/message_center",
196 "//ui/shell_dialogs",
[email protected]dffd8a912014-06-30 23:24:31197 "//ui/strings",
[email protected]797b25042014-07-01 23:54:17198 "//ui/resources",
[email protected]dffd8a912014-06-30 23:24:31199 ]
200
scottmga266f952014-12-03 20:47:10201 sources +=
202 rebase_path(gypi_values.chrome_browser_undo_sources, ".", "//chrome")
danduongd81789642014-09-23 02:50:00203
[email protected]dffd8a912014-06-30 23:24:31204 if (!is_ios) {
scottmga266f952014-12-03 20:47:10205 sources +=
206 rebase_path(gypi_values.chrome_browser_non_ios_sources, ".", "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59207 sources += rebase_path(gypi_values.chrome_browser_autocomplete_sources,
scottmga266f952014-12-03 20:47:10208 ".",
209 "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59210 sources += rebase_path(gypi_values.chrome_browser_bookmark_sources,
scottmga266f952014-12-03 20:47:10211 ".",
212 "//chrome")
stuartmorgan997cf23d2014-12-04 21:01:18213 sources += rebase_path(gypi_values.chrome_browser_browser_process_sources,
214 ".",
215 "//chrome")
216 sources += rebase_path(gypi_values.chrome_browser_content_settings_sources,
217 ".",
218 "//chrome")
benwellsedf5e082015-04-23 02:45:14219 sources += rebase_path(gypi_values.chrome_browser_engagement_sources,
220 ".",
221 "//chrome")
scottmga266f952014-12-03 20:47:10222 sources +=
223 rebase_path(gypi_values.chrome_browser_favicon_sources, ".", "//chrome")
224 sources +=
225 rebase_path(gypi_values.chrome_browser_google_sources, ".", "//chrome")
226 sources +=
227 rebase_path(gypi_values.chrome_browser_history_sources, ".", "//chrome")
228 sources +=
229 rebase_path(gypi_values.chrome_browser_metrics_sources, ".", "//chrome")
230 sources +=
231 rebase_path(gypi_values.chrome_browser_net_sources, ".", "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59232 sources += rebase_path(gypi_values.chrome_browser_password_manager_sources,
scottmga266f952014-12-03 20:47:10233 ".",
234 "//chrome")
mlamouri4e372022015-03-29 14:51:06235 sources += rebase_path(gypi_values.chrome_browser_permissions_sources,
236 ".",
237 "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59238 sources += rebase_path(gypi_values.chrome_browser_predictor_sources,
scottmga266f952014-12-03 20:47:10239 ".",
240 "//chrome")
241 sources +=
242 rebase_path(gypi_values.chrome_browser_pref_sources, ".", "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59243 sources += rebase_path(gypi_values.chrome_browser_profiles_sources,
scottmga266f952014-12-03 20:47:10244 ".",
245 "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59246 sources += rebase_path(gypi_values.chrome_browser_search_engines_sources,
scottmga266f952014-12-03 20:47:10247 ".",
248 "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59249 sources += rebase_path(gypi_values.chrome_browser_services_sources,
scottmga266f952014-12-03 20:47:10250 ".",
251 "//chrome")
252 sources +=
stuartmorgan997cf23d2014-12-04 21:01:18253 rebase_path(gypi_values.chrome_browser_session_sources, ".", "//chrome")
254 sources +=
scottmga266f952014-12-03 20:47:10255 rebase_path(gypi_values.chrome_browser_signin_sources, ".", "//chrome")
256 sources +=
stuartmorgan997cf23d2014-12-04 21:01:18257 rebase_path(gypi_values.chrome_browser_ssl_sources, ".", "//chrome")
258 sources +=
scottmga266f952014-12-03 20:47:10259 rebase_path(gypi_values.chrome_browser_sync_sources, ".", "//chrome")
stuartmorgancd5b6042014-11-17 16:52:59260 sources += rebase_path(gypi_values.chrome_browser_web_resource_sources,
scottmga266f952014-12-03 20:47:10261 ".",
262 "//chrome")
263
[email protected]dffd8a912014-06-30 23:24:31264 deps += [
Brett Wilson1c693992014-08-25 19:10:01265 "//apps",
[email protected]dffd8a912014-06-30 23:24:31266 "//cc",
brettwca934582015-02-24 21:50:27267 "//chrome/app/theme:theme_resources",
[email protected]55699f392014-08-20 22:16:30268 "//chrome/browser/devtools",
sdefresnea213ceb2015-10-05 09:23:39269 "//chrome/browser/metrics/variations:chrome_ui_string_overrider_factory",
brettwca934582015-02-24 21:50:27270 "//chrome/browser/resources:component_extension_resources",
tfarina04d426612015-08-18 16:42:33271 "//chrome/common/net",
[email protected]55699f392014-08-20 22:16:30272 "//chrome/installer/util",
jitendra.ks4f2e9112015-08-14 11:40:26273 "//components/about_handler",
oshimaf65398422014-11-18 23:30:42274 "//components/app_modal",
[email protected]b9f4c682014-07-10 22:00:37275 "//components/autofill/content/browser",
lazyboy14082d22015-04-02 01:04:58276 "//components/browsing_data",
jeremyim364ac1182015-03-03 18:49:43277 "//components/data_reduction_proxy/content/browser",
amohammadkhan092adb22015-09-11 21:08:49278 "//components/data_use_measurement/content",
dgozmanec2b982a2015-04-28 10:36:39279 "//components/devtools_discovery",
dgozman102fee92015-04-20 15:45:46280 "//components/devtools_http_handler",
mdjones1c47b052015-07-22 19:15:39281 "//components/dom_distiller/content:content_browser",
tfarina041134472015-09-02 15:29:38282 "//components/error_page/common",
sdefresne001b10de2015-03-20 18:41:46283 "//components/favicon/content",
sdefresne715246622015-01-12 16:24:04284 "//components/history/content/browser",
[email protected]fca567b2014-07-02 17:37:34285 "//components/keyed_service/content",
[email protected]55699f392014-08-20 22:16:30286 "//components/navigation_interception",
drogerc690e8802015-09-21 14:29:16287 "//components/net_log",
tfarina041134472015-09-02 15:29:38288 "//components/network_hints/common",
[email protected]55699f392014-08-20 22:16:30289 "//components/password_manager/content/browser",
vabr5410d0b2015-08-07 11:02:04290 "//components/password_manager/sync/browser",
dbeam155ac972015-04-20 15:34:48291 "//components/plugins/common",
abhishek.a2171c612852015-08-31 10:48:19292 "//components/proxy_config",
bauerbf0e64aa2015-06-25 15:54:07293 "//components/safe_json",
brettwa22cb3b2015-04-30 20:23:12294 "//components/sessions",
[email protected]abd4b682014-07-16 20:26:30295 "//components/storage_monitor",
sdefresne875d0782015-09-16 12:01:28296 "//components/syncable_prefs",
[email protected]b9f4c682014-07-10 22:00:37297 "//components/translate/content/browser",
sdefresne44eb1f22015-08-06 08:51:55298 "//components/upload_list",
[email protected]fca567b2014-07-02 17:37:34299 "//components/url_matcher",
[email protected]dffd8a912014-06-30 23:24:31300 "//components/visitedlink/browser",
301 "//components/visitedlink/common",
hanxi149b92d2014-09-11 21:57:18302 "//components/web_cache/browser",
[email protected]b9f4c682014-07-10 22:00:37303 "//components/web_modal",
[email protected]a9ca8d52014-08-22 10:21:08304 "//content/app/resources",
finnur61535c702015-10-05 11:10:02305 "//device/devices_app/usb/public/interfaces",
[email protected]55699f392014-08-20 22:16:30306 "//media",
yhiranobbea6272015-09-17 07:09:03307 "//media/midi",
rockot50dc5692015-07-08 01:57:26308 "//mojo/application/public/cpp",
cjhopman09981a92014-10-27 17:11:18309 "//mojo/common",
[email protected]604828c2014-07-02 20:39:12310 "//mojo/environment:chromium",
Brett Wilson83fd4242014-09-02 19:45:33311 "//net:extras",
[email protected]dffd8a912014-06-30 23:24:31312 "//net:net_with_v8",
pilgrim4af8c212014-09-05 17:30:15313 "//storage/browser",
pilgrimf55d19fc2014-09-04 00:05:24314 "//storage/common",
erga3c614c92015-04-03 17:47:51315 "//third_party/WebKit/public:image_resources",
[email protected]4eebe74d2014-08-13 02:54:46316 "//third_party/WebKit/public:resources",
[email protected]dffd8a912014-06-30 23:24:31317 "//third_party/leveldatabase",
[email protected]fca567b2014-07-02 17:37:34318 "//third_party/libaddressinput",
[email protected]dffd8a912014-06-30 23:24:31319 "//third_party/libyuv",
blundell70fb547672015-01-19 17:18:33320 "//third_party/mojo/src/mojo/edk/system",
321 "//third_party/mojo/src/mojo/public/cpp/bindings",
322 "//third_party/mojo/src/mojo/public/js",
[email protected]dffd8a912014-06-30 23:24:31323 "//third_party/re2",
324 "//third_party/smhasher:cityhash",
Brett Wilson83fd4242014-09-02 19:45:33325 "//third_party/webrtc/modules/desktop_capture",
spang1c36fac2015-02-05 19:55:12326 "//ui/base/ime",
[email protected]dffd8a912014-06-30 23:24:31327 "//ui/gl",
brettwca934582015-02-24 21:50:27328 "//ui/resources",
[email protected]dffd8a912014-06-30 23:24:31329 "//ui/surface",
[email protected]604828c2014-07-02 20:39:12330 "//ui/web_dialogs",
[email protected]fca567b2014-07-02 17:37:34331 "//v8",
[email protected]dffd8a912014-06-30 23:24:31332 ]
paulmeyer27b328b2015-06-17 21:26:12333
334 if (toolkit_views) {
335 deps += [ "//ui/views" ]
336 }
[email protected]dffd8a912014-06-30 23:24:31337 } else { # iOS
scottmga266f952014-12-03 20:47:10338 sources +=
339 rebase_path(gypi_values.chrome_browser_ios_sources, ".", "//chrome")
340 sources +=
341 rebase_path(gypi_values.chrome_browser_google_sources, ".", "//chrome")
342 deps += [ "//net" ]
[email protected]dffd8a912014-06-30 23:24:31343 libs += [
344 "CoreTelephony.framework",
345 "CoreText.framework",
346 "MobileCoreServices.framework",
347 "QuartzCore.framework",
348 ]
scottmga266f952014-12-03 20:47:10349 ldflags += [
350 "-weak_framework",
351 "CoreImage",
352 ]
[email protected]dffd8a912014-06-30 23:24:31353 }
354
355 if (is_win || is_mac) {
scottmga266f952014-12-03 20:47:10356 sources +=
357 rebase_path(gypi_values.chrome_browser_win_mac_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31358 }
mmenkede134672015-08-18 01:33:39359 if (!is_win && !is_mac && !is_ios) {
360 sources += [ "net/net_error_diagnostics_dialog_generic.cc" ]
361 }
[email protected]dffd8a912014-06-30 23:24:31362 if (!is_android && !is_ios && !is_chromeos && enable_configuration_policy) {
363 sources += [
364 "net/disk_cache_dir_policy_handler.cc",
365 "net/disk_cache_dir_policy_handler.h",
366 ]
367 }
368 if (!is_android && !is_ios && enable_configuration_policy) {
369 sources += [
370 "download/download_dir_policy_handler.cc",
371 "download/download_dir_policy_handler.h",
372 ]
373 }
374 if (is_mac) {
scottmga266f952014-12-03 20:47:10375 sources +=
376 rebase_path(gypi_values.chrome_browser_mac_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31377 deps += [
brettw624c82d2015-07-23 00:31:50378 #"app_shim" TODO(GYP) bug 512600
379 #"browser_app_shim" TODO(GYP) bug 512600
[email protected]dffd8a912014-06-30 23:24:31380 ]
381 }
ki.stfu5e669f02015-09-17 07:15:19382 if (is_mac || is_android) {
383 sources += rebase_path(
384 gypi_values.chrome_browser_password_manager_mac_android_sources,
385 ".",
386 "//chrome")
387 }
[email protected]dffd8a912014-06-30 23:24:31388 if (enable_extensions) {
Brett Wilsone53895272014-09-23 23:41:46389 public_deps += [ "//chrome/browser/extensions" ]
[email protected]cc5b3be2014-08-15 23:24:52390 deps += [
[email protected]cc5b3be2014-08-15 23:24:52391 "//chrome/browser/sync_file_system/drive_backend:sync_file_system_drive_proto",
thestige33aa2422014-09-22 22:16:30392 "//chrome/common/extensions/api",
393 "//chrome/common/extensions/api:api_registration",
lukasza8acc4eb2015-07-20 20:57:20394 "//components/drive:drive",
msarda4c408ff2015-04-22 14:27:56395 "//components/proximity_auth/ble",
tengs4758c082014-12-19 18:51:44396 "//components/proximity_auth/cryptauth",
oshima758abebc2014-11-06 10:55:50397 "//extensions/components/javascript_dialog_extensions_client",
thestig73f4cdc2015-01-15 01:51:06398 "//media/cast:net",
[email protected]cc5b3be2014-08-15 23:24:52399 ]
[email protected]dffd8a912014-06-30 23:24:31400 sources += rebase_path(gypi_values.chrome_browser_extensions_sources,
scottmga266f952014-12-03 20:47:10401 ".",
402 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31403 }
404 if (enable_background) {
405 sources += rebase_path(gypi_values.chrome_browser_background_sources,
scottmga266f952014-12-03 20:47:10406 ".",
407 "//chrome")
jamesr29ea2d122014-10-23 10:30:27408 if (!use_aura || is_win || is_chromeos) {
[email protected]dffd8a912014-06-30 23:24:31409 sources -= [ "background/background_mode_manager_aura.cc" ]
410 }
411 }
412 if (enable_task_manager) {
413 sources += rebase_path(gypi_values.chrome_browser_task_manager_sources,
scottmga266f952014-12-03 20:47:10414 ".",
415 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31416 }
417 if (enable_spellcheck) {
418 sources += rebase_path(gypi_values.chrome_browser_spellchecker_sources,
scottmga266f952014-12-03 20:47:10419 ".",
420 "//chrome")
dylanking34c72442015-07-23 23:19:58421 if (!is_android) {
422 deps += [ "//third_party/hunspell" ]
423 }
[email protected]dffd8a912014-06-30 23:24:31424 }
425 if (enable_nacl) {
scottmga266f952014-12-03 20:47:10426 sources +=
427 rebase_path(gypi_values.chrome_browser_nacl_sources, ".", "//chrome")
dpranke6065cf72015-02-26 03:30:58428 deps += [ "//components/nacl:nacl_browser" ]
[email protected]dffd8a912014-06-30 23:24:31429 }
apavlove749bca2014-09-30 11:07:41430
[email protected]dffd8a912014-06-30 23:24:31431 if (enable_configuration_policy) {
scottmga266f952014-12-03 20:47:10432 sources +=
433 rebase_path(gypi_values.chrome_browser_policy_shared_with_ios_sources,
434 ".",
435 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31436 deps += [
[email protected]604828c2014-07-02 20:39:12437 "//components/policy",
[email protected]797b25042014-07-01 23:54:17438 "//components/policy/proto",
[email protected]dffd8a912014-06-30 23:24:31439 ]
440 if (!is_ios) {
scottmga266f952014-12-03 20:47:10441 sources += rebase_path(gypi_values.chrome_browser_policy_non_ios_sources,
442 ".",
443 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31444 }
445 if (!is_chromeos) {
446 sources += rebase_path(
scottmga266f952014-12-03 20:47:10447 gypi_values.chrome_browser_policy_shared_with_ios_not_chromeos_sources,
448 ".",
449 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31450 }
451 if (is_win || is_mac || is_desktop_linux) {
452 sources += rebase_path(gypi_values.chrome_browser_policy_desktop_sources,
scottmga266f952014-12-03 20:47:10453 ".",
454 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31455 }
cjhopman09981a92014-10-27 17:11:18456 if (is_android || is_ios) {
457 sources += rebase_path(gypi_values.chrome_browser_policy_mobile_sources,
scottmga266f952014-12-03 20:47:10458 ".",
459 "//chrome")
cjhopman09981a92014-10-27 17:11:18460 } else {
amistry6e1ed1b2015-03-12 05:24:01461 deps += [
462 "//chrome/browser/policy:path_parser",
463 "//net:net_browser_services",
464 ]
[email protected]dffd8a912014-06-30 23:24:31465 }
466 } else {
467 # Configuration policy disabled.
468 sources += rebase_path(gypi_values.chrome_browser_policy_disabled_sources,
scottmga266f952014-12-03 20:47:10469 ".",
470 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31471 }
472
473 if (enable_plugins) {
scottmga266f952014-12-03 20:47:10474 sources +=
475 rebase_path(gypi_values.chrome_browser_plugins_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31476 deps += [
James Robinson2ed4d692014-09-17 05:20:58477 "//components/pdf/browser",
brettwf7eb6ca2015-02-14 01:37:31478 "//ppapi/proxy:ipc",
thestig11b815e92014-08-26 00:32:14479 "//third_party/adobe/flash:flapper_version_h",
[email protected]dffd8a912014-06-30 23:24:31480 ]
481 }
482 if (safe_browsing_mode != 0) {
scottmga266f952014-12-03 20:47:10483 sources +=
stuartmorgan1b3df822014-12-08 14:36:11484 rebase_path(gypi_values.chrome_browser_safe_browsing_basic_sources,
scottmga266f952014-12-03 20:47:10485 ".",
486 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31487 deps += [
[email protected]fca567b2014-07-02 17:37:34488 "//chrome/browser/safe_browsing:chunk_proto",
mattm022138b52014-09-23 01:05:45489 "//chrome/browser/safe_browsing:metadata_proto",
[email protected]fca567b2014-07-02 17:37:34490 "//chrome/browser/safe_browsing:report_proto",
[email protected]dffd8a912014-06-30 23:24:31491 ]
492 if (safe_browsing_mode == 1) {
scottmga266f952014-12-03 20:47:10493 sources +=
stuartmorgan1b3df822014-12-08 14:36:11494 rebase_path(gypi_values.chrome_browser_safe_browsing_full_sources,
scottmga266f952014-12-03 20:47:10495 ".",
496 "//chrome")
scottmga266f952014-12-03 20:47:10497 deps += [ "//chrome/common/safe_browsing:proto" ]
grtc1d1b752015-09-05 13:26:41498 if (is_win) {
499 deps += [ "//chrome/browser/safe_browsing/incident_reporting:state_store_data_proto" ]
500 }
nparkerb2cd5ee2015-05-13 01:12:01501 } else if (safe_browsing_mode == 3) {
502 sources += rebase_path(
503 gypi_values.chrome_browser_safe_browsing_mobile_extended_sources,
504 ".",
505 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31506 }
507 }
508
amistryf269d3b2015-06-09 19:18:39509 if (enable_hotwording) {
510 defines += [ "ENABLE_HOTWORDING" ]
511 }
512
[email protected]dffd8a912014-06-30 23:24:31513 if (is_linux) {
mostynbea514682015-08-18 22:08:56514 deps += [ "//device/media_transfer_protocol" ]
[email protected]dffd8a912014-06-30 23:24:31515 }
mostynbea514682015-08-18 22:08:56516
517 if (use_udev) {
518 deps += [ "//device/udev_linux" ]
519 }
520
[email protected]dffd8a912014-06-30 23:24:31521 if (is_linux && !is_chromeos) {
[email protected]fd98b612014-07-09 22:11:47522 deps += [ "//third_party/speech-dispatcher" ]
[email protected]dffd8a912014-06-30 23:24:31523 }
524
525 if (is_chromeos) {
526 sources += rebase_path(gypi_values.chrome_browser_chromeos_sources,
scottmga266f952014-12-03 20:47:10527 ".",
528 "//chrome")
529 deps += [ "//chrome/browser/chromeos" ]
[email protected]dffd8a912014-06-30 23:24:31530 }
531
yiyaoliubcd08dc22014-12-10 05:56:10532 if (is_ios) {
533 sources -= [
534 "metrics/signin_status_metrics_provider_base.cc",
535 "metrics/signin_status_metrics_provider_base.h",
536 ]
537 }
538
mukai8c99b882014-10-15 03:07:59539 if (is_chromeos || is_ios) {
540 sources -= [
541 "metrics/signin_status_metrics_provider.cc",
542 "metrics/signin_status_metrics_provider.h",
543 ]
544 }
545
[email protected]dffd8a912014-06-30 23:24:31546 if (use_cups) {
[email protected]604828c2014-07-02 20:39:12547 configs += [ "//printing:cups" ]
[email protected]dffd8a912014-06-30 23:24:31548 }
549 if (is_desktop_linux) {
550 sources += rebase_path(gypi_values.chrome_browser_gnome_keyring_sources,
scottmga266f952014-12-03 20:47:10551 ".",
552 "//chrome")
cmasone0a9e4ca2014-10-16 16:40:49553 configs += [ ":gnome_keyring" ]
[email protected]dffd8a912014-06-30 23:24:31554 }
dvadym34532022015-01-22 15:42:51555 if (is_desktop_linux) {
556 sources += rebase_path(gypi_values.chrome_browser_libsecret_sources,
557 ".",
558 "//chrome")
559 defines += [ "USE_LIBSECRET" ]
560 }
[email protected]dffd8a912014-06-30 23:24:31561 if (use_aura) {
scottmga266f952014-12-03 20:47:10562 sources +=
563 rebase_path(gypi_values.chrome_browser_aura_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31564 deps += [
[email protected]fca567b2014-07-02 17:37:34565 "//ui/aura",
566 "//ui/compositor",
[email protected]604828c2014-07-02 20:39:12567 "//ui/keyboard",
[email protected]dffd8a912014-06-30 23:24:31568 ]
569 }
570 if (ui_compositor_image_transport) {
571 deps += [ "//ui/gl" ]
572 }
573
[email protected]855b7de2014-07-08 21:02:45574 if (use_ash) {
scottmga266f952014-12-03 20:47:10575 sources +=
576 rebase_path(gypi_values.chrome_browser_ash_sources, ".", "//chrome")
[email protected]855b7de2014-07-08 21:02:45577 }
578
[email protected]dffd8a912014-06-30 23:24:31579 if (use_x11) {
scottmga266f952014-12-03 20:47:10580 sources +=
581 rebase_path(gypi_values.chrome_browser_x11_sources, ".", "//chrome")
vchigrinbbc23e72015-01-21 22:49:23582 } else {
583 sources -= [ "password_manager/password_store_x.cc" ]
[email protected]dffd8a912014-06-30 23:24:31584 }
585 if (is_posix && !is_mac && !is_ios) {
586 sources += [
rseseka0a7a042014-09-18 23:59:20587 "//chrome/app/chrome_crash_reporter_client.cc",
588 "//chrome/app/chrome_crash_reporter_client.h",
[email protected]dffd8a912014-06-30 23:24:31589 ]
590 deps += [
sdefresne8ba0b88c2015-09-18 10:33:13591 "//components/crash/content/app",
592 "//components/crash/content/browser",
[email protected]dffd8a912014-06-30 23:24:31593 ]
594 }
595 if (use_nss_certs) {
scottmga266f952014-12-03 20:47:10596 sources +=
597 rebase_path(gypi_values.chrome_browser_nss_sources, ".", "//chrome")
mukai8c99b882014-10-15 03:07:59598 if (is_chromeos) {
599 sources -= [ "net/nss_context_linux.cc" ]
600 }
[email protected]dffd8a912014-06-30 23:24:31601 }
602 if (enable_notifications) {
603 sources += rebase_path(gypi_values.chrome_browser_notifications_sources,
scottmga266f952014-12-03 20:47:10604 ".",
605 "//chrome")
estade6d95d1d2015-10-02 18:55:23606 if (is_android) {
607 sources +=
608 rebase_path(gypi_values.chrome_browser_notifications_android_sources,
609 ".",
610 "//chrome")
611 } else {
[email protected]dffd8a912014-06-30 23:24:31612 sources += rebase_path(
stuartmorgan1b3df822014-12-08 14:36:11613 gypi_values.chrome_browser_notifications_non_android_sources,
scottmga266f952014-12-03 20:47:10614 ".",
615 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31616 }
617 }
618 if (enable_themes) {
scottmga266f952014-12-03 20:47:10619 sources +=
620 rebase_path(gypi_values.chrome_browser_themes_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31621 }
622
vitalybuka93eea402014-11-05 23:47:15623 if (enable_basic_printing || enable_print_preview) {
[email protected]dffd8a912014-06-30 23:24:31624 # Some form of printing support.
stuartmorgan1b3df822014-12-08 14:36:11625 sources += rebase_path(gypi_values.chrome_browser_printing_basic_sources,
scottmga266f952014-12-03 20:47:10626 ".",
627 "//chrome")
spang5cc72542015-08-04 19:47:11628 deps += [
629 "//printing",
brettwd649f6b2015-08-18 20:58:51630 "//components/printing/browser",
spang5cc72542015-08-04 19:47:11631 ]
632
vitalybuka36259ca2014-08-28 23:42:24633 if (is_win) {
[email protected]dffd8a912014-06-30 23:24:31634 sources += rebase_path(gypi_values.chrome_browser_printing_emf_sources,
scottmga266f952014-12-03 20:47:10635 ".",
636 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31637 }
vitalybuka93eea402014-11-05 23:47:15638 if (enable_print_preview) {
[email protected]dffd8a912014-06-30 23:24:31639 # Full printing on top of the above.
stuartmorgan1b3df822014-12-08 14:36:11640 sources += rebase_path(gypi_values.chrome_browser_printing_full_sources,
scottmga266f952014-12-03 20:47:10641 ".",
642 "//chrome")
vitalybuka93eea402014-11-05 23:47:15643 } else {
[email protected]dffd8a912014-06-30 23:24:31644 # Partial-only printing support.
scottmga266f952014-12-03 20:47:10645 sources +=
stuartmorgan1b3df822014-12-08 14:36:11646 rebase_path(gypi_values.chrome_browser_printing_basic_only_sources,
scottmga266f952014-12-03 20:47:10647 ".",
648 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31649 }
650 }
651 if (enable_captive_portal_detection) {
652 sources += rebase_path(gypi_values.chrome_browser_captive_portal_sources,
scottmga266f952014-12-03 20:47:10653 ".",
654 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31655 }
656 if (enable_session_service) {
657 sources += rebase_path(gypi_values.chrome_browser_session_service_sources,
scottmga266f952014-12-03 20:47:10658 ".",
659 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31660 }
661
thestigdc377202014-10-28 22:06:02662 if (!is_android && !is_ios && !is_chromeos) {
scottmga266f952014-12-03 20:47:10663 sources +=
664 rebase_path(gypi_values.chrome_browser_desktop_sources, ".", "//chrome")
thestigdc377202014-10-28 22:06:02665 }
666
[email protected]dffd8a912014-06-30 23:24:31667 if (is_android || is_ios) {
668 # Mobile.
scottmga266f952014-12-03 20:47:10669 sources +=
670 rebase_path(gypi_values.chrome_browser_mobile_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31671 } else {
672 # Non-mobile.
673 sources += rebase_path(gypi_values.chrome_browser_non_mobile_sources,
scottmga266f952014-12-03 20:47:10674 ".",
675 "//chrome")
reillyge471fab2014-08-29 01:58:43676 deps += [
sdefresnebbf563c2015-03-17 11:09:09677 "//components/feedback",
juncai1b1152562015-09-04 02:36:08678 "//components/webusb",
reillyge471fab2014-08-29 01:58:43679 "//device/core",
rockot50dc5692015-07-08 01:57:26680 "//device/devices_app/public/cpp",
681 "//device/devices_app/public/cpp:factory",
reillygd77718d2014-09-04 00:57:56682 "//device/usb",
reillyge471fab2014-08-29 01:58:43683 ]
[email protected]dffd8a912014-06-30 23:24:31684 }
685
mathp17e1eba2015-10-06 21:50:59686 if (!is_chrome_branded) {
fserb1c2db4c2015-07-16 17:14:49687 sources += [
688 "search/local_files_ntp_source.cc",
689 "search/local_files_ntp_source.h",
690 ]
691 }
692
[email protected]dffd8a912014-06-30 23:24:31693 if (is_android) {
scottmga266f952014-12-03 20:47:10694 sources +=
695 rebase_path(gypi_values.chrome_browser_android_sources, ".", "//chrome")
twellingtoncaf0eb752015-06-01 16:19:50696 sources += rebase_path(gypi_values.chrome_browser_bookmark_android_sources,
697 ".",
698 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31699 deps += [
pkotwicz127726f2015-05-29 15:20:12700 ":client_discourse_context_proto",
701 ":delta_file_proto",
James Robinson2ed4d692014-09-17 05:20:58702 ":jni_headers",
[email protected]55699f392014-08-20 22:16:30703 "//components/cdm/browser",
cjhopman09981a92014-10-27 17:11:18704 "//components/enhanced_bookmarks",
twifkak8c9f7502015-06-25 02:12:57705 "//components/precache/content",
706 "//components/precache/core",
estadee37f8222014-11-07 21:35:22707 "//components/resources:components_resources",
mathiash3ecfdfa2015-04-13 15:06:07708 "//components/service_tab_launcher",
blundell11d93bc2015-07-31 12:33:12709 "//components/toolbar",
cjhopman09981a92014-10-27 17:11:18710 "//components/web_contents_delegate_android",
711 "//third_party/android_opengl/etc1",
fdegans34f31e272015-05-22 16:59:03712 "//third_party/android_tools:cpu_features",
twellington0bc61492015-01-30 20:14:13713 "//third_party/libaddressinput:util",
[email protected]dffd8a912014-06-30 23:24:31714 ]
715 deps -= [
[email protected]fca567b2014-07-02 17:37:34716 "//third_party/libaddressinput",
[email protected]abd4b682014-07-16 20:26:30717 "//components/storage_monitor",
[email protected]abd4b682014-07-16 20:26:30718 "//components/web_modal",
[email protected]dffd8a912014-06-30 23:24:31719 ]
megjablon5effca2e2015-02-13 23:54:07720 defines += [ "ENABLE_DATA_REDUCTION_PROXY_DEBUGGING" ]
rseseke59ea892015-03-19 22:27:44721
722 if (use_seccomp_bpf) {
723 defines += [ "USE_SECCOMP_BPF" ]
rsesek65d31352015-06-08 22:53:44724 deps += [ "//sandbox/linux:seccomp_bpf" ]
rseseke59ea892015-03-19 22:27:44725 }
[email protected]dffd8a912014-06-30 23:24:31726 }
727
728 if (is_mac) {
729 deps += [
[email protected]6b5d2f92014-07-30 00:40:03730 "//third_party/google_toolbox_for_mac",
tfarina22896302015-02-23 21:18:03731 "//third_party/mozilla",
[email protected]dffd8a912014-06-30 23:24:31732 ]
733 libs += [
734 "Accelerate.framework",
735 "AddressBook.framework",
736 "AudioUnit.framework",
737 "DiskArbitration.framework",
738 "IOKit.framework",
739 "ImageCaptureCore.framework",
740 "OpenGL.framework",
741 "QuartzCore.framework",
742 "SecurityInterface.framework",
743 ]
744 }
745
746 if (enable_rlz) {
sdefresned967d552015-07-16 08:34:35747 deps += [ ":rlz" ]
[email protected]dffd8a912014-06-30 23:24:31748 }
749
750 # TODO(GYP)
751 # Temporary fix to break the browser target into smaller chunks so it
752 # will link with goma builds.
753 #["OS=="win" and chromium_win_pch==0", {
754 # "msvs_shard": 4,
755 #}],
756
757 if (is_win) {
scottmga266f952014-12-03 20:47:10758 sources +=
759 rebase_path(gypi_values.chrome_browser_win_sources, ".", "//chrome")
Brett Wilsone53895272014-09-23 23:41:46760 public_deps += [
761 "//ui/views",
762 "//ui/views/controls/webview",
763 ]
[email protected]dffd8a912014-06-30 23:24:31764 deps += [
vchigrin9593e7a2015-01-27 10:08:19765 ":chrome_process_finder",
[email protected]55699f392014-08-20 22:16:30766 "//chrome:version_header",
767 "//chrome/installer/util:strings",
vchigrinf2b90aa2015-01-23 11:12:19768 "//chrome_elf",
769 "//chrome_elf:constants",
770 "//chrome_elf:dll_hash",
vchigrin61944ae2015-01-30 23:51:32771 "//components/browser_watcher",
772 "//components/browser_watcher:browser_watcher_client",
vchigrinbbc23e72015-01-21 22:49:23773 "//google_update",
[email protected]55699f392014-08-20 22:16:30774 "//third_party/iaccessible2",
775 "//third_party/isimpledom",
[email protected]dffd8a912014-06-30 23:24:31776 "//third_party/wtl",
vchigrin88ed6f42015-01-17 11:56:42777 "//ui/metro_viewer",
778 "//win8:metro_viewer",
[email protected]dffd8a912014-06-30 23:24:31779 ]
mmenkede134672015-08-18 01:33:39780
781 all_dependent_configs = [ ":browser_win_linker_flags" ]
782
grt235b3f092015-05-27 21:42:48783 if (!is_chrome_branded) {
784 deps -= [ "//google_update" ]
785 sources -= [
786 "google/did_run_updater_win.cc",
787 "google/did_run_updater_win.h",
788 "google/google_update_win.cc",
789 "google/google_update_win.h",
790 ]
791 }
[email protected]dffd8a912014-06-30 23:24:31792 } else {
793 # Non-Windows.
scottmga266f952014-12-03 20:47:10794 sources +=
795 rebase_path(gypi_values.chrome_browser_non_win_sources, ".", "//chrome")
[email protected]f6dc4ae2014-07-30 00:10:37796 if (toolkit_views) {
[email protected]dffd8a912014-06-30 23:24:31797 deps += [
scottmga266f952014-12-03 20:47:10798 "//ui/views",
799 "//ui/views/controls/webview",
[email protected]dffd8a912014-06-30 23:24:31800 ]
[email protected]dffd8a912014-06-30 23:24:31801 }
802 }
803
804 if (is_linux) {
[email protected]dffd8a912014-06-30 23:24:31805 if (use_aura) {
slan17e5ce7f2015-09-25 00:04:45806 configs += [ "//build/config/linux:dbus" ]
807 deps += [
808 "//build/linux:fontconfig",
809 "//dbus",
[email protected]dffd8a912014-06-30 23:24:31810 ]
[email protected]dffd8a912014-06-30 23:24:31811 }
812 if (use_x11) {
813 configs += [ "//build/config/linux:x11" ]
814 deps += [ "//ui/gfx/x" ]
815 }
816 }
817
818 if (is_desktop_linux) {
stuartmorgan7f569a822014-12-08 20:10:54819 sources += rebase_path(gypi_values.chrome_browser_linux_desktop_sources,
scottmga266f952014-12-03 20:47:10820 ".",
821 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31822 }
823 if (enable_plugin_installation) {
scottmga266f952014-12-03 20:47:10824 sources +=
825 rebase_path(gypi_values.chrome_browser_plugin_installation_sources,
826 ".",
827 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31828 }
829 if (enable_app_list) {
scottmga266f952014-12-03 20:47:10830 deps += [ "//ui/app_list" ]
[email protected]dffd8a912014-06-30 23:24:31831 }
treib87bb89cbb2014-12-01 16:01:47832 if (enable_supervised_users) {
scottmga266f952014-12-03 20:47:10833 sources += rebase_path(gypi_values.chrome_browser_supervised_user_sources,
834 ".",
835 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31836 }
bauerb7f3b8542015-06-29 19:56:19837 if (enable_supervised_users && !is_android && !is_ios) {
838 sources +=
839 rebase_path(gypi_values.chrome_browser_supervised_user_legacy_sources,
840 ".",
841 "//chrome")
842 }
treib87bb89cbb2014-12-01 16:01:47843 if (enable_supervised_users && enable_themes) {
thestig169a6362014-11-13 20:47:59844 sources += rebase_path(
scottmga266f952014-12-03 20:47:10845 gypi_values.chrome_browser_supervised_user_and_themes_sources,
846 ".",
847 "//chrome")
thestig169a6362014-11-13 20:47:59848 }
[email protected]dffd8a912014-06-30 23:24:31849 if (enable_webrtc) {
scottmga266f952014-12-03 20:47:10850 sources +=
851 rebase_path(gypi_values.chrome_browser_webrtc_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31852 }
853 if (enable_service_discovery) {
scottmga266f952014-12-03 20:47:10854 sources += rebase_path(gypi_values.chrome_browser_service_discovery_sources,
855 ".",
856 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31857 }
858 if (enable_mdns) {
scottmga266f952014-12-03 20:47:10859 sources +=
860 rebase_path(gypi_values.chrome_browser_mdns_sources, ".", "//chrome")
[email protected]dffd8a912014-06-30 23:24:31861 }
862 if (!enable_autofill_dialog || is_android || is_ios) {
863 sources -= [
864 "autofill/validation_rules_storage_factory.cc",
865 "autofill/validation_rules_storage_factory.h",
866 ]
867 }
868 if (enable_wifi_bootstrapping) {
scottmga266f952014-12-03 20:47:10869 sources +=
870 rebase_path(gypi_values.chrome_browser_wifi_bootstrapping_sources,
871 ".",
872 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31873 if (is_win || is_mac) {
874 # TODO(brettw) as of this writing wifi bootstrapping is set on Windows
875 # and Mac, so this test is meaningless. Can we merge these lists?
876 sources += rebase_path(
stuartmorgan1b3df822014-12-08 14:36:11877 gypi_values.chrome_browser_wifi_bootstrapping_win_mac_sources,
scottmga266f952014-12-03 20:47:10878 ".",
879 "//chrome")
[email protected]dffd8a912014-06-30 23:24:31880 }
881 }
mfoltz150bb8b2015-04-09 22:30:05882 if (enable_media_router) {
imchengb6b09239f2015-05-15 21:41:55883 deps += [ "//chrome/browser/media/router" ]
mfoltz150bb8b2015-04-09 22:30:05884 }
[email protected]dffd8a912014-06-30 23:24:31885}
886
James Robinson2ed4d692014-09-17 05:20:58887if (is_android) {
888 # GYP version: chrome/chrome_browser.gypi:chrome_browser_jni_headers
889 generate_jni("jni_headers") {
scottmga266f952014-12-03 20:47:10890 sources =
891 rebase_path(gypi_values.chrome_browser_jni_sources, ".", "//chrome")
James Robinson2ed4d692014-09-17 05:20:58892 jni_package = "chrome"
893 }
pkotwicz127726f2015-05-29 15:20:12894
895 #GYP: '//chrome/chrome_browser.gypi:client_discourse_context_proto'
896 proto_library("client_discourse_context_proto") {
897 sources = [
898 "android/proto/client_discourse_context.proto",
899 ]
900 }
901
902 #GYP: '//chrome/chrome_browser.gypi:delta_file_proto'
903 proto_library("delta_file_proto") {
904 sources = [
905 "android/proto/delta_file.proto",
906 ]
907 }
James Robinson2ed4d692014-09-17 05:20:58908}
909
vchigrin9593e7a2015-01-27 10:08:19910if (is_win) {
911 source_set("chrome_process_finder") {
912 sources = [
913 "chrome_process_finder_win.cc",
914 "chrome_process_finder_win.h",
915 ]
916 deps = [
917 "//base",
918 "//chrome/browser/metro_utils",
919 "//chrome/common:constants",
920 ]
921 if (enable_configuration_policy) {
922 deps += [ "//chrome/browser/policy:path_parser" ]
923 }
924 }
925}
926
[email protected]77ce8022014-06-16 19:29:56927# GYP version: chrome/chrome_resources.gyp:chrome_resources
928# (generate_browser_resources action)
929grit("resources") {
930 source = "browser_resources.grd"
[email protected]48885492014-08-13 11:22:41931 output_dir = "$root_gen_dir/chrome"
[email protected]cb0c67a2014-07-22 16:37:26932 outputs = [
933 "grit/browser_resources.h",
934 "browser_resources.pak",
935 ]
[email protected]77ce8022014-06-16 19:29:56936
[email protected]77ce8022014-06-16 19:29:56937 grit_flags = [
scottmga266f952014-12-03 20:47:10938 "-E",
scottmga266f952014-12-03 20:47:10939 "additional_modules_list_file=" +
940 rebase_path(additional_modules_list_file, root_build_dir),
941 "-E",
calamityd59c1032015-09-22 06:35:53942 "root_gen_dir=" + rebase_path(root_gen_dir, root_build_dir),
[email protected]77ce8022014-06-16 19:29:56943 ]
944
945 deps = [
[email protected]77ce8022014-06-16 19:29:56946 ":chrome_internal_resources_gen",
brettwde262b02015-05-27 19:41:42947
948 # Depend only on the generated mojo bindings since we read the .mojom.js
949 # file, rather than the whole mojo target which will link the C++ bindings.
calamityd59c1032015-09-22 06:35:53950 "//chrome/browser/ui/webui/engagement:mojo_bindings__generator",
brettwde262b02015-05-27 19:41:42951 "//chrome/browser/ui/webui/omnibox:mojo_bindings__generator",
vchigrin8eede942015-01-29 09:28:15952 ]
[email protected]77ce8022014-06-16 19:29:56953}
954
[email protected]77ce8022014-06-16 19:29:56955# GYP version: chrome/chrome_resource.gyp:chrome_internal_resources_gen
engedy99d0e11b2014-09-30 13:32:41956if (is_chrome_branded) {
[email protected]77ce8022014-06-16 19:29:56957 action("chrome_internal_resources_gen") {
engedy99d0e11b2014-09-30 13:32:41958 script = "internal/transform_additional_modules_list.py"
scottmga266f952014-12-03 20:47:10959 sources = [
960 "internal/resources/additional_modules_list.input",
961 ]
962 outputs = [
963 additional_modules_list_file,
964 ]
engedy99d0e11b2014-09-30 13:32:41965 args = rebase_path(sources, root_build_dir) +
966 rebase_path(outputs, root_build_dir)
[email protected]77ce8022014-06-16 19:29:56967 }
968} else {
969 group("chrome_internal_resources_gen") {
970 # Empty placeholder.
971 }
972}
Brett Wilson052ce132014-09-12 19:46:29973
974# In GYP this is part of test_support_common.
975source_set("test_support") {
976 testonly = true
977
978 # Always include this via the main test support target.
979 visibility = [ "//chrome/test:test_support" ]
980
981 sources = [
982 "browsing_data/mock_browsing_data_appcache_helper.cc",
983 "browsing_data/mock_browsing_data_appcache_helper.h",
jsbelle1fe9692015-08-22 01:02:42984 "browsing_data/mock_browsing_data_cache_storage_helper.cc",
985 "browsing_data/mock_browsing_data_cache_storage_helper.h",
Brett Wilson052ce132014-09-12 19:46:29986 "browsing_data/mock_browsing_data_channel_id_helper.cc",
987 "browsing_data/mock_browsing_data_channel_id_helper.h",
988 "browsing_data/mock_browsing_data_cookie_helper.cc",
989 "browsing_data/mock_browsing_data_cookie_helper.h",
990 "browsing_data/mock_browsing_data_database_helper.cc",
991 "browsing_data/mock_browsing_data_database_helper.h",
992 "browsing_data/mock_browsing_data_file_system_helper.cc",
993 "browsing_data/mock_browsing_data_file_system_helper.h",
994 "browsing_data/mock_browsing_data_flash_lso_helper.cc",
995 "browsing_data/mock_browsing_data_flash_lso_helper.h",
996 "browsing_data/mock_browsing_data_indexed_db_helper.cc",
997 "browsing_data/mock_browsing_data_indexed_db_helper.h",
998 "browsing_data/mock_browsing_data_local_storage_helper.cc",
999 "browsing_data/mock_browsing_data_local_storage_helper.h",
1000 "browsing_data/mock_browsing_data_quota_helper.cc",
1001 "browsing_data/mock_browsing_data_quota_helper.h",
1002 "browsing_data/mock_browsing_data_service_worker_helper.cc",
1003 "browsing_data/mock_browsing_data_service_worker_helper.h",
1004 "download/download_test_file_activity_observer.cc",
1005 "download/download_test_file_activity_observer.h",
1006 "download/test_download_shelf.cc",
1007 "download/test_download_shelf.h",
Brett Wilson052ce132014-09-12 19:46:291008 "invalidation/fake_invalidation_service.cc",
1009 "invalidation/fake_invalidation_service.h",
1010 "media/fake_desktop_media_list.cc",
1011 "media/fake_desktop_media_list.h",
1012 "net/dns_probe_test_util.cc",
1013 "net/dns_probe_test_util.h",
1014 "net/url_request_mock_util.cc",
1015 "net/url_request_mock_util.h",
1016 "notifications/notification_test_util.cc",
1017 "notifications/notification_test_util.h",
1018 "password_manager/mock_password_store_service.cc",
1019 "password_manager/mock_password_store_service.h",
Brett Wilson052ce132014-09-12 19:46:291020 "password_manager/test_password_store_service.cc",
1021 "password_manager/test_password_store_service.h",
Brett Wilson052ce132014-09-12 19:46:291022 "profile_resetter/profile_resetter_test_base.cc",
1023 "profile_resetter/profile_resetter_test_base.h",
1024 "search_engines/template_url_service_factory_test_util.cc",
1025 "search_engines/template_url_service_factory_test_util.h",
1026 "search_engines/template_url_service_test_util.cc",
1027 "search_engines/template_url_service_test_util.h",
squef7d723a2015-01-26 22:13:451028 "sessions/session_restore_test_helper.cc",
1029 "sessions/session_restore_test_helper.h",
Brett Wilson052ce132014-09-12 19:46:291030 "sessions/session_service_test_helper.cc",
1031 "sessions/session_service_test_helper.h",
knn523bd722015-07-30 16:27:091032 "signin/fake_account_fetcher_service_builder.cc",
1033 "signin/fake_account_fetcher_service_builder.h",
mlerman2933d012015-04-24 18:34:271034 "signin/fake_gaia_cookie_manager_service.cc",
1035 "signin/fake_gaia_cookie_manager_service.h",
Brett Wilson052ce132014-09-12 19:46:291036 "signin/fake_profile_oauth2_token_service_builder.cc",
1037 "signin/fake_profile_oauth2_token_service_builder.h",
droger4f489e62015-07-24 19:27:591038 "signin/fake_signin_manager_builder.cc",
1039 "signin/fake_signin_manager_builder.h",
Brett Wilson052ce132014-09-12 19:46:291040 "ssl/ssl_client_auth_requestor_mock.cc",
1041 "ssl/ssl_client_auth_requestor_mock.h",
Brett Wilson052ce132014-09-12 19:46:291042 "sync/profile_sync_components_factory_mock.cc",
1043 "sync/profile_sync_components_factory_mock.h",
1044 "sync/profile_sync_service_mock.cc",
1045 "sync/profile_sync_service_mock.h",
1046 ]
1047
brettwbc8b2a22015-07-28 18:24:421048 configs += [ "//build/config:precompiled_headers" ]
1049
Brett Wilsone53895272014-09-23 23:41:461050 public_deps = [
Brett Wilson052ce132014-09-12 19:46:291051 ":browser",
Brett Wilsone53895272014-09-23 23:41:461052 "//chrome/browser/ui:test_support",
1053 ]
1054 deps = [
Brett Wilson052ce132014-09-12 19:46:291055 "//base:prefs_test_support",
1056 "//chrome/browser",
Brett Wilson052ce132014-09-12 19:46:291057 "//chrome/common",
1058 "//chrome/common/safe_browsing:proto",
knn062cdbb2015-06-26 18:18:421059 "//components/invalidation/impl",
1060 "//components/invalidation/impl:test_support",
Brett Wilson052ce132014-09-12 19:46:291061 "//components/password_manager/core/browser:test_support",
1062 "//components/search_engines:test_support",
sdefresne875d0782015-09-16 12:01:281063 "//components/syncable_prefs:test_support",
jitendra.ks94c0b962015-08-10 08:24:091064 "//components/user_prefs/tracked:user_prefs_tracked_test_support",
Brett Wilson052ce132014-09-12 19:46:291065 "//content/test:test_support",
1066 "//chrome/app/theme:theme_resources",
1067 "//net:test_support",
1068 "//skia",
1069 "//testing/gmock",
1070 "//testing/gtest",
1071 "//ui/gfx",
1072 ]
1073
Brett Wilson052ce132014-09-12 19:46:291074 if (!is_ios) {
1075 deps += [
1076 "//components/sessions:test_support",
Brett Wilson052ce132014-09-12 19:46:291077 "//google_apis:test_support",
1078 ]
1079 }
1080
thestig354985d2015-09-28 20:55:001081 if (is_android) {
1082 sources -= [
thestig259da0b2015-10-07 18:09:081083 "download/test_download_shelf.cc",
1084 "download/test_download_shelf.h",
1085 "profile_resetter/profile_resetter_test_base.cc",
1086 "profile_resetter/profile_resetter_test_base.h",
1087 "sessions/session_restore_test_helper.cc",
1088 "sessions/session_restore_test_helper.h",
thestig354985d2015-09-28 20:55:001089 "sessions/session_service_test_helper.cc",
1090 "sessions/session_service_test_helper.h",
thestig354985d2015-09-28 20:55:001091 ]
1092 }
1093
James Robinson2ed4d692014-09-17 05:20:581094 if (enable_extensions) {
thestig52a87b3b2014-10-23 22:02:381095 sources += [
1096 "extensions/extension_action_test_util.cc",
1097 "extensions/extension_action_test_util.h",
1098 ]
scottmga266f952014-12-03 20:47:101099 deps += [ "//extensions:test_support" ]
James Robinson2ed4d692014-09-17 05:20:581100 }
1101
Brett Wilson052ce132014-09-12 19:46:291102 if (is_chromeos) {
1103 sources += [
1104 "chromeos/app_mode/fake_cws.cc",
1105 "chromeos/app_mode/fake_cws.h",
1106 "chromeos/file_manager/fake_disk_mount_manager.cc",
1107 "chromeos/file_manager/fake_disk_mount_manager.h",
1108 "chromeos/input_method/mock_candidate_window_controller.cc",
1109 "chromeos/input_method/mock_candidate_window_controller.h",
1110 "chromeos/input_method/mock_input_method_engine.cc",
1111 "chromeos/input_method/mock_input_method_engine.h",
1112 "chromeos/input_method/mock_input_method_manager.cc",
1113 "chromeos/input_method/mock_input_method_manager.h",
brettw7d6ec2462015-01-07 13:00:511114 "chromeos/login/screens/mock_device_disabled_screen_actor.cc",
1115 "chromeos/login/screens/mock_device_disabled_screen_actor.h",
nkostylev393309f2015-02-05 13:57:391116 "chromeos/login/session/user_session_manager_test_api.cc",
1117 "chromeos/login/session/user_session_manager_test_api.h",
Brett Wilson052ce132014-09-12 19:46:291118 "chromeos/login/test/js_checker.cc",
1119 "chromeos/login/test/js_checker.h",
satoruxb7a72ea2015-02-13 07:19:591120 "chromeos/login/test/oobe_screen_waiter.cc",
1121 "chromeos/login/test/oobe_screen_waiter.h",
Brett Wilson052ce132014-09-12 19:46:291122 "chromeos/login/ui/mock_login_display.cc",
1123 "chromeos/login/ui/mock_login_display.h",
1124 "chromeos/login/ui/mock_login_display_host.cc",
1125 "chromeos/login/ui/mock_login_display_host.h",
brettw7d6ec2462015-01-07 13:00:511126 "chromeos/login/users/avatar/mock_user_image_manager.cc",
1127 "chromeos/login/users/avatar/mock_user_image_manager.h",
merkulova793f3022015-02-04 10:18:301128 "chromeos/login/users/fake_chrome_user_manager.cc",
1129 "chromeos/login/users/fake_chrome_user_manager.h",
brettw7d6ec2462015-01-07 13:00:511130 "chromeos/login/users/fake_supervised_user_manager.cc",
1131 "chromeos/login/users/fake_supervised_user_manager.h",
brettw7d6ec2462015-01-07 13:00:511132 "chromeos/login/users/mock_user_manager.cc",
1133 "chromeos/login/users/mock_user_manager.h",
Brett Wilson052ce132014-09-12 19:46:291134 "chromeos/net/network_portal_detector_test_utils.cc",
1135 "chromeos/net/network_portal_detector_test_utils.h",
1136 "chromeos/policy/cloud_external_data_manager_base_test_util.cc",
1137 "chromeos/policy/cloud_external_data_manager_base_test_util.h",
1138 "chromeos/policy/device_policy_builder.cc",
1139 "chromeos/policy/device_policy_builder.h",
brettwa68ea2b2015-02-01 02:54:071140 "chromeos/policy/fake_consumer_management_service.cc",
1141 "chromeos/policy/fake_consumer_management_service.h",
Brett Wilson052ce132014-09-12 19:46:291142 "chromeos/policy/fake_device_cloud_policy_initializer.cc",
1143 "chromeos/policy/fake_device_cloud_policy_initializer.h",
brettwa68ea2b2015-02-01 02:54:071144 "chromeos/policy/fake_device_cloud_policy_manager.cc",
1145 "chromeos/policy/fake_device_cloud_policy_manager.h",
Brett Wilson052ce132014-09-12 19:46:291146 "chromeos/policy/stub_enterprise_install_attributes.cc",
1147 "chromeos/policy/stub_enterprise_install_attributes.h",
1148 "chromeos/settings/device_settings_test_helper.cc",
1149 "chromeos/settings/device_settings_test_helper.h",
1150 "chromeos/system/fake_input_device_settings.cc",
1151 "chromeos/system/fake_input_device_settings.h",
1152 ]
1153 configs += [ "//build/config/linux:dbus" ]
mukai6ba73552014-10-09 19:05:171154 deps += [ "//chromeos:test_support" ]
Brett Wilson052ce132014-09-12 19:46:291155 }
1156
1157 if (enable_configuration_policy) {
1158 sources += [
1159 "policy/test/local_policy_test_server.cc",
1160 "policy/test/local_policy_test_server.h",
1161 ]
Brett Wilsone53895272014-09-23 23:41:461162 public_deps += [
Brett Wilson052ce132014-09-12 19:46:291163 "//components/policy:policy_component_test_support",
1164 "//components/policy:test_support",
1165 ]
Brett Wilson052ce132014-09-12 19:46:291166 }
1167
1168 if (safe_browsing_mode == 1) {
1169 sources += [
1170 "extensions/fake_safe_browsing_database_manager.cc",
1171 "extensions/fake_safe_browsing_database_manager.h",
1172 ]
1173 }
1174
1175 if (enable_extensions) {
1176 sources += [
Brett Wilson052ce132014-09-12 19:46:291177 "extensions/api/messaging/native_messaging_test_util.cc",
1178 "extensions/api/messaging/native_messaging_test_util.h",
1179 "extensions/extension_notification_observer.cc",
1180 "extensions/extension_notification_observer.h",
Brett Wilson052ce132014-09-12 19:46:291181 "extensions/mock_extension_special_storage_policy.cc",
1182 "extensions/mock_extension_special_storage_policy.h",
1183 "extensions/test_blacklist.cc",
1184 "extensions/test_blacklist.h",
1185 "extensions/test_blacklist_state_fetcher.cc",
1186 "extensions/test_blacklist_state_fetcher.h",
brettw7d6ec2462015-01-07 13:00:511187 "extensions/test_extension_dir.cc",
1188 "extensions/test_extension_dir.h",
satoruxb7a72ea2015-02-13 07:19:591189 "extensions/test_extension_environment.cc",
1190 "extensions/test_extension_environment.h",
Brett Wilson052ce132014-09-12 19:46:291191 "extensions/test_extension_prefs.cc",
1192 "extensions/test_extension_prefs.h",
1193 "extensions/test_extension_service.cc",
1194 "extensions/test_extension_service.h",
1195 "extensions/test_extension_system.cc",
1196 "extensions/test_extension_system.h",
1197 "media_galleries/media_galleries_test_util.cc",
1198 "media_galleries/media_galleries_test_util.h",
1199 ]
lukasza8acc4eb2015-07-20 20:57:201200 deps += [
1201 "//components/drive:test_support",
1202 "//components/storage_monitor:test_support",
1203 ]
Brett Wilson052ce132014-09-12 19:46:291204 }
1205
1206 if (enable_mdns) {
1207 sources += [
1208 "local_discovery/test_service_discovery_client.cc",
1209 "local_discovery/test_service_discovery_client.h",
1210 ]
1211 }
1212
1213 if (enable_app_list) {
1214 sources += [
1215 "ui/app_list/test/chrome_app_list_test_support.cc",
1216 "ui/app_list/test/chrome_app_list_test_support.h",
brettw7d6ec2462015-01-07 13:00:511217 "ui/app_list/test/test_app_list_controller_delegate.cc",
1218 "ui/app_list/test/test_app_list_controller_delegate.h",
Brett Wilson052ce132014-09-12 19:46:291219 ]
1220 }
1221
1222 if (enable_wifi_bootstrapping) {
1223 sources += [
1224 "local_discovery/wifi/mock_wifi_manager.cc",
1225 "local_discovery/wifi/mock_wifi_manager.h",
1226 ]
1227 }
1228}
sdefresned967d552015-07-16 08:34:351229
thestig65d7c5c2015-10-06 18:13:471230# In GYP this is part of test_support_ui.
1231source_set("test_support_ui") {
1232 testonly = true
1233
1234 # Always include this via the main test support UI target.
1235 visibility = [ "//chrome/test:test_support_ui" ]
1236
1237 sources = [
1238 "password_manager/password_manager_test_base.cc",
1239 "password_manager/password_manager_test_base.h",
1240 "ui/webui/signin/login_ui_test_utils.cc",
1241 "ui/webui/signin/login_ui_test_utils.h",
1242 ]
1243
1244 configs += [ "//build/config:precompiled_headers" ]
1245
1246 deps = [
1247 "//components/metrics:test_support",
1248 "//skia",
1249 "//testing/gtest",
1250 ]
1251}
1252
sdefresned967d552015-07-16 08:34:351253if (enable_rlz_support) {
1254 source_set("rlz") {
1255 sources =
1256 rebase_path(gypi_values.chrome_browser_rlz_sources, ".", "//chrome")
1257 deps = [
1258 "//components/google/core/browser",
1259 "//components/omnibox/browser",
1260 "//components/rlz",
1261 "//components/search_engines",
1262 "//rlz:rlz_lib",
1263 ]
1264 }
1265}