blob: 8c5c61a70908e8ea975119dbaaca9cd28207c83d [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")
ortunof78c8412016-03-31 18:59:5911import("//mojo/public/tools/bindings/mojom.gni")
[email protected]6b9028ab2014-07-23 17:15:3812import("//tools/grit/repack.gni")
cjhopmancd7694af2014-09-08 00:00:0413import("//tools/grit/grit_rule.gni")
[email protected]6b9028ab2014-07-23 17:15:3814if (is_android) {
15 import("//build/config/android/config.gni")
16}
17
18declare_args() {
19 content_shell_product_name = "Content Shell"
esprehnb3789092015-11-24 19:46:0320 content_shell_version = "99.77.34.5"
[email protected]6b9028ab2014-07-23 17:15:3821}
22
thakisff2eab9c2015-11-13 00:29:5823config("content_shell_lib_warnings") {
24 if (is_clang) {
25 # TODO(thakis): Remove this once http://crbug.com/383820 is figured out
26 cflags = [ "-Wno-nonnull" ]
27 }
28}
29
[email protected]6b9028ab2014-07-23 17:15:3830static_library("content_shell_lib") {
Brett Wilson8f80ad0b2014-09-08 19:50:2431 testonly = true
[email protected]6b9028ab2014-07-23 17:15:3832 sources = [
dprankec6beb8392015-10-30 23:44:2133 "android/shell_descriptors.h",
[email protected]6b9028ab2014-07-23 17:15:3834 "android/shell_jni_registrar.cc",
35 "android/shell_jni_registrar.h",
36 "android/shell_manager.cc",
37 "android/shell_manager.h",
lukasza88e4b0b42016-02-25 21:42:1038 "app/blink_test_platform_support.h",
39 "app/blink_test_platform_support_android.cc",
40 "app/blink_test_platform_support_linux.cc",
41 "app/blink_test_platform_support_mac.mm",
42 "app/blink_test_platform_support_win.cc",
[email protected]6b9028ab2014-07-23 17:15:3843 "app/paths_mac.h",
44 "app/paths_mac.mm",
rseseka0a7a042014-09-18 23:59:2045 "app/shell_crash_reporter_client.cc",
46 "app/shell_crash_reporter_client.h",
[email protected]6b9028ab2014-07-23 17:15:3847 "app/shell_main_delegate.cc",
48 "app/shell_main_delegate.h",
49 "app/shell_main_delegate_mac.h",
50 "app/shell_main_delegate_mac.mm",
jochen5ce1af92016-02-17 20:39:4551 "browser/layout_test/blink_test_controller.cc",
52 "browser/layout_test/blink_test_controller.h",
mkwstd6805d0d2014-10-16 14:44:3753 "browser/layout_test/layout_test_android.cc",
54 "browser/layout_test/layout_test_android.h",
ortunofd24faa2015-05-20 16:34:3755 "browser/layout_test/layout_test_bluetooth_adapter_provider.cc",
56 "browser/layout_test/layout_test_bluetooth_adapter_provider.h",
jyasskin8057c002015-09-10 19:09:5357 "browser/layout_test/layout_test_bluetooth_chooser_factory.cc",
58 "browser/layout_test/layout_test_bluetooth_chooser_factory.h",
ortunof78c8412016-03-31 18:59:5959 "browser/layout_test/layout_test_bluetooth_fake_adapter_setter_impl.cc",
60 "browser/layout_test/layout_test_bluetooth_fake_adapter_setter_impl.h",
mkwstd993d06a2014-10-10 11:44:3861 "browser/layout_test/layout_test_browser_context.cc",
62 "browser/layout_test/layout_test_browser_context.h",
mkwst88e23182014-10-16 12:08:5863 "browser/layout_test/layout_test_browser_main.cc",
64 "browser/layout_test/layout_test_browser_main.h",
mkwst36b11b6f2014-10-15 16:18:5665 "browser/layout_test/layout_test_browser_main_parts.cc",
66 "browser/layout_test/layout_test_browser_main_parts.h",
petercd7abb42014-10-17 13:34:0167 "browser/layout_test/layout_test_content_browser_client.cc",
68 "browser/layout_test/layout_test_content_browser_client.h",
mkwst30d20d52014-10-09 13:33:1469 "browser/layout_test/layout_test_devtools_frontend.cc",
70 "browser/layout_test/layout_test_devtools_frontend.h",
mkwst94388f792014-10-16 07:36:5271 "browser/layout_test/layout_test_download_manager_delegate.cc",
72 "browser/layout_test/layout_test_download_manager_delegate.h",
mkwst6efe7f2e62014-10-08 15:09:0173 "browser/layout_test/layout_test_javascript_dialog_manager.cc",
74 "browser/layout_test/layout_test_javascript_dialog_manager.h",
Peter Beverlooe8f2f9d2014-10-20 16:47:4975 "browser/layout_test/layout_test_message_filter.cc",
76 "browser/layout_test/layout_test_message_filter.h",
mekc9182202015-03-03 17:56:0777 "browser/layout_test/layout_test_navigator_connect_service_factory.cc",
78 "browser/layout_test/layout_test_navigator_connect_service_factory.h",
petercd7abb42014-10-17 13:34:0179 "browser/layout_test/layout_test_notification_manager.cc",
80 "browser/layout_test/layout_test_notification_manager.h",
mlamouri4e372022015-03-29 14:51:0681 "browser/layout_test/layout_test_permission_manager.cc",
82 "browser/layout_test/layout_test_permission_manager.h",
mvanouwerkerkde895c9c2014-12-06 12:17:3283 "browser/layout_test/layout_test_push_messaging_service.cc",
84 "browser/layout_test/layout_test_push_messaging_service.h",
mkwst002d02902014-10-09 10:17:0085 "browser/layout_test/layout_test_resource_dispatcher_host_delegate.cc",
86 "browser/layout_test/layout_test_resource_dispatcher_host_delegate.h",
mkwst94388f792014-10-16 07:36:5287 "browser/layout_test/layout_test_url_request_context_getter.cc",
88 "browser/layout_test/layout_test_url_request_context_getter.h",
jochen5ce1af92016-02-17 20:39:4589 "browser/layout_test/notify_done_forwarder.cc",
90 "browser/layout_test/notify_done_forwarder.h",
jochene9ba6dd2016-02-23 17:20:4991 "browser/layout_test/test_info_extractor.cc",
92 "browser/layout_test/test_info_extractor.h",
peter11d5f562014-10-23 23:12:2593 "browser/shell.cc",
94 "browser/shell.h",
95 "browser/shell_access_token_store.cc",
96 "browser/shell_access_token_store.h",
[email protected]6b9028ab2014-07-23 17:15:3897 "browser/shell_android.cc",
98 "browser/shell_application_mac.h",
99 "browser/shell_application_mac.mm",
100 "browser/shell_browser_context.cc",
101 "browser/shell_browser_context.h",
102 "browser/shell_browser_main.cc",
103 "browser/shell_browser_main.h",
104 "browser/shell_browser_main_parts.cc",
105 "browser/shell_browser_main_parts.h",
106 "browser/shell_browser_main_parts_mac.mm",
[email protected]6b9028ab2014-07-23 17:15:38107 "browser/shell_content_browser_client.cc",
108 "browser/shell_content_browser_client.h",
[email protected]6b9028ab2014-07-23 17:15:38109 "browser/shell_devtools_frontend.cc",
110 "browser/shell_devtools_frontend.h",
satorux7fa9d302015-02-16 00:44:52111 "browser/shell_devtools_manager_delegate.cc",
112 "browser/shell_devtools_manager_delegate.h",
[email protected]6b9028ab2014-07-23 17:15:38113 "browser/shell_download_manager_delegate.cc",
114 "browser/shell_download_manager_delegate.h",
[email protected]6b9028ab2014-07-23 17:15:38115 "browser/shell_javascript_dialog.h",
116 "browser/shell_javascript_dialog_mac.mm",
117 "browser/shell_javascript_dialog_manager.cc",
118 "browser/shell_javascript_dialog_manager.h",
119 "browser/shell_javascript_dialog_win.cc",
[email protected]6b9028ab2014-07-23 17:15:38120 "browser/shell_login_dialog.cc",
121 "browser/shell_login_dialog.h",
122 "browser/shell_login_dialog_mac.mm",
123 "browser/shell_mac.mm",
satorux7fa9d302015-02-16 00:44:52124 "browser/shell_mojo_test_utils_android.cc",
125 "browser/shell_mojo_test_utils_android.h",
[email protected]6b9028ab2014-07-23 17:15:38126 "browser/shell_net_log.cc",
127 "browser/shell_net_log.h",
128 "browser/shell_network_delegate.cc",
129 "browser/shell_network_delegate.h",
mlamouri4e372022015-03-29 14:51:06130 "browser/shell_permission_manager.cc",
131 "browser/shell_permission_manager.h",
[email protected]6b9028ab2014-07-23 17:15:38132 "browser/shell_platform_data_aura.cc",
133 "browser/shell_platform_data_aura.h",
134 "browser/shell_plugin_service_filter.cc",
135 "browser/shell_plugin_service_filter.h",
136 "browser/shell_quota_permission_context.cc",
137 "browser/shell_quota_permission_context.h",
138 "browser/shell_resource_dispatcher_host_delegate.cc",
139 "browser/shell_resource_dispatcher_host_delegate.h",
140 "browser/shell_speech_recognition_manager_delegate.cc",
141 "browser/shell_speech_recognition_manager_delegate.h",
142 "browser/shell_url_request_context_getter.cc",
143 "browser/shell_url_request_context_getter.h",
satorux7fa9d302015-02-16 00:44:52144 "browser/shell_web_contents_view_delegate.h",
[email protected]6b9028ab2014-07-23 17:15:38145 "browser/shell_web_contents_view_delegate_android.cc",
146 "browser/shell_web_contents_view_delegate_creator.h",
[email protected]6b9028ab2014-07-23 17:15:38147 "browser/shell_web_contents_view_delegate_mac.mm",
148 "browser/shell_web_contents_view_delegate_win.cc",
lukasza80f7f602016-03-22 23:13:19149 "common/layout_test/layout_test_content_client.cc",
150 "common/layout_test/layout_test_content_client.h",
petere04203592014-10-27 17:57:35151 "common/layout_test/layout_test_messages.cc",
152 "common/layout_test/layout_test_messages.h",
lukasza381b0492016-03-10 16:48:43153 "common/layout_test/layout_test_switches.cc",
154 "common/layout_test/layout_test_switches.h",
[email protected]6b9028ab2014-07-23 17:15:38155 "common/leak_detection_result.h",
156 "common/shell_content_client.cc",
157 "common/shell_content_client.h",
158 "common/shell_messages.cc",
159 "common/shell_messages.h",
160 "common/shell_switches.cc",
161 "common/shell_switches.h",
162 "common/shell_test_configuration.cc",
163 "common/shell_test_configuration.h",
tfarina685c39802015-05-04 22:11:22164 "renderer/layout_test/blink_test_helpers.cc",
165 "renderer/layout_test/blink_test_helpers.h",
tfarina8e08285f2015-05-02 03:17:39166 "renderer/layout_test/blink_test_runner.cc",
167 "renderer/layout_test/blink_test_runner.h",
mkwst02ec0d62014-10-07 22:07:29168 "renderer/layout_test/layout_test_content_renderer_client.cc",
169 "renderer/layout_test/layout_test_content_renderer_client.h",
mkwst3e72c1f2014-10-08 05:02:36170 "renderer/layout_test/layout_test_render_frame_observer.cc",
171 "renderer/layout_test/layout_test_render_frame_observer.h",
mkwst99069fc2014-10-08 06:13:28172 "renderer/layout_test/layout_test_render_process_observer.cc",
173 "renderer/layout_test/layout_test_render_process_observer.h",
mkwst04b72d12014-10-08 15:52:55174 "renderer/layout_test/leak_detector.cc",
175 "renderer/layout_test/leak_detector.h",
jochen51265132015-05-28 07:33:45176 "renderer/layout_test/test_media_stream_renderer_factory.cc",
177 "renderer/layout_test/test_media_stream_renderer_factory.h",
178 "renderer/layout_test/test_video_frame_provider.cc",
179 "renderer/layout_test/test_video_frame_provider.h",
[email protected]6b9028ab2014-07-23 17:15:38180 "renderer/shell_content_renderer_client.cc",
181 "renderer/shell_content_renderer_client.h",
[email protected]6b9028ab2014-07-23 17:15:38182 "renderer/shell_render_view_observer.cc",
183 "renderer/shell_render_view_observer.h",
rockotb814a582015-06-05 00:30:52184 "utility/shell_content_utility_client.cc",
185 "utility/shell_content_utility_client.h",
[email protected]6b9028ab2014-07-23 17:15:38186 ]
187
brettwbc8b2a22015-07-28 18:24:42188 configs += [
thakisff2eab9c2015-11-13 00:29:58189 ":content_shell_lib_warnings",
brettwbc8b2a22015-07-28 18:24:42190 "//build/config:precompiled_headers",
191
192 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
193 "//build/config/compiler:no_size_t_to_int_warning",
kozyatinskiy6adbc802016-01-28 00:16:16194
195 "//third_party/WebKit/public:debug_devtools",
brettwbc8b2a22015-07-28 18:24:42196 ]
brettwd1c719a2015-02-19 23:17:04197
[email protected]6b9028ab2014-07-23 17:15:38198 defines = [ "CONTENT_SHELL_VERSION=\"$content_shell_version\"" ]
199
Brett Wilson0380637c2014-09-19 21:24:40200 public_deps = [
201 # This exposes all public content APIs.
202 "//content/public/app:both",
203 "//content/public/browser",
204 "//content/public/common",
205 "//content/public/plugin",
206 "//content/public/renderer",
207 "//content/public/utility",
208 ]
[email protected]6b9028ab2014-07-23 17:15:38209 deps = [
ortunof78c8412016-03-31 18:59:59210 ":mojo_bindings",
[email protected]6b9028ab2014-07-23 17:15:38211 ":resources",
212 "//base",
213 "//base:base_static",
[email protected]6b9028ab2014-07-23 17:15:38214 "//base/third_party/dynamic_annotations",
215 "//cc",
scottmgcfa5b01b2015-11-30 23:13:46216 "//components/crash/content/app:app_breakpad_mac_win_to_be_deleted",
dgozmanf7200152015-04-22 17:48:21217 "//components/devtools_discovery",
dgozman102fee92015-04-20 15:45:46218 "//components/devtools_http_handler",
chrishtr8a377e62015-06-01 19:20:08219 "//components/plugins/renderer",
jochen73e711c2015-06-03 10:01:46220 "//components/test_runner:test_runner",
rsleevi24f64dc22015-08-07 21:39:21221 "//components/url_formatter",
hanxi149b92d2014-09-11 21:57:18222 "//components/web_cache/renderer",
[email protected]6b9028ab2014-07-23 17:15:38223 "//content:resources",
[email protected]a9ca8d52014-08-22 10:21:08224 "//content/app/resources",
[email protected]6586a2e32014-08-09 19:24:12225 "//content/app/strings",
[email protected]6b9028ab2014-07-23 17:15:38226 "//content/gpu",
[email protected]6b9028ab2014-07-23 17:15:38227 "//content/test:layouttest_support",
brettwb78fc9e2016-03-25 21:02:51228 "//content/test:test_support",
dpranke93211fc2015-04-29 04:59:42229 "//device/bluetooth",
ortunofd24faa2015-05-20 16:34:37230 "//device/bluetooth:mocks",
[email protected]6b9028ab2014-07-23 17:15:38231 "//gin",
232 "//gpu",
233 "//ipc",
234 "//media",
brettwb78fc9e2016-03-25 21:02:51235 "//media/mojo/services:application_factory",
[email protected]6b9028ab2014-07-23 17:15:38236 "//net",
237 "//net:net_resources",
238 "//skia",
pilgrim4af8c212014-09-05 17:30:15239 "//storage/browser",
ortunofd24faa2015-05-20 16:34:37240 "//testing/gmock",
241 "//testing/gtest",
[email protected]6b9028ab2014-07-23 17:15:38242 "//third_party/WebKit/public:blink",
erga3c614c92015-04-03 17:47:51243 "//third_party/WebKit/public:image_resources",
[email protected]4eebe74d2014-08-13 02:54:46244 "//third_party/WebKit/public:resources",
[email protected]0e043592014-07-28 19:47:04245 "//third_party/WebKit/public:test_support",
[email protected]4eebe74d2014-08-13 02:54:46246 "//third_party/icu",
[email protected]6b9028ab2014-07-23 17:15:38247 "//ui/base",
spang1c36fac2015-02-05 19:55:12248 "//ui/base/ime",
[email protected]6b9028ab2014-07-23 17:15:38249 "//ui/events:events_base",
250 "//ui/gfx",
251 "//ui/gfx/geometry",
252 "//ui/gfx/ipc",
markdittmer99d77bf2016-03-31 19:03:24253 "//ui/gfx/ipc/skia",
[email protected]6b9028ab2014-07-23 17:15:38254 "//ui/gl",
255 "//url",
256 "//v8",
scottmg7afc4092014-12-03 19:22:42257
[email protected]6b9028ab2014-07-23 17:15:38258 #'copy_test_netscape_plugin', TODO(GYP)
[email protected]6b9028ab2014-07-23 17:15:38259 ]
jamesr50081742014-09-09 07:52:22260 if (enable_plugins) {
dcheng0d93c1a2015-12-03 02:46:41261 deps += [
262 "//content/ppapi_plugin",
dchengc70b36e2016-03-02 02:36:10263 "//ppapi:blink_deprecated_test_plugin",
dcheng0d93c1a2015-12-03 02:46:41264 "//ppapi:blink_test_plugin",
brettwb78fc9e2016-03-25 21:02:51265 "//ppapi/shared_impl",
dcheng0d93c1a2015-12-03 02:46:41266 ]
jamesr50081742014-09-09 07:52:22267 }
xhwangbe720032016-02-19 18:45:31268 if (mojo_media_host == "browser") {
xhwang755165d2016-02-18 17:29:58269 deps += [ "//media/mojo/services:application_factory" ]
alokpaa2fdfb72016-02-03 22:55:54270 }
[email protected]6b9028ab2014-07-23 17:15:38271
272 if (is_win) {
[email protected]6b9028ab2014-07-23 17:15:38273 #'LinkIncremental': '<(msvs_large_module_debug_link_mode)', TODO(GYP)
vchigrin61944ae2015-01-30 23:51:32274 sources += [
275 "common/v8_breakpad_support_win.cc",
276 "common/v8_breakpad_support_win.h",
277 ]
[email protected]6b9028ab2014-07-23 17:15:38278 }
279
280 if (is_linux) {
brettwb78fc9e2016-03-25 21:02:51281 deps += [
282 "//build/linux:fontconfig",
283 "//ui/gfx:test_support",
284 ]
[email protected]6b9028ab2014-07-23 17:15:38285 }
286
287 if (use_x11) {
[email protected]c7990dbf2014-07-23 22:35:10288 # Some tests rely on this tool at runtime. Note: it might be better if
289 # the tests that needed it had this as a dep instead of adding it here.
sadrul1f7fa9f2015-10-06 17:14:57290 data_deps = [
291 "//tools/xdisplaycheck",
292 ]
dnicoara78a734702014-11-04 19:54:38293
294 deps += [ "//ui/events/devices" ]
[email protected]6b9028ab2014-07-23 17:15:38295 }
296
297 if (is_android) {
James Robinson060f2e32014-09-10 22:31:37298 deps += [ "//content/shell/android:content_shell_jni_headers" ]
cjhopmancd7694af2014-09-08 00:00:04299 #deps -= [ "copy_test_netscape_plugin" ] TODO(GYP)
[email protected]6b9028ab2014-07-23 17:15:38300 }
301
torne1b1c9782015-03-30 20:49:00302 if (is_posix && !is_mac) {
brettwb78fc9e2016-03-25 21:02:51303 deps += [
304 "//components/crash/content/app",
305 "//components/crash/content/browser",
306 ]
[email protected]6b9028ab2014-07-23 17:15:38307 }
308
309 if (use_aura) {
310 deps += [
311 "//ui/aura",
312 "//ui/aura:test_support",
313 "//ui/events",
314 "//ui/strings",
315 "//ui/wm",
316 ]
317
318 if (toolkit_views) {
319 sources += [ "browser/shell_views.cc" ]
320 deps += [
321 "//ui/resources",
[email protected]6b9028ab2014-07-23 17:15:38322 "//ui/views",
323 "//ui/views:test_support",
agrieved7a71c882015-11-20 19:53:28324 "//ui/views/controls/webview",
brettwb78fc9e2016-03-25 21:02:51325 "//ui/wm:test_support",
[email protected]6b9028ab2014-07-23 17:15:38326 ]
327 } else {
328 sources += [ "browser/shell_aura.cc" ]
329 }
James Robinson060f2e32014-09-10 22:31:37330 } else {
331 sources -= [
332 "browser/shell_platform_data_aura.cc",
333 "browser/shell_platform_data_aura.h",
334 ]
[email protected]6b9028ab2014-07-23 17:15:38335 }
336
337 # The test plugin relies on X11.
338 if (is_linux && !use_x11) {
339 #deps -= [ 'copy_test_netscape_plugin' ] TODO(GYP)
340 }
341
342 if (is_chromeos) {
343 deps += [
mukai6ba73552014-10-09 19:05:17344 "//chromeos",
[email protected]6b9028ab2014-07-23 17:15:38345 "//ui/wm:test_support",
[email protected]6b9028ab2014-07-23 17:15:38346 ]
347 }
348
bcf0ddf78a2016-02-02 18:52:21349 if (is_linux) {
[email protected]6b9028ab2014-07-23 17:15:38350 deps += [ "//third_party/freetype2" ]
351 }
352
353 if (!enable_plugins) {
354 sources -= [
355 "browser/shell_plugin_service_filter.cc",
356 "browser/shell_plugin_service_filter.h",
357 ]
358 }
359}
360
361grit("content_shell_resources_grit") {
brettwb78fc9e2016-03-25 21:02:51362 # External code should depend on ":resources" instead.
brettw9af42622014-09-06 21:21:02363 visibility = [ ":*" ]
[email protected]6b9028ab2014-07-23 17:15:38364 source = "shell_resources.grd"
365 outputs = [
366 "grit/shell_resources.h",
367 "shell_resources.pak",
[email protected]6b9028ab2014-07-23 17:15:38368 ]
369}
370
371copy("copy_shell_resources") {
scottmg7afc4092014-12-03 19:22:42372 sources = [
373 "$target_gen_dir/shell_resources.pak",
374 ]
scottmg34fb7e52014-12-03 23:27:24375 outputs = [
376 "$root_out_dir/shell_resources.pak",
377 ]
[email protected]6b9028ab2014-07-23 17:15:38378
scottmg7afc4092014-12-03 19:22:42379 public_deps = [
380 ":content_shell_resources_grit",
381 ]
[email protected]6b9028ab2014-07-23 17:15:38382}
383
[email protected]6b9028ab2014-07-23 17:15:38384group("resources") {
Brett Wilsone53895272014-09-23 23:41:46385 public_deps = [
[email protected]6b9028ab2014-07-23 17:15:38386 ":copy_shell_resources",
387 ]
jochen73e711c2015-06-03 10:01:46388 deps = [
389 "//components/test_runner:resources",
390 ]
[email protected]6b9028ab2014-07-23 17:15:38391}
392
393repack("pak") {
394 sources = [
erga3c614c92015-04-03 17:47:51395 "$root_gen_dir/blink/public/resources/blink_image_resources_100_percent.pak",
396 "$root_gen_dir/blink/public/resources/blink_resources.pak",
[email protected]a9ca8d52014-08-22 10:21:08397 "$root_gen_dir/content/app/resources/content_resources_100_percent.pak",
[email protected]6586a2e32014-08-09 19:24:12398 "$root_gen_dir/content/app/strings/content_strings_en-US.pak",
[email protected]6b9028ab2014-07-23 17:15:38399 "$root_gen_dir/content/browser/tracing/tracing_resources.pak",
[email protected]6586a2e32014-08-09 19:24:12400 "$root_gen_dir/content/content_resources.pak",
[email protected]6b9028ab2014-07-23 17:15:38401 "$root_gen_dir/content/shell/shell_resources.pak",
402 "$root_gen_dir/net/net_resources.pak",
403 "$root_gen_dir/ui/resources/ui_resources_100_percent.pak",
404 "$root_gen_dir/ui/resources/webui_resources.pak",
405 "$root_gen_dir/ui/strings/app_locale_settings_en-US.pak",
406 "$root_gen_dir/ui/strings/ui_strings_en-US.pak",
[email protected]6b9028ab2014-07-23 17:15:38407 ]
408
409 deps = [
410 ":resources",
411 "//content:resources",
[email protected]a9ca8d52014-08-22 10:21:08412 "//content/app/resources",
[email protected]6586a2e32014-08-09 19:24:12413 "//content/app/strings",
[email protected]6b9028ab2014-07-23 17:15:38414 "//content/browser/tracing:resources",
415 "//net:net_resources",
erga3c614c92015-04-03 17:47:51416 "//third_party/WebKit/public:image_resources",
[email protected]4eebe74d2014-08-13 02:54:46417 "//third_party/WebKit/public:resources",
[email protected]6b9028ab2014-07-23 17:15:38418 "//ui/resources",
419 "//ui/strings",
[email protected]6b9028ab2014-07-23 17:15:38420 ]
421
sadrul7bd20c92015-06-24 16:45:44422 if (toolkit_views) {
423 deps += [ "//ui/views/resources" ]
424 sources +=
425 [ "$root_gen_dir/ui/views/resources/views_resources_100_percent.pak" ]
426 }
427
vivek.vg77816a12014-12-18 14:28:20428 sources += [ "$root_gen_dir/blink/devtools_resources.pak" ]
cjhopman2fd48fd2014-09-24 00:52:56429 deps += [ "//content/browser/devtools:resources" ]
430 output = "$root_out_dir/content_shell.pak"
[email protected]6b9028ab2014-07-23 17:15:38431}
432
James Robinson060f2e32014-09-10 22:31:37433# TODO(GYP): Figure out what this should be on android
dpranke380390f2014-11-21 06:08:53434# and make linking this work on the Mac.
brettw4897a612015-03-02 23:13:15435if (!is_android && !is_mac) {
brettw2e2220c2015-07-21 18:56:35436 # TODO(brettw) when GYP is no longer necessary, delete
437 # content/shell/app/shell.exe.manifest. This file is not used in GN.
scottmg7afc4092014-12-03 19:22:42438 executable("content_shell") {
439 testonly = true
James Robinson060f2e32014-09-10 22:31:37440
scottmg7afc4092014-12-03 19:22:42441 # TODO(GYP) mac resource bundle stuff for this target.
442 # TODO(GYP) Windows content shell settings:
scottmg7afc4092014-12-03 19:22:42443 # - RC file.
444 # - 'LinkIncremental': '<(msvs_large_module_debug_link_mode)',
445 sources = [
scottmg7afc4092014-12-03 19:22:42446 "app/shell_main.cc",
447 ]
[email protected]6b9028ab2014-07-23 17:15:38448
skobes502412ae2016-01-19 17:40:43449 defines = []
450
scottmg7afc4092014-12-03 19:22:42451 deps = [
452 ":content_shell_lib",
453 ":pak",
brettwba7a73d2015-08-31 22:17:39454 "//build/config/sanitizers:deps",
brettw2e2220c2015-07-21 18:56:35455 "//build/win:default_exe_manifest",
scottmg7afc4092014-12-03 19:22:42456 ]
[email protected]6b9028ab2014-07-23 17:15:38457
scottmg7afc4092014-12-03 19:22:42458 if (is_win) {
459 deps += [ "//sandbox" ]
skobes502412ae2016-01-19 17:40:43460 if (win_console_app) {
461 defines += [ "WIN_CONSOLE_APP" ]
462 } else {
463 # Set /SUBSYSTEM:WINDOWS unless a console build has been requested.
scottmg7afc4092014-12-03 19:22:42464 configs -= [ "//build/config/win:console" ]
465 configs += [ "//build/config/win:windowed" ]
466 }
467 }
468
469 if (is_mac) {
brettwe1d40652015-10-23 23:06:10470 # TODO(GYP) lots of stuff from GYP file here including helper_app and
471 # postbuilds.
472 output_name = content_shell_product_name
473 deps = [
474 ":framework",
475 ]
scottmg7afc4092014-12-03 19:22:42476 }
477
torne1b1c9782015-03-30 20:49:00478 if (is_android) {
scottmg7afc4092014-12-03 19:22:42479 # Some tests rely on this tool. It might be nicer if these tests relied on
480 # image diff rather than having content shell depend on it.
sadrul1f7fa9f2015-10-06 17:14:57481 data_deps = [
482 "//tools/imagediff($host_toolchain)",
483 ]
[email protected]6b9028ab2014-07-23 17:15:38484 }
wangxianzhu1a34fa32016-03-10 21:03:00485
486 if (is_linux && !is_component_build) {
487 # Set rpath to find our own libfreetype even in a non-component build.
488 configs += [ "//build/config/gcc:rpath_for_built_shared_libraries" ]
489 }
[email protected]6b9028ab2014-07-23 17:15:38490 }
brettw6aa189562015-02-02 05:34:22491} else {
492 group("content_shell") {
dpranked4063e42015-05-01 01:23:42493 testonly = true
494 deps = [
495 ":content_shell_lib",
496 ]
brettw6aa189562015-02-02 05:34:22497 }
James Robinson060f2e32014-09-10 22:31:37498}
tfarina10ae51f62015-05-13 03:35:57499
tfarina795e01a2015-05-15 19:29:57500if (is_win) {
501 # GYP version: content/content_shell_and_tests.gyp:content_shell_crash_service
brettw0d3b1df2015-12-03 00:10:01502 executable("content_shell_crash_service") {
tfarina795e01a2015-05-15 19:29:57503 sources = [
504 "tools/content_shell_crash_service.cc",
505 ]
506
507 deps = [
508 "//base",
brettwba7a73d2015-08-31 22:17:39509 "//build/config/sanitizers:deps",
sdefresne8ba0b88c2015-09-18 10:33:13510 "//components/crash/content/tools:crash_service",
tfarina795e01a2015-05-15 19:29:57511 ]
512
513 configs -= [ "//build/config/win:console" ]
514 configs += [ "//build/config/win:windowed" ]
515 }
516}
brettwe1d40652015-10-23 23:06:10517
518if (is_mac) {
519 # TODO(GYP) this should be a bundle. Lots of other stuff in this target.
520 # GYP version: content/content_shell.gypi:content_shell_framework
521 shared_library("framework") {
522 testonly = true
523
524 # TODO(GYP) bug 546894: Fix GN and toolchains to handle spaces here.
525 #output_name = "$content_shell_product_name Framework"
526 output_name = "content_shell_framework" # Temporary one with no spaces.
527
528 sources = [
tfarinac708f3972015-10-25 17:42:50529 "app/shell_content_main.cc",
530 "app/shell_content_main.h",
brettwe1d40652015-10-23 23:06:10531 ]
532
533 deps = [
534 ":content_shell_lib",
535 ]
536 }
537}
ortunof78c8412016-03-31 18:59:59538
539mojom("mojo_bindings") {
540 sources = [
541 "common/layout_test/layout_test_bluetooth_fake_adapter_setter.mojom",
542 ]
543}