blob: e18c0b953bdfd90bcf2552a0c6313ab1bf528d85 [file] [log] [blame]
[email protected]6b9028ab2014-07-23 17:15:381# 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
5import("//build/config/features.gni")
brettw4cab0f12015-09-14 21:40:016import("//build/config/sanitizers/sanitizers.gni")
[email protected]6b9028ab2014-07-23 17:15:387import("//build/config/ui.gni")
skobes502412ae2016-01-19 17:40:438import("//build/config/win/console_app.gni")
brettw2e2220c2015-07-21 18:56:359import("//build/config/win/manifest.gni")
alokpaa2fdfb72016-02-03 22:55:5410import("//media/media_options.gni")
[email protected]6b9028ab2014-07-23 17:15:3811import("//tools/grit/repack.gni")
cjhopmancd7694af2014-09-08 00:00:0412import("//tools/grit/grit_rule.gni")
[email protected]6b9028ab2014-07-23 17:15:3813if (is_android) {
14 import("//build/config/android/config.gni")
15}
16
17declare_args() {
18 content_shell_product_name = "Content Shell"
esprehnb3789092015-11-24 19:46:0319 content_shell_version = "99.77.34.5"
[email protected]6b9028ab2014-07-23 17:15:3820}
21
thakisff2eab9c2015-11-13 00:29:5822config("content_shell_lib_warnings") {
23 if (is_clang) {
24 # TODO(thakis): Remove this once http://crbug.com/383820 is figured out
25 cflags = [ "-Wno-nonnull" ]
26 }
27}
28
[email protected]6b9028ab2014-07-23 17:15:3829static_library("content_shell_lib") {
Brett Wilson8f80ad0b2014-09-08 19:50:2430 testonly = true
[email protected]6b9028ab2014-07-23 17:15:3831 sources = [
dprankec6beb8392015-10-30 23:44:2132 "android/shell_descriptors.h",
[email protected]6b9028ab2014-07-23 17:15:3833 "android/shell_jni_registrar.cc",
34 "android/shell_jni_registrar.h",
35 "android/shell_manager.cc",
36 "android/shell_manager.h",
37 "app/paths_mac.h",
38 "app/paths_mac.mm",
rseseka0a7a042014-09-18 23:59:2039 "app/shell_crash_reporter_client.cc",
40 "app/shell_crash_reporter_client.h",
[email protected]6b9028ab2014-07-23 17:15:3841 "app/shell_main_delegate.cc",
42 "app/shell_main_delegate.h",
43 "app/shell_main_delegate_mac.h",
44 "app/shell_main_delegate_mac.mm",
tfarinacde91252015-05-06 16:10:4945 "browser/blink_test_controller.cc",
46 "browser/blink_test_controller.h",
mkwstd6805d0d2014-10-16 14:44:3747 "browser/layout_test/layout_test_android.cc",
48 "browser/layout_test/layout_test_android.h",
ortunofd24faa2015-05-20 16:34:3749 "browser/layout_test/layout_test_bluetooth_adapter_provider.cc",
50 "browser/layout_test/layout_test_bluetooth_adapter_provider.h",
jyasskin8057c002015-09-10 19:09:5351 "browser/layout_test/layout_test_bluetooth_chooser_factory.cc",
52 "browser/layout_test/layout_test_bluetooth_chooser_factory.h",
mkwstd993d06a2014-10-10 11:44:3853 "browser/layout_test/layout_test_browser_context.cc",
54 "browser/layout_test/layout_test_browser_context.h",
mkwst88e23182014-10-16 12:08:5855 "browser/layout_test/layout_test_browser_main.cc",
56 "browser/layout_test/layout_test_browser_main.h",
mkwst36b11b6f2014-10-15 16:18:5657 "browser/layout_test/layout_test_browser_main_parts.cc",
58 "browser/layout_test/layout_test_browser_main_parts.h",
petercd7abb42014-10-17 13:34:0159 "browser/layout_test/layout_test_content_browser_client.cc",
60 "browser/layout_test/layout_test_content_browser_client.h",
mkwst30d20d52014-10-09 13:33:1461 "browser/layout_test/layout_test_devtools_frontend.cc",
62 "browser/layout_test/layout_test_devtools_frontend.h",
mkwst94388f792014-10-16 07:36:5263 "browser/layout_test/layout_test_download_manager_delegate.cc",
64 "browser/layout_test/layout_test_download_manager_delegate.h",
mkwst6efe7f2e62014-10-08 15:09:0165 "browser/layout_test/layout_test_javascript_dialog_manager.cc",
66 "browser/layout_test/layout_test_javascript_dialog_manager.h",
Peter Beverlooe8f2f9d2014-10-20 16:47:4967 "browser/layout_test/layout_test_message_filter.cc",
68 "browser/layout_test/layout_test_message_filter.h",
mekc9182202015-03-03 17:56:0769 "browser/layout_test/layout_test_navigator_connect_service_factory.cc",
70 "browser/layout_test/layout_test_navigator_connect_service_factory.h",
petercd7abb42014-10-17 13:34:0171 "browser/layout_test/layout_test_notification_manager.cc",
72 "browser/layout_test/layout_test_notification_manager.h",
mlamouri4e372022015-03-29 14:51:0673 "browser/layout_test/layout_test_permission_manager.cc",
74 "browser/layout_test/layout_test_permission_manager.h",
mvanouwerkerkde895c9c2014-12-06 12:17:3275 "browser/layout_test/layout_test_push_messaging_service.cc",
76 "browser/layout_test/layout_test_push_messaging_service.h",
mkwst002d02902014-10-09 10:17:0077 "browser/layout_test/layout_test_resource_dispatcher_host_delegate.cc",
78 "browser/layout_test/layout_test_resource_dispatcher_host_delegate.h",
mkwst94388f792014-10-16 07:36:5279 "browser/layout_test/layout_test_url_request_context_getter.cc",
80 "browser/layout_test/layout_test_url_request_context_getter.h",
[email protected]6b9028ab2014-07-23 17:15:3881 "browser/notify_done_forwarder.cc",
82 "browser/notify_done_forwarder.h",
peter11d5f562014-10-23 23:12:2583 "browser/shell.cc",
84 "browser/shell.h",
85 "browser/shell_access_token_store.cc",
86 "browser/shell_access_token_store.h",
[email protected]6b9028ab2014-07-23 17:15:3887 "browser/shell_android.cc",
88 "browser/shell_application_mac.h",
89 "browser/shell_application_mac.mm",
90 "browser/shell_browser_context.cc",
91 "browser/shell_browser_context.h",
92 "browser/shell_browser_main.cc",
93 "browser/shell_browser_main.h",
94 "browser/shell_browser_main_parts.cc",
95 "browser/shell_browser_main_parts.h",
96 "browser/shell_browser_main_parts_mac.mm",
[email protected]6b9028ab2014-07-23 17:15:3897 "browser/shell_content_browser_client.cc",
98 "browser/shell_content_browser_client.h",
[email protected]6b9028ab2014-07-23 17:15:3899 "browser/shell_devtools_frontend.cc",
100 "browser/shell_devtools_frontend.h",
satorux7fa9d302015-02-16 00:44:52101 "browser/shell_devtools_manager_delegate.cc",
102 "browser/shell_devtools_manager_delegate.h",
[email protected]6b9028ab2014-07-23 17:15:38103 "browser/shell_download_manager_delegate.cc",
104 "browser/shell_download_manager_delegate.h",
[email protected]6b9028ab2014-07-23 17:15:38105 "browser/shell_javascript_dialog.h",
106 "browser/shell_javascript_dialog_mac.mm",
107 "browser/shell_javascript_dialog_manager.cc",
108 "browser/shell_javascript_dialog_manager.h",
109 "browser/shell_javascript_dialog_win.cc",
[email protected]6b9028ab2014-07-23 17:15:38110 "browser/shell_login_dialog.cc",
111 "browser/shell_login_dialog.h",
112 "browser/shell_login_dialog_mac.mm",
113 "browser/shell_mac.mm",
satorux7fa9d302015-02-16 00:44:52114 "browser/shell_mojo_test_utils_android.cc",
115 "browser/shell_mojo_test_utils_android.h",
[email protected]6b9028ab2014-07-23 17:15:38116 "browser/shell_net_log.cc",
117 "browser/shell_net_log.h",
118 "browser/shell_network_delegate.cc",
119 "browser/shell_network_delegate.h",
mlamouri4e372022015-03-29 14:51:06120 "browser/shell_permission_manager.cc",
121 "browser/shell_permission_manager.h",
[email protected]6b9028ab2014-07-23 17:15:38122 "browser/shell_platform_data_aura.cc",
123 "browser/shell_platform_data_aura.h",
124 "browser/shell_plugin_service_filter.cc",
125 "browser/shell_plugin_service_filter.h",
126 "browser/shell_quota_permission_context.cc",
127 "browser/shell_quota_permission_context.h",
128 "browser/shell_resource_dispatcher_host_delegate.cc",
129 "browser/shell_resource_dispatcher_host_delegate.h",
130 "browser/shell_speech_recognition_manager_delegate.cc",
131 "browser/shell_speech_recognition_manager_delegate.h",
132 "browser/shell_url_request_context_getter.cc",
133 "browser/shell_url_request_context_getter.h",
satorux7fa9d302015-02-16 00:44:52134 "browser/shell_web_contents_view_delegate.h",
[email protected]6b9028ab2014-07-23 17:15:38135 "browser/shell_web_contents_view_delegate_android.cc",
136 "browser/shell_web_contents_view_delegate_creator.h",
[email protected]6b9028ab2014-07-23 17:15:38137 "browser/shell_web_contents_view_delegate_mac.mm",
138 "browser/shell_web_contents_view_delegate_win.cc",
petere04203592014-10-27 17:57:35139 "common/layout_test/layout_test_messages.cc",
140 "common/layout_test/layout_test_messages.h",
[email protected]6b9028ab2014-07-23 17:15:38141 "common/leak_detection_result.h",
142 "common/shell_content_client.cc",
143 "common/shell_content_client.h",
144 "common/shell_messages.cc",
145 "common/shell_messages.h",
146 "common/shell_switches.cc",
147 "common/shell_switches.h",
148 "common/shell_test_configuration.cc",
149 "common/shell_test_configuration.h",
tfarina685c39802015-05-04 22:11:22150 "renderer/layout_test/blink_test_helpers.cc",
151 "renderer/layout_test/blink_test_helpers.h",
tfarina8e08285f2015-05-02 03:17:39152 "renderer/layout_test/blink_test_runner.cc",
153 "renderer/layout_test/blink_test_runner.h",
mkwst02ec0d62014-10-07 22:07:29154 "renderer/layout_test/layout_test_content_renderer_client.cc",
155 "renderer/layout_test/layout_test_content_renderer_client.h",
mkwst3e72c1f2014-10-08 05:02:36156 "renderer/layout_test/layout_test_render_frame_observer.cc",
157 "renderer/layout_test/layout_test_render_frame_observer.h",
mkwst99069fc2014-10-08 06:13:28158 "renderer/layout_test/layout_test_render_process_observer.cc",
159 "renderer/layout_test/layout_test_render_process_observer.h",
mkwst04b72d12014-10-08 15:52:55160 "renderer/layout_test/leak_detector.cc",
161 "renderer/layout_test/leak_detector.h",
jochen51265132015-05-28 07:33:45162 "renderer/layout_test/test_media_stream_renderer_factory.cc",
163 "renderer/layout_test/test_media_stream_renderer_factory.h",
164 "renderer/layout_test/test_video_frame_provider.cc",
165 "renderer/layout_test/test_video_frame_provider.h",
[email protected]6b9028ab2014-07-23 17:15:38166 "renderer/shell_content_renderer_client.cc",
167 "renderer/shell_content_renderer_client.h",
[email protected]6b9028ab2014-07-23 17:15:38168 "renderer/shell_render_view_observer.cc",
169 "renderer/shell_render_view_observer.h",
rockotb814a582015-06-05 00:30:52170 "utility/shell_content_utility_client.cc",
171 "utility/shell_content_utility_client.h",
[email protected]6b9028ab2014-07-23 17:15:38172 ]
173
brettwbc8b2a22015-07-28 18:24:42174 configs += [
thakisff2eab9c2015-11-13 00:29:58175 ":content_shell_lib_warnings",
brettwbc8b2a22015-07-28 18:24:42176 "//build/config:precompiled_headers",
177
178 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
179 "//build/config/compiler:no_size_t_to_int_warning",
kozyatinskiy6adbc802016-01-28 00:16:16180
181 "//third_party/WebKit/public:debug_devtools",
brettwbc8b2a22015-07-28 18:24:42182 ]
brettwd1c719a2015-02-19 23:17:04183
[email protected]6b9028ab2014-07-23 17:15:38184 defines = [ "CONTENT_SHELL_VERSION=\"$content_shell_version\"" ]
185
Brett Wilson0380637c2014-09-19 21:24:40186 public_deps = [
187 # This exposes all public content APIs.
188 "//content/public/app:both",
189 "//content/public/browser",
190 "//content/public/common",
191 "//content/public/plugin",
192 "//content/public/renderer",
193 "//content/public/utility",
194 ]
[email protected]6b9028ab2014-07-23 17:15:38195 deps = [
196 ":resources",
197 "//base",
198 "//base:base_static",
[email protected]6b9028ab2014-07-23 17:15:38199 "//base/third_party/dynamic_annotations",
200 "//cc",
scottmgcfa5b01b2015-11-30 23:13:46201 "//components/crash/content/app:app_breakpad_mac_win_to_be_deleted",
dgozmanf7200152015-04-22 17:48:21202 "//components/devtools_discovery",
dgozman102fee92015-04-20 15:45:46203 "//components/devtools_http_handler",
chrishtr8a377e62015-06-01 19:20:08204 "//components/plugins/renderer",
jochen73e711c2015-06-03 10:01:46205 "//components/test_runner:test_runner",
rsleevi24f64dc22015-08-07 21:39:21206 "//components/url_formatter",
hanxi149b92d2014-09-11 21:57:18207 "//components/web_cache/renderer",
[email protected]6b9028ab2014-07-23 17:15:38208 "//content:resources",
[email protected]a9ca8d52014-08-22 10:21:08209 "//content/app/resources",
[email protected]6586a2e32014-08-09 19:24:12210 "//content/app/strings",
[email protected]6b9028ab2014-07-23 17:15:38211 "//content/gpu",
[email protected]6b9028ab2014-07-23 17:15:38212 "//content/test:layouttest_support",
dpranke93211fc2015-04-29 04:59:42213 "//device/bluetooth",
ortunofd24faa2015-05-20 16:34:37214 "//device/bluetooth:mocks",
[email protected]6b9028ab2014-07-23 17:15:38215 "//gin",
216 "//gpu",
217 "//ipc",
218 "//media",
219 "//net",
220 "//net:net_resources",
221 "//skia",
pilgrim4af8c212014-09-05 17:30:15222 "//storage/browser",
ortunofd24faa2015-05-20 16:34:37223 "//testing/gmock",
224 "//testing/gtest",
[email protected]6b9028ab2014-07-23 17:15:38225 "//third_party/WebKit/public:blink",
erga3c614c92015-04-03 17:47:51226 "//third_party/WebKit/public:image_resources",
[email protected]4eebe74d2014-08-13 02:54:46227 "//third_party/WebKit/public:resources",
[email protected]0e043592014-07-28 19:47:04228 "//third_party/WebKit/public:test_support",
[email protected]4eebe74d2014-08-13 02:54:46229 "//third_party/icu",
[email protected]6b9028ab2014-07-23 17:15:38230 "//ui/base",
spang1c36fac2015-02-05 19:55:12231 "//ui/base/ime",
[email protected]6b9028ab2014-07-23 17:15:38232 "//ui/events:events_base",
233 "//ui/gfx",
234 "//ui/gfx/geometry",
235 "//ui/gfx/ipc",
236 "//ui/gl",
237 "//url",
238 "//v8",
scottmg7afc4092014-12-03 19:22:42239
[email protected]6b9028ab2014-07-23 17:15:38240 #'copy_test_netscape_plugin', TODO(GYP)
[email protected]6b9028ab2014-07-23 17:15:38241 ]
jamesr50081742014-09-09 07:52:22242 if (enable_plugins) {
dcheng0d93c1a2015-12-03 02:46:41243 deps += [
244 "//content/ppapi_plugin",
245 "//ppapi:blink_test_plugin",
246 ]
jamesr50081742014-09-09 07:52:22247 }
alokpaa2fdfb72016-02-03 22:55:54248 if (enable_mojo_media != "none") {
249 deps += [ "//media/mojo/services:default_application" ]
250 }
[email protected]6b9028ab2014-07-23 17:15:38251
252 if (is_win) {
[email protected]6b9028ab2014-07-23 17:15:38253 #'LinkIncremental': '<(msvs_large_module_debug_link_mode)', TODO(GYP)
vchigrin61944ae2015-01-30 23:51:32254 sources += [
255 "common/v8_breakpad_support_win.cc",
256 "common/v8_breakpad_support_win.h",
257 ]
[email protected]6b9028ab2014-07-23 17:15:38258 }
259
260 if (is_linux) {
slan17e5ce7f2015-09-25 00:04:45261 deps += [ "//build/linux:fontconfig" ]
[email protected]6b9028ab2014-07-23 17:15:38262 }
263
264 if (use_x11) {
[email protected]c7990dbf2014-07-23 22:35:10265 # Some tests rely on this tool at runtime. Note: it might be better if
266 # the tests that needed it had this as a dep instead of adding it here.
sadrul1f7fa9f2015-10-06 17:14:57267 data_deps = [
268 "//tools/xdisplaycheck",
269 ]
dnicoara78a734702014-11-04 19:54:38270
271 deps += [ "//ui/events/devices" ]
[email protected]6b9028ab2014-07-23 17:15:38272 }
273
274 if (is_android) {
James Robinson060f2e32014-09-10 22:31:37275 deps += [ "//content/shell/android:content_shell_jni_headers" ]
cjhopmancd7694af2014-09-08 00:00:04276 #deps -= [ "copy_test_netscape_plugin" ] TODO(GYP)
[email protected]6b9028ab2014-07-23 17:15:38277 }
278
torne1b1c9782015-03-30 20:49:00279 if (is_posix && !is_mac) {
sdefresne8ba0b88c2015-09-18 10:33:13280 deps += [ "//components/crash/content/browser" ]
[email protected]6b9028ab2014-07-23 17:15:38281 }
282
283 if (use_aura) {
284 deps += [
285 "//ui/aura",
286 "//ui/aura:test_support",
287 "//ui/events",
288 "//ui/strings",
289 "//ui/wm",
290 ]
291
292 if (toolkit_views) {
293 sources += [ "browser/shell_views.cc" ]
294 deps += [
295 "//ui/resources",
[email protected]6b9028ab2014-07-23 17:15:38296 "//ui/views",
297 "//ui/views:test_support",
agrieved7a71c882015-11-20 19:53:28298 "//ui/views/controls/webview",
[email protected]6b9028ab2014-07-23 17:15:38299 ]
300 } else {
301 sources += [ "browser/shell_aura.cc" ]
302 }
James Robinson060f2e32014-09-10 22:31:37303 } else {
304 sources -= [
305 "browser/shell_platform_data_aura.cc",
306 "browser/shell_platform_data_aura.h",
307 ]
[email protected]6b9028ab2014-07-23 17:15:38308 }
309
310 # The test plugin relies on X11.
311 if (is_linux && !use_x11) {
312 #deps -= [ 'copy_test_netscape_plugin' ] TODO(GYP)
313 }
314
315 if (is_chromeos) {
316 deps += [
mukai6ba73552014-10-09 19:05:17317 "//chromeos",
[email protected]6b9028ab2014-07-23 17:15:38318 "//ui/wm:test_support",
[email protected]6b9028ab2014-07-23 17:15:38319 ]
320 }
321
bcf0ddf78a2016-02-02 18:52:21322 if (is_linux) {
[email protected]6b9028ab2014-07-23 17:15:38323 deps += [ "//third_party/freetype2" ]
324 }
325
326 if (!enable_plugins) {
327 sources -= [
328 "browser/shell_plugin_service_filter.cc",
329 "browser/shell_plugin_service_filter.h",
330 ]
331 }
332}
333
334grit("content_shell_resources_grit") {
brettw9af42622014-09-06 21:21:02335 visibility = [ ":*" ]
[email protected]6b9028ab2014-07-23 17:15:38336 source = "shell_resources.grd"
337 outputs = [
338 "grit/shell_resources.h",
339 "shell_resources.pak",
[email protected]6b9028ab2014-07-23 17:15:38340 ]
341}
342
343copy("copy_shell_resources") {
scottmg7afc4092014-12-03 19:22:42344 sources = [
345 "$target_gen_dir/shell_resources.pak",
346 ]
scottmg34fb7e52014-12-03 23:27:24347 outputs = [
348 "$root_out_dir/shell_resources.pak",
349 ]
[email protected]6b9028ab2014-07-23 17:15:38350
scottmg7afc4092014-12-03 19:22:42351 public_deps = [
352 ":content_shell_resources_grit",
353 ]
[email protected]6b9028ab2014-07-23 17:15:38354}
355
[email protected]6b9028ab2014-07-23 17:15:38356group("resources") {
Brett Wilsone53895272014-09-23 23:41:46357 public_deps = [
[email protected]6b9028ab2014-07-23 17:15:38358 ":copy_shell_resources",
359 ]
jochen73e711c2015-06-03 10:01:46360 deps = [
361 "//components/test_runner:resources",
362 ]
[email protected]6b9028ab2014-07-23 17:15:38363}
364
365repack("pak") {
366 sources = [
erga3c614c92015-04-03 17:47:51367 "$root_gen_dir/blink/public/resources/blink_image_resources_100_percent.pak",
368 "$root_gen_dir/blink/public/resources/blink_resources.pak",
[email protected]a9ca8d52014-08-22 10:21:08369 "$root_gen_dir/content/app/resources/content_resources_100_percent.pak",
[email protected]6586a2e32014-08-09 19:24:12370 "$root_gen_dir/content/app/strings/content_strings_en-US.pak",
[email protected]6b9028ab2014-07-23 17:15:38371 "$root_gen_dir/content/browser/tracing/tracing_resources.pak",
[email protected]6586a2e32014-08-09 19:24:12372 "$root_gen_dir/content/content_resources.pak",
[email protected]6b9028ab2014-07-23 17:15:38373 "$root_gen_dir/content/shell/shell_resources.pak",
374 "$root_gen_dir/net/net_resources.pak",
375 "$root_gen_dir/ui/resources/ui_resources_100_percent.pak",
376 "$root_gen_dir/ui/resources/webui_resources.pak",
377 "$root_gen_dir/ui/strings/app_locale_settings_en-US.pak",
378 "$root_gen_dir/ui/strings/ui_strings_en-US.pak",
[email protected]6b9028ab2014-07-23 17:15:38379 ]
380
381 deps = [
382 ":resources",
383 "//content:resources",
[email protected]a9ca8d52014-08-22 10:21:08384 "//content/app/resources",
[email protected]6586a2e32014-08-09 19:24:12385 "//content/app/strings",
[email protected]6b9028ab2014-07-23 17:15:38386 "//content/browser/tracing:resources",
387 "//net:net_resources",
erga3c614c92015-04-03 17:47:51388 "//third_party/WebKit/public:image_resources",
[email protected]4eebe74d2014-08-13 02:54:46389 "//third_party/WebKit/public:resources",
[email protected]6b9028ab2014-07-23 17:15:38390 "//ui/resources",
391 "//ui/strings",
[email protected]6b9028ab2014-07-23 17:15:38392 ]
393
sadrul7bd20c92015-06-24 16:45:44394 if (toolkit_views) {
395 deps += [ "//ui/views/resources" ]
396 sources +=
397 [ "$root_gen_dir/ui/views/resources/views_resources_100_percent.pak" ]
398 }
399
vivek.vg77816a12014-12-18 14:28:20400 sources += [ "$root_gen_dir/blink/devtools_resources.pak" ]
cjhopman2fd48fd2014-09-24 00:52:56401 deps += [ "//content/browser/devtools:resources" ]
402 output = "$root_out_dir/content_shell.pak"
[email protected]6b9028ab2014-07-23 17:15:38403}
404
James Robinson060f2e32014-09-10 22:31:37405# TODO(GYP): Figure out what this should be on android
dpranke380390f2014-11-21 06:08:53406# and make linking this work on the Mac.
brettw4897a612015-03-02 23:13:15407if (!is_android && !is_mac) {
brettw2e2220c2015-07-21 18:56:35408 # TODO(brettw) when GYP is no longer necessary, delete
409 # content/shell/app/shell.exe.manifest. This file is not used in GN.
scottmg7afc4092014-12-03 19:22:42410 executable("content_shell") {
411 testonly = true
James Robinson060f2e32014-09-10 22:31:37412
scottmg7afc4092014-12-03 19:22:42413 # TODO(GYP) mac resource bundle stuff for this target.
414 # TODO(GYP) Windows content shell settings:
scottmg7afc4092014-12-03 19:22:42415 # - RC file.
416 # - 'LinkIncremental': '<(msvs_large_module_debug_link_mode)',
417 sources = [
scottmg7afc4092014-12-03 19:22:42418 "app/shell_main.cc",
419 ]
[email protected]6b9028ab2014-07-23 17:15:38420
skobes502412ae2016-01-19 17:40:43421 defines = []
422
scottmg7afc4092014-12-03 19:22:42423 deps = [
424 ":content_shell_lib",
425 ":pak",
brettwba7a73d2015-08-31 22:17:39426 "//build/config/sanitizers:deps",
brettw2e2220c2015-07-21 18:56:35427 "//build/win:default_exe_manifest",
scottmg7afc4092014-12-03 19:22:42428 ]
[email protected]6b9028ab2014-07-23 17:15:38429
scottmg7afc4092014-12-03 19:22:42430 if (is_win) {
431 deps += [ "//sandbox" ]
skobes502412ae2016-01-19 17:40:43432 if (win_console_app) {
433 defines += [ "WIN_CONSOLE_APP" ]
434 } else {
435 # Set /SUBSYSTEM:WINDOWS unless a console build has been requested.
scottmg7afc4092014-12-03 19:22:42436 configs -= [ "//build/config/win:console" ]
437 configs += [ "//build/config/win:windowed" ]
438 }
439 }
440
441 if (is_mac) {
brettwe1d40652015-10-23 23:06:10442 # TODO(GYP) lots of stuff from GYP file here including helper_app and
443 # postbuilds.
444 output_name = content_shell_product_name
445 deps = [
446 ":framework",
447 ]
scottmg7afc4092014-12-03 19:22:42448 }
449
torne1b1c9782015-03-30 20:49:00450 if (is_android) {
scottmg7afc4092014-12-03 19:22:42451 # Some tests rely on this tool. It might be nicer if these tests relied on
452 # image diff rather than having content shell depend on it.
sadrul1f7fa9f2015-10-06 17:14:57453 data_deps = [
454 "//tools/imagediff($host_toolchain)",
455 ]
[email protected]6b9028ab2014-07-23 17:15:38456 }
457 }
brettw6aa189562015-02-02 05:34:22458} else {
459 group("content_shell") {
dpranked4063e42015-05-01 01:23:42460 testonly = true
461 deps = [
462 ":content_shell_lib",
463 ]
brettw6aa189562015-02-02 05:34:22464 }
James Robinson060f2e32014-09-10 22:31:37465}
tfarina10ae51f62015-05-13 03:35:57466
tfarina795e01a2015-05-15 19:29:57467if (is_win) {
468 # GYP version: content/content_shell_and_tests.gyp:content_shell_crash_service
brettw0d3b1df2015-12-03 00:10:01469 executable("content_shell_crash_service") {
tfarina795e01a2015-05-15 19:29:57470 sources = [
471 "tools/content_shell_crash_service.cc",
472 ]
473
474 deps = [
475 "//base",
brettwba7a73d2015-08-31 22:17:39476 "//build/config/sanitizers:deps",
sdefresne8ba0b88c2015-09-18 10:33:13477 "//components/crash/content/tools:crash_service",
tfarina795e01a2015-05-15 19:29:57478 ]
479
480 configs -= [ "//build/config/win:console" ]
481 configs += [ "//build/config/win:windowed" ]
482 }
483}
brettwe1d40652015-10-23 23:06:10484
485if (is_mac) {
486 # TODO(GYP) this should be a bundle. Lots of other stuff in this target.
487 # GYP version: content/content_shell.gypi:content_shell_framework
488 shared_library("framework") {
489 testonly = true
490
491 # TODO(GYP) bug 546894: Fix GN and toolchains to handle spaces here.
492 #output_name = "$content_shell_product_name Framework"
493 output_name = "content_shell_framework" # Temporary one with no spaces.
494
495 sources = [
tfarinac708f3972015-10-25 17:42:50496 "app/shell_content_main.cc",
497 "app/shell_content_main.h",
brettwe1d40652015-10-23 23:06:10498 ]
499
500 deps = [
501 ":content_shell_lib",
502 ]
503 }
504}