blob: 12d7264f12de276b0cf2d32f14812ff6ec45dfc5 [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")
6import("//build/config/ui.gni")
[email protected]6b9028ab2014-07-23 17:15:387import("//tools/grit/repack.gni")
cjhopmancd7694af2014-09-08 00:00:048import("//tools/grit/grit_rule.gni")
[email protected]6b9028ab2014-07-23 17:15:389if (is_android) {
10 import("//build/config/android/config.gni")
11}
12
13declare_args() {
14 content_shell_product_name = "Content Shell"
15
16 # The "19" is so that sites that sniff for version think that this is
17 # something reasonably current; the "77.34.5" is a hint that this isn't a
18 # standard Chrome.
19 content_shell_version = "19.77.34.5"
20}
21
22static_library("content_shell_lib") {
Brett Wilson8f80ad0b2014-09-08 19:50:2423 testonly = true
[email protected]6b9028ab2014-07-23 17:15:3824 sources = [
25 "android/shell_jni_registrar.cc",
26 "android/shell_jni_registrar.h",
27 "android/shell_manager.cc",
28 "android/shell_manager.h",
tfarina4d06f572014-10-17 03:36:4829 "app/blink_test_platform_support.h",
30 "app/blink_test_platform_support_android.cc",
31 "app/blink_test_platform_support_linux.cc",
32 "app/blink_test_platform_support_mac.mm",
33 "app/blink_test_platform_support_win.cc",
[email protected]6b9028ab2014-07-23 17:15:3834 "app/paths_mac.h",
35 "app/paths_mac.mm",
rseseka0a7a042014-09-18 23:59:2036 "app/shell_crash_reporter_client.cc",
37 "app/shell_crash_reporter_client.h",
[email protected]6b9028ab2014-07-23 17:15:3838 "app/shell_main_delegate.cc",
39 "app/shell_main_delegate.h",
40 "app/shell_main_delegate_mac.h",
41 "app/shell_main_delegate_mac.mm",
tfarinacde91252015-05-06 16:10:4942 "browser/blink_test_controller.cc",
43 "browser/blink_test_controller.h",
[email protected]9cd36bfb2014-08-20 00:32:0044 "browser/ipc_echo_message_filter.cc",
45 "browser/ipc_echo_message_filter.h",
mkwstd6805d0d2014-10-16 14:44:3746 "browser/layout_test/layout_test_android.cc",
47 "browser/layout_test/layout_test_android.h",
ortunofd24faa2015-05-20 16:34:3748 "browser/layout_test/layout_test_bluetooth_adapter_provider.cc",
49 "browser/layout_test/layout_test_bluetooth_adapter_provider.h",
mkwstd993d06a2014-10-10 11:44:3850 "browser/layout_test/layout_test_browser_context.cc",
51 "browser/layout_test/layout_test_browser_context.h",
mkwst88e23182014-10-16 12:08:5852 "browser/layout_test/layout_test_browser_main.cc",
53 "browser/layout_test/layout_test_browser_main.h",
mkwst36b11b6f2014-10-15 16:18:5654 "browser/layout_test/layout_test_browser_main_parts.cc",
55 "browser/layout_test/layout_test_browser_main_parts.h",
petercd7abb42014-10-17 13:34:0156 "browser/layout_test/layout_test_content_browser_client.cc",
57 "browser/layout_test/layout_test_content_browser_client.h",
mkwst30d20d52014-10-09 13:33:1458 "browser/layout_test/layout_test_devtools_frontend.cc",
59 "browser/layout_test/layout_test_devtools_frontend.h",
mkwst94388f792014-10-16 07:36:5260 "browser/layout_test/layout_test_download_manager_delegate.cc",
61 "browser/layout_test/layout_test_download_manager_delegate.h",
mkwst6efe7f2e62014-10-08 15:09:0162 "browser/layout_test/layout_test_javascript_dialog_manager.cc",
63 "browser/layout_test/layout_test_javascript_dialog_manager.h",
Peter Beverlooe8f2f9d2014-10-20 16:47:4964 "browser/layout_test/layout_test_message_filter.cc",
65 "browser/layout_test/layout_test_message_filter.h",
mekc9182202015-03-03 17:56:0766 "browser/layout_test/layout_test_navigator_connect_service_factory.cc",
67 "browser/layout_test/layout_test_navigator_connect_service_factory.h",
petercd7abb42014-10-17 13:34:0168 "browser/layout_test/layout_test_notification_manager.cc",
69 "browser/layout_test/layout_test_notification_manager.h",
mlamouri4e372022015-03-29 14:51:0670 "browser/layout_test/layout_test_permission_manager.cc",
71 "browser/layout_test/layout_test_permission_manager.h",
mvanouwerkerkde895c9c2014-12-06 12:17:3272 "browser/layout_test/layout_test_push_messaging_service.cc",
73 "browser/layout_test/layout_test_push_messaging_service.h",
mkwst002d02902014-10-09 10:17:0074 "browser/layout_test/layout_test_resource_dispatcher_host_delegate.cc",
75 "browser/layout_test/layout_test_resource_dispatcher_host_delegate.h",
mkwst94388f792014-10-16 07:36:5276 "browser/layout_test/layout_test_url_request_context_getter.cc",
77 "browser/layout_test/layout_test_url_request_context_getter.h",
[email protected]6b9028ab2014-07-23 17:15:3878 "browser/notify_done_forwarder.cc",
79 "browser/notify_done_forwarder.h",
peter11d5f562014-10-23 23:12:2580 "browser/shell.cc",
81 "browser/shell.h",
82 "browser/shell_access_token_store.cc",
83 "browser/shell_access_token_store.h",
[email protected]6b9028ab2014-07-23 17:15:3884 "browser/shell_android.cc",
85 "browser/shell_application_mac.h",
86 "browser/shell_application_mac.mm",
87 "browser/shell_browser_context.cc",
88 "browser/shell_browser_context.h",
89 "browser/shell_browser_main.cc",
90 "browser/shell_browser_main.h",
91 "browser/shell_browser_main_parts.cc",
92 "browser/shell_browser_main_parts.h",
93 "browser/shell_browser_main_parts_mac.mm",
[email protected]6b9028ab2014-07-23 17:15:3894 "browser/shell_content_browser_client.cc",
95 "browser/shell_content_browser_client.h",
[email protected]6b9028ab2014-07-23 17:15:3896 "browser/shell_devtools_frontend.cc",
97 "browser/shell_devtools_frontend.h",
satorux7fa9d302015-02-16 00:44:5298 "browser/shell_devtools_manager_delegate.cc",
99 "browser/shell_devtools_manager_delegate.h",
[email protected]6b9028ab2014-07-23 17:15:38100 "browser/shell_download_manager_delegate.cc",
101 "browser/shell_download_manager_delegate.h",
[email protected]6b9028ab2014-07-23 17:15:38102 "browser/shell_javascript_dialog.h",
103 "browser/shell_javascript_dialog_mac.mm",
104 "browser/shell_javascript_dialog_manager.cc",
105 "browser/shell_javascript_dialog_manager.h",
106 "browser/shell_javascript_dialog_win.cc",
[email protected]6b9028ab2014-07-23 17:15:38107 "browser/shell_login_dialog.cc",
108 "browser/shell_login_dialog.h",
109 "browser/shell_login_dialog_mac.mm",
110 "browser/shell_mac.mm",
satorux7fa9d302015-02-16 00:44:52111 "browser/shell_mojo_test_utils_android.cc",
112 "browser/shell_mojo_test_utils_android.h",
[email protected]6b9028ab2014-07-23 17:15:38113 "browser/shell_net_log.cc",
114 "browser/shell_net_log.h",
115 "browser/shell_network_delegate.cc",
116 "browser/shell_network_delegate.h",
mlamouri4e372022015-03-29 14:51:06117 "browser/shell_permission_manager.cc",
118 "browser/shell_permission_manager.h",
[email protected]6b9028ab2014-07-23 17:15:38119 "browser/shell_platform_data_aura.cc",
120 "browser/shell_platform_data_aura.h",
121 "browser/shell_plugin_service_filter.cc",
122 "browser/shell_plugin_service_filter.h",
123 "browser/shell_quota_permission_context.cc",
124 "browser/shell_quota_permission_context.h",
125 "browser/shell_resource_dispatcher_host_delegate.cc",
126 "browser/shell_resource_dispatcher_host_delegate.h",
127 "browser/shell_speech_recognition_manager_delegate.cc",
128 "browser/shell_speech_recognition_manager_delegate.h",
129 "browser/shell_url_request_context_getter.cc",
130 "browser/shell_url_request_context_getter.h",
satorux7fa9d302015-02-16 00:44:52131 "browser/shell_web_contents_view_delegate.h",
[email protected]6b9028ab2014-07-23 17:15:38132 "browser/shell_web_contents_view_delegate_android.cc",
133 "browser/shell_web_contents_view_delegate_creator.h",
[email protected]6b9028ab2014-07-23 17:15:38134 "browser/shell_web_contents_view_delegate_mac.mm",
135 "browser/shell_web_contents_view_delegate_win.cc",
petere04203592014-10-27 17:57:35136 "common/layout_test/layout_test_messages.cc",
137 "common/layout_test/layout_test_messages.h",
[email protected]6b9028ab2014-07-23 17:15:38138 "common/leak_detection_result.h",
139 "common/shell_content_client.cc",
140 "common/shell_content_client.h",
141 "common/shell_messages.cc",
142 "common/shell_messages.h",
143 "common/shell_switches.cc",
144 "common/shell_switches.h",
145 "common/shell_test_configuration.cc",
146 "common/shell_test_configuration.h",
147 "common/test_runner/test_preferences.cc",
148 "common/test_runner/test_preferences.h",
[email protected]9cd36bfb2014-08-20 00:32:00149 "renderer/ipc_echo.cc",
150 "renderer/ipc_echo.h",
tfarina685c39802015-05-04 22:11:22151 "renderer/layout_test/blink_test_helpers.cc",
152 "renderer/layout_test/blink_test_helpers.h",
tfarina8e08285f2015-05-02 03:17:39153 "renderer/layout_test/blink_test_runner.cc",
154 "renderer/layout_test/blink_test_runner.h",
mkwst04b72d12014-10-08 15:52:55155 "renderer/layout_test/gc_controller.cc",
156 "renderer/layout_test/gc_controller.h",
mkwst02ec0d62014-10-07 22:07:29157 "renderer/layout_test/layout_test_content_renderer_client.cc",
158 "renderer/layout_test/layout_test_content_renderer_client.h",
mkwst3e72c1f2014-10-08 05:02:36159 "renderer/layout_test/layout_test_render_frame_observer.cc",
160 "renderer/layout_test/layout_test_render_frame_observer.h",
mkwst99069fc2014-10-08 06:13:28161 "renderer/layout_test/layout_test_render_process_observer.cc",
162 "renderer/layout_test/layout_test_render_process_observer.h",
mkwst04b72d12014-10-08 15:52:55163 "renderer/layout_test/leak_detector.cc",
164 "renderer/layout_test/leak_detector.h",
jochen51265132015-05-28 07:33:45165 "renderer/layout_test/test_media_stream_renderer_factory.cc",
166 "renderer/layout_test/test_media_stream_renderer_factory.h",
chrishtr8a377e62015-06-01 19:20:08167 "renderer/layout_test/test_plugin_placeholder.cc",
168 "renderer/layout_test/test_plugin_placeholder.h",
jochen51265132015-05-28 07:33:45169 "renderer/layout_test/test_video_frame_provider.cc",
170 "renderer/layout_test/test_video_frame_provider.h",
[email protected]6b9028ab2014-07-23 17:15:38171 "renderer/shell_content_renderer_client.cc",
172 "renderer/shell_content_renderer_client.h",
[email protected]6b9028ab2014-07-23 17:15:38173 "renderer/shell_render_view_observer.cc",
174 "renderer/shell_render_view_observer.h",
[email protected]6b9028ab2014-07-23 17:15:38175 "renderer/test_runner/accessibility_controller.cc",
176 "renderer/test_runner/accessibility_controller.h",
benwells0c0d3f12015-05-25 01:03:17177 "renderer/test_runner/app_banner_client.cc",
178 "renderer/test_runner/app_banner_client.h",
[email protected]6b9028ab2014-07-23 17:15:38179 "renderer/test_runner/event_sender.cc",
180 "renderer/test_runner/event_sender.h",
181 "renderer/test_runner/gamepad_controller.cc",
182 "renderer/test_runner/gamepad_controller.h",
[email protected]0e043592014-07-28 19:47:04183 "renderer/test_runner/mock_color_chooser.cc",
184 "renderer/test_runner/mock_color_chooser.h",
[email protected]6b9028ab2014-07-23 17:15:38185 "renderer/test_runner/mock_constraints.cc",
186 "renderer/test_runner/mock_constraints.h",
mkwst41667ab2014-09-16 06:52:43187 "renderer/test_runner/mock_credential_manager_client.cc",
188 "renderer/test_runner/mock_credential_manager_client.h",
[email protected]6b9028ab2014-07-23 17:15:38189 "renderer/test_runner/mock_grammar_check.cc",
190 "renderer/test_runner/mock_grammar_check.h",
191 "renderer/test_runner/mock_screen_orientation_client.cc",
192 "renderer/test_runner/mock_screen_orientation_client.h",
[email protected]f656a652014-07-25 12:19:52193 "renderer/test_runner/mock_spell_check.cc",
194 "renderer/test_runner/mock_spell_check.h",
[email protected]6b9028ab2014-07-23 17:15:38195 "renderer/test_runner/mock_web_audio_device.cc",
196 "renderer/test_runner/mock_web_audio_device.h",
[email protected]85afb6c2014-07-29 02:43:36197 "renderer/test_runner/mock_web_media_stream_center.cc",
198 "renderer/test_runner/mock_web_media_stream_center.h",
[email protected]6b950c32014-07-28 14:35:43199 "renderer/test_runner/mock_web_midi_accessor.cc",
200 "renderer/test_runner/mock_web_midi_accessor.h",
[email protected]ca35ef02014-07-31 11:46:49201 "renderer/test_runner/mock_web_speech_recognizer.cc",
202 "renderer/test_runner/mock_web_speech_recognizer.h",
[email protected]6b9028ab2014-07-23 17:15:38203 "renderer/test_runner/mock_web_theme_engine.cc",
204 "renderer/test_runner/mock_web_theme_engine.h",
205 "renderer/test_runner/mock_web_user_media_client.cc",
206 "renderer/test_runner/mock_web_user_media_client.h",
207 "renderer/test_runner/mock_webrtc_data_channel_handler.cc",
208 "renderer/test_runner/mock_webrtc_data_channel_handler.h",
209 "renderer/test_runner/mock_webrtc_dtmf_sender_handler.cc",
210 "renderer/test_runner/mock_webrtc_dtmf_sender_handler.h",
211 "renderer/test_runner/mock_webrtc_peer_connection_handler.cc",
212 "renderer/test_runner/mock_webrtc_peer_connection_handler.h",
[email protected]b38c8f312014-08-01 23:21:37213 "renderer/test_runner/spell_check_client.cc",
214 "renderer/test_runner/spell_check_client.h",
[email protected]f5b1ad882014-08-05 16:30:41215 "renderer/test_runner/test_common.cc",
216 "renderer/test_runner/test_common.h",
[email protected]8ed8bf432014-08-11 19:47:55217 "renderer/test_runner/test_interfaces.cc",
218 "renderer/test_runner/test_interfaces.h",
abhishek.a21dd9554f2014-09-03 17:19:12219 "renderer/test_runner/test_plugin.cc",
220 "renderer/test_runner/test_plugin.h",
[email protected]6b9028ab2014-07-23 17:15:38221 "renderer/test_runner/test_runner.cc",
222 "renderer/test_runner/test_runner.h",
223 "renderer/test_runner/text_input_controller.cc",
224 "renderer/test_runner/text_input_controller.h",
225 "renderer/test_runner/web_ax_object_proxy.cc",
226 "renderer/test_runner/web_ax_object_proxy.h",
mlamouri007f9d72015-02-27 16:27:25227 "renderer/test_runner/web_content_settings.cc",
228 "renderer/test_runner/web_content_settings.h",
[email protected]6b9028ab2014-07-23 17:15:38229 "renderer/test_runner/web_frame_test_proxy.h",
abhishek.a21ab71acb2014-09-12 16:46:31230 "renderer/test_runner/web_task.cc",
231 "renderer/test_runner/web_task.h",
abhishek.a21ca9b5602014-09-19 07:33:33232 "renderer/test_runner/web_test_delegate.h",
abhishek.a21bdd07a82014-09-25 06:34:10233 "renderer/test_runner/web_test_interfaces.cc",
234 "renderer/test_runner/web_test_interfaces.h",
[email protected]6b9028ab2014-07-23 17:15:38235 "renderer/test_runner/web_test_proxy.cc",
236 "renderer/test_runner/web_test_proxy.h",
237 "renderer/test_runner/web_test_runner.h",
[email protected]6b9028ab2014-07-23 17:15:38238 ]
239
brettwd1c719a2015-02-19 23:17:04240 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
241 configs += [ "//build/config/compiler:no_size_t_to_int_warning" ]
242
[email protected]6b9028ab2014-07-23 17:15:38243 defines = [ "CONTENT_SHELL_VERSION=\"$content_shell_version\"" ]
244
Brett Wilson0380637c2014-09-19 21:24:40245 public_deps = [
246 # This exposes all public content APIs.
247 "//content/public/app:both",
248 "//content/public/browser",
249 "//content/public/common",
250 "//content/public/plugin",
251 "//content/public/renderer",
252 "//content/public/utility",
253 ]
[email protected]6b9028ab2014-07-23 17:15:38254 deps = [
255 ":resources",
256 "//base",
257 "//base:base_static",
258 "//base/allocator",
259 "//base/third_party/dynamic_annotations",
260 "//cc",
Robert Sesekabcd8102014-08-27 16:12:44261 "//components/crash/app",
dgozmanf7200152015-04-22 17:48:21262 "//components/devtools_discovery",
dgozman102fee92015-04-20 15:45:46263 "//components/devtools_http_handler",
chrishtr8a377e62015-06-01 19:20:08264 "//components/plugins/renderer",
hanxi149b92d2014-09-11 21:57:18265 "//components/web_cache/renderer",
[email protected]6b9028ab2014-07-23 17:15:38266 "//content:resources",
[email protected]a9ca8d52014-08-22 10:21:08267 "//content/app/resources",
[email protected]6586a2e32014-08-09 19:24:12268 "//content/app/strings",
[email protected]6b9028ab2014-07-23 17:15:38269 "//content/gpu",
[email protected]6b9028ab2014-07-23 17:15:38270 "//content/test:layouttest_support",
dpranke93211fc2015-04-29 04:59:42271 "//device/bluetooth",
ortunofd24faa2015-05-20 16:34:37272 "//device/bluetooth:mocks",
[email protected]6b9028ab2014-07-23 17:15:38273 "//gin",
274 "//gpu",
275 "//ipc",
276 "//media",
277 "//net",
278 "//net:net_resources",
279 "//skia",
pilgrim4af8c212014-09-05 17:30:15280 "//storage/browser",
ortunofd24faa2015-05-20 16:34:37281 "//testing/gmock",
282 "//testing/gtest",
[email protected]6b9028ab2014-07-23 17:15:38283 "//third_party/WebKit/public:blink",
erga3c614c92015-04-03 17:47:51284 "//third_party/WebKit/public:image_resources",
[email protected]4eebe74d2014-08-13 02:54:46285 "//third_party/WebKit/public:resources",
[email protected]0e043592014-07-28 19:47:04286 "//third_party/WebKit/public:test_support",
[email protected]4eebe74d2014-08-13 02:54:46287 "//third_party/icu",
[email protected]6b9028ab2014-07-23 17:15:38288 "//ui/base",
spang1c36fac2015-02-05 19:55:12289 "//ui/base/ime",
[email protected]6b9028ab2014-07-23 17:15:38290 "//ui/events:events_base",
291 "//ui/gfx",
292 "//ui/gfx/geometry",
293 "//ui/gfx/ipc",
294 "//ui/gl",
295 "//url",
296 "//v8",
scottmg7afc4092014-12-03 19:22:42297
[email protected]6b9028ab2014-07-23 17:15:38298 #'copy_test_netscape_plugin', TODO(GYP)
[email protected]6b9028ab2014-07-23 17:15:38299 ]
jamesr50081742014-09-09 07:52:22300 if (enable_plugins) {
301 deps += [ "//content/ppapi_plugin" ]
302 }
[email protected]6b9028ab2014-07-23 17:15:38303
304 if (is_win) {
[email protected]6b9028ab2014-07-23 17:15:38305 #'LinkIncremental': '<(msvs_large_module_debug_link_mode)', TODO(GYP)
vchigrin61944ae2015-01-30 23:51:32306 sources += [
307 "common/v8_breakpad_support_win.cc",
308 "common/v8_breakpad_support_win.h",
309 ]
[email protected]6b9028ab2014-07-23 17:15:38310 }
311
312 if (is_linux) {
313 configs += [ "//build/config/linux:fontconfig" ]
314 }
315
316 if (use_x11) {
[email protected]c7990dbf2014-07-23 22:35:10317 # Some tests rely on this tool at runtime. Note: it might be better if
318 # the tests that needed it had this as a dep instead of adding it here.
scottmg7afc4092014-12-03 19:22:42319 datadeps = [
320 "//tools/xdisplaycheck",
321 ]
dnicoara78a734702014-11-04 19:54:38322
323 deps += [ "//ui/events/devices" ]
[email protected]6b9028ab2014-07-23 17:15:38324 }
325
326 if (is_android) {
James Robinson060f2e32014-09-10 22:31:37327 deps += [ "//content/shell/android:content_shell_jni_headers" ]
cjhopmancd7694af2014-09-08 00:00:04328 #deps -= [ "copy_test_netscape_plugin" ] TODO(GYP)
[email protected]6b9028ab2014-07-23 17:15:38329 }
330
torne1b1c9782015-03-30 20:49:00331 if (is_posix && !is_mac) {
Robert Sesekabcd8102014-08-27 16:12:44332 deps += [ "//components/crash/browser" ]
[email protected]6b9028ab2014-07-23 17:15:38333 }
334
335 if (use_aura) {
336 deps += [
337 "//ui/aura",
338 "//ui/aura:test_support",
339 "//ui/events",
340 "//ui/strings",
341 "//ui/wm",
342 ]
343
344 if (toolkit_views) {
345 sources += [ "browser/shell_views.cc" ]
346 deps += [
347 "//ui/resources",
348 "//ui/views/controls/webview",
349 "//ui/views",
350 "//ui/views:test_support",
351 ]
352 } else {
353 sources += [ "browser/shell_aura.cc" ]
354 }
James Robinson060f2e32014-09-10 22:31:37355 } else {
356 sources -= [
357 "browser/shell_platform_data_aura.cc",
358 "browser/shell_platform_data_aura.h",
359 ]
[email protected]6b9028ab2014-07-23 17:15:38360 }
361
362 # The test plugin relies on X11.
363 if (is_linux && !use_x11) {
364 #deps -= [ 'copy_test_netscape_plugin' ] TODO(GYP)
365 }
366
367 if (is_chromeos) {
368 deps += [
mukai6ba73552014-10-09 19:05:17369 "//chromeos",
[email protected]6b9028ab2014-07-23 17:15:38370 "//ui/wm:test_support",
[email protected]6b9028ab2014-07-23 17:15:38371 ]
372 }
373
374 if (is_linux) {
375 deps += [ "//third_party/freetype2" ]
376 }
377
378 if (!enable_plugins) {
379 sources -= [
380 "browser/shell_plugin_service_filter.cc",
381 "browser/shell_plugin_service_filter.h",
382 ]
383 }
384}
385
386grit("content_shell_resources_grit") {
brettw9af42622014-09-06 21:21:02387 visibility = [ ":*" ]
[email protected]6b9028ab2014-07-23 17:15:38388 source = "shell_resources.grd"
389 outputs = [
390 "grit/shell_resources.h",
391 "shell_resources.pak",
392 "shell_resources.rc",
393 ]
394}
395
396copy("copy_shell_resources") {
scottmg7afc4092014-12-03 19:22:42397 sources = [
398 "$target_gen_dir/shell_resources.pak",
399 ]
scottmg34fb7e52014-12-03 23:27:24400 outputs = [
401 "$root_out_dir/shell_resources.pak",
402 ]
[email protected]6b9028ab2014-07-23 17:15:38403
scottmg7afc4092014-12-03 19:22:42404 public_deps = [
405 ":content_shell_resources_grit",
406 ]
[email protected]6b9028ab2014-07-23 17:15:38407}
408
409# Font copies.
410if (!is_mac) {
411 copy("copy_ahem") {
brettw9af42622014-09-06 21:21:02412 visibility = [ ":*" ]
scottmg7afc4092014-12-03 19:22:42413 sources = [
414 "renderer/test_runner/resources/fonts/AHEM____.TTF",
415 ]
scottmg34fb7e52014-12-03 23:27:24416 outputs = [
417 "$root_out_dir/AHEM____.TTF",
418 ]
[email protected]6b9028ab2014-07-23 17:15:38419 }
420}
421if (use_x11) {
422 copy("copy_x11_fonts") {
brettw9af42622014-09-06 21:21:02423 visibility = [ ":*" ]
[email protected]6b9028ab2014-07-23 17:15:38424 sources = [
[email protected]6b9028ab2014-07-23 17:15:38425 "//third_party/gardiner_mod/GardinerModBug.ttf",
426 "//third_party/gardiner_mod/GardinerModCat.ttf",
scottmg7c7296f42015-02-28 02:23:09427 "renderer/test_runner/resources/fonts/fonts.conf",
[email protected]6b9028ab2014-07-23 17:15:38428 ]
scottmg34fb7e52014-12-03 23:27:24429 outputs = [
430 "$root_out_dir/{{source_file_part}}",
431 ]
[email protected]6b9028ab2014-07-23 17:15:38432 }
433}
434if (is_android) {
435 copy("copy_android_fonts") {
brettw9af42622014-09-06 21:21:02436 visibility = [ ":*" ]
[email protected]6b9028ab2014-07-23 17:15:38437 sources = [
[email protected]6b9028ab2014-07-23 17:15:38438 "renderer/test_runner/resources/fonts/android_fallback_fonts.xml",
scottmg7c7296f42015-02-28 02:23:09439 "renderer/test_runner/resources/fonts/android_main_fonts.xml",
[email protected]6b9028ab2014-07-23 17:15:38440 ]
scottmg34fb7e52014-12-03 23:27:24441 outputs = [
442 "$root_out_dir/{{source_file_part}}",
443 ]
[email protected]6b9028ab2014-07-23 17:15:38444 }
445}
446
447group("resources") {
Brett Wilsone53895272014-09-23 23:41:46448 public_deps = [
[email protected]6b9028ab2014-07-23 17:15:38449 ":copy_shell_resources",
450 ]
Brett Wilsone53895272014-09-23 23:41:46451 deps = []
[email protected]6b9028ab2014-07-23 17:15:38452
453 if (is_mac) {
454 # TODO(GYP) Mac bundle resources.
455 #'all_dependent_settings': {
456 # 'mac_bundle_resources': [
457 # 'shell/renderer/test_runner/resources/fonts/AHEM____.TTF',
458 # 'shell/renderer/test_runner/resources/fonts/ChromiumAATTest.ttf',
459 # '<(SHARED_INTERMEDIATE_DIR)/webkit/missingImage.png',
460 # '<(SHARED_INTERMEDIATE_DIR)/webkit/textAreaResizeCorner.png',
461 # ],
462 #},
463 } else {
464 deps += [ ":copy_ahem" ]
465 }
466
467 if (use_x11) {
468 deps += [ ":copy_x11_fonts" ]
469 }
470 if (is_android) {
471 deps += [ ":copy_android_fonts" ]
472 }
473}
474
475repack("pak") {
476 sources = [
erga3c614c92015-04-03 17:47:51477 "$root_gen_dir/blink/public/resources/blink_image_resources_100_percent.pak",
478 "$root_gen_dir/blink/public/resources/blink_resources.pak",
[email protected]a9ca8d52014-08-22 10:21:08479 "$root_gen_dir/content/app/resources/content_resources_100_percent.pak",
[email protected]6586a2e32014-08-09 19:24:12480 "$root_gen_dir/content/app/strings/content_strings_en-US.pak",
[email protected]6b9028ab2014-07-23 17:15:38481 "$root_gen_dir/content/browser/tracing/tracing_resources.pak",
[email protected]6586a2e32014-08-09 19:24:12482 "$root_gen_dir/content/content_resources.pak",
[email protected]6b9028ab2014-07-23 17:15:38483 "$root_gen_dir/content/shell/shell_resources.pak",
484 "$root_gen_dir/net/net_resources.pak",
485 "$root_gen_dir/ui/resources/ui_resources_100_percent.pak",
486 "$root_gen_dir/ui/resources/webui_resources.pak",
487 "$root_gen_dir/ui/strings/app_locale_settings_en-US.pak",
488 "$root_gen_dir/ui/strings/ui_strings_en-US.pak",
[email protected]6b9028ab2014-07-23 17:15:38489 ]
490
491 deps = [
492 ":resources",
493 "//content:resources",
[email protected]a9ca8d52014-08-22 10:21:08494 "//content/app/resources",
[email protected]6586a2e32014-08-09 19:24:12495 "//content/app/strings",
[email protected]6b9028ab2014-07-23 17:15:38496 "//content/browser/tracing:resources",
497 "//net:net_resources",
erga3c614c92015-04-03 17:47:51498 "//third_party/WebKit/public:image_resources",
[email protected]4eebe74d2014-08-13 02:54:46499 "//third_party/WebKit/public:resources",
[email protected]6b9028ab2014-07-23 17:15:38500 "//ui/resources",
501 "//ui/strings",
[email protected]6b9028ab2014-07-23 17:15:38502 ]
503
vivek.vg77816a12014-12-18 14:28:20504 sources += [ "$root_gen_dir/blink/devtools_resources.pak" ]
cjhopman2fd48fd2014-09-24 00:52:56505 deps += [ "//content/browser/devtools:resources" ]
506 output = "$root_out_dir/content_shell.pak"
[email protected]6b9028ab2014-07-23 17:15:38507}
508
James Robinson060f2e32014-09-10 22:31:37509# TODO(GYP): Figure out what this should be on android
dpranke380390f2014-11-21 06:08:53510# and make linking this work on the Mac.
brettw4897a612015-03-02 23:13:15511if (!is_android && !is_mac) {
scottmg7afc4092014-12-03 19:22:42512 executable("content_shell") {
513 testonly = true
James Robinson060f2e32014-09-10 22:31:37514
scottmg7afc4092014-12-03 19:22:42515 # TODO(GYP) mac resource bundle stuff for this target.
516 # TODO(GYP) Windows content shell settings:
517 # - Manifest.
518 # - RC file.
519 # - 'LinkIncremental': '<(msvs_large_module_debug_link_mode)',
520 sources = [
scottmg7afc4092014-12-03 19:22:42521 "app/shell_main.cc",
522 ]
[email protected]6b9028ab2014-07-23 17:15:38523
scottmg7afc4092014-12-03 19:22:42524 deps = [
525 ":content_shell_lib",
526 ":pak",
527 "//base/allocator",
528 ]
[email protected]6b9028ab2014-07-23 17:15:38529
scottmg7afc4092014-12-03 19:22:42530 if (is_win) {
531 deps += [ "//sandbox" ]
532 if (!is_asan) {
533 configs -= [ "//build/config/win:console" ]
534 configs += [ "//build/config/win:windowed" ]
535 }
536 }
537
538 if (is_mac) {
539 # TODO(GYP) lots of stuff from GYP file here.
540 }
541
torne1b1c9782015-03-30 20:49:00542 if (is_android) {
scottmg7afc4092014-12-03 19:22:42543 # Some tests rely on this tool. It might be nicer if these tests relied on
544 # image diff rather than having content shell depend on it.
545 datadeps = [
546 "//tools/imagediff($host_toolchain)",
547 ]
[email protected]6b9028ab2014-07-23 17:15:38548 }
549 }
brettw6aa189562015-02-02 05:34:22550} else {
551 group("content_shell") {
dpranked4063e42015-05-01 01:23:42552 testonly = true
553 deps = [
554 ":content_shell_lib",
555 ]
brettw6aa189562015-02-02 05:34:22556 }
James Robinson060f2e32014-09-10 22:31:37557}
tfarina10ae51f62015-05-13 03:35:57558
559if (is_mac || is_win) {
560 # GYP version: content/content_shell_and_tests.gyp:layout_test_helper
561 executable("layout_test_helper") {
562 sources = [
563 "renderer/test_runner/helper/layout_test_helper_mac.mm",
564 "renderer/test_runner/helper/layout_test_helper_win.cc",
565 ]
566
567 if (is_mac) {
568 libs = [ "AppKit.framework" ]
569 }
570 }
571}
tfarina795e01a2015-05-15 19:29:57572
573if (is_win) {
574 # GYP version: content/content_shell_and_tests.gyp:content_shell_crash_service
575 executable("crash_service") {
576 sources = [
577 "tools/content_shell_crash_service.cc",
578 ]
579
580 deps = [
581 "//base",
582 "//components/crash/tools:crash_service",
583 ]
584
585 configs -= [ "//build/config/win:console" ]
586 configs += [ "//build/config/win:windowed" ]
587 }
588}