[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 1 | # 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 | |
| 5 | import("//build/config/features.gni") |
brettw | 4cab0f1 | 2015-09-14 21:40:01 | [diff] [blame] | 6 | import("//build/config/sanitizers/sanitizers.gni") |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 7 | import("//build/config/ui.gni") |
skobes | 502412ae | 2016-01-19 17:40:43 | [diff] [blame] | 8 | import("//build/config/win/console_app.gni") |
brettw | 2e2220c | 2015-07-21 18:56:35 | [diff] [blame] | 9 | import("//build/config/win/manifest.gni") |
alokp | aa2fdfb7 | 2016-02-03 22:55:54 | [diff] [blame] | 10 | import("//media/media_options.gni") |
ortuno | f78c841 | 2016-03-31 18:59:59 | [diff] [blame] | 11 | import("//mojo/public/tools/bindings/mojom.gni") |
brettw | 4b46108 | 2016-11-19 18:55:16 | [diff] [blame] | 12 | import("//ppapi/features/features.gni") |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 13 | import("//tools/grit/repack.gni") |
cjhopman | cd7694af | 2014-09-08 00:00:04 | [diff] [blame] | 14 | import("//tools/grit/grit_rule.gni") |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 15 | if (is_android) { |
| 16 | import("//build/config/android/config.gni") |
rsesek | 20a58a6 | 2016-04-15 20:59:23 | [diff] [blame] | 17 | } else if (is_mac) { |
| 18 | import("//build/config/mac/rules.gni") |
rsesek | 90112aa6 | 2016-05-03 17:33:36 | [diff] [blame] | 19 | import("//build/mac/tweak_info_plist.gni") |
jshin | 359df9c9 | 2016-07-30 06:59:49 | [diff] [blame] | 20 | import("//third_party/icu/config.gni") |
machenbach | d65ec5c | 2016-07-22 09:05:23 | [diff] [blame] | 21 | import("//v8/gni/v8.gni") |
sebmarchand | a2df339 | 2016-07-13 15:34:59 | [diff] [blame] | 22 | } else if (is_win) { |
| 23 | import("//build/win/syzygy/syzygy.gni") |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 24 | } |
| 25 | |
| 26 | declare_args() { |
| 27 | content_shell_product_name = "Content Shell" |
esprehn | b378909 | 2015-11-24 19:46:03 | [diff] [blame] | 28 | content_shell_version = "99.77.34.5" |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 29 | } |
| 30 | |
thakis | ff2eab9c | 2015-11-13 00:29:58 | [diff] [blame] | 31 | config("content_shell_lib_warnings") { |
| 32 | if (is_clang) { |
| 33 | # TODO(thakis): Remove this once http://crbug.com/383820 is figured out |
| 34 | cflags = [ "-Wno-nonnull" ] |
| 35 | } |
| 36 | } |
| 37 | |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 38 | static_library("content_shell_lib") { |
Brett Wilson | 8f80ad0b | 2014-09-08 19:50:24 | [diff] [blame] | 39 | testonly = true |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 40 | sources = [ |
dpranke | c6beb839 | 2015-10-30 23:44:21 | [diff] [blame] | 41 | "android/shell_descriptors.h", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 42 | "android/shell_jni_registrar.cc", |
| 43 | "android/shell_jni_registrar.h", |
| 44 | "android/shell_manager.cc", |
| 45 | "android/shell_manager.h", |
lukasza | 88e4b0b4 | 2016-02-25 21:42:10 | [diff] [blame] | 46 | "app/blink_test_platform_support.h", |
| 47 | "app/blink_test_platform_support_android.cc", |
| 48 | "app/blink_test_platform_support_linux.cc", |
| 49 | "app/blink_test_platform_support_mac.mm", |
| 50 | "app/blink_test_platform_support_win.cc", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 51 | "app/paths_mac.h", |
| 52 | "app/paths_mac.mm", |
rsesek | a0a7a04 | 2014-09-18 23:59:20 | [diff] [blame] | 53 | "app/shell_crash_reporter_client.cc", |
| 54 | "app/shell_crash_reporter_client.h", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 55 | "app/shell_main_delegate.cc", |
| 56 | "app/shell_main_delegate.h", |
| 57 | "app/shell_main_delegate_mac.h", |
| 58 | "app/shell_main_delegate_mac.mm", |
jochen | 5ce1af9 | 2016-02-17 20:39:45 | [diff] [blame] | 59 | "browser/layout_test/blink_test_controller.cc", |
| 60 | "browser/layout_test/blink_test_controller.h", |
ortuno | fd24faa | 2015-05-20 16:34:37 | [diff] [blame] | 61 | "browser/layout_test/layout_test_bluetooth_adapter_provider.cc", |
| 62 | "browser/layout_test/layout_test_bluetooth_adapter_provider.h", |
jyasskin | 8057c00 | 2015-09-10 19:09:53 | [diff] [blame] | 63 | "browser/layout_test/layout_test_bluetooth_chooser_factory.cc", |
| 64 | "browser/layout_test/layout_test_bluetooth_chooser_factory.h", |
ortuno | f78c841 | 2016-03-31 18:59:59 | [diff] [blame] | 65 | "browser/layout_test/layout_test_bluetooth_fake_adapter_setter_impl.cc", |
| 66 | "browser/layout_test/layout_test_bluetooth_fake_adapter_setter_impl.h", |
mkwst | d993d06a | 2014-10-10 11:44:38 | [diff] [blame] | 67 | "browser/layout_test/layout_test_browser_context.cc", |
| 68 | "browser/layout_test/layout_test_browser_context.h", |
mkwst | 88e2318 | 2014-10-16 12:08:58 | [diff] [blame] | 69 | "browser/layout_test/layout_test_browser_main.cc", |
| 70 | "browser/layout_test/layout_test_browser_main.h", |
mkwst | 36b11b6f | 2014-10-15 16:18:56 | [diff] [blame] | 71 | "browser/layout_test/layout_test_browser_main_parts.cc", |
| 72 | "browser/layout_test/layout_test_browser_main_parts.h", |
peter | cd7abb4 | 2014-10-17 13:34:01 | [diff] [blame] | 73 | "browser/layout_test/layout_test_content_browser_client.cc", |
| 74 | "browser/layout_test/layout_test_content_browser_client.h", |
mkwst | 30d20d5 | 2014-10-09 13:33:14 | [diff] [blame] | 75 | "browser/layout_test/layout_test_devtools_frontend.cc", |
| 76 | "browser/layout_test/layout_test_devtools_frontend.h", |
mkwst | 94388f79 | 2014-10-16 07:36:52 | [diff] [blame] | 77 | "browser/layout_test/layout_test_download_manager_delegate.cc", |
| 78 | "browser/layout_test/layout_test_download_manager_delegate.h", |
ortuno | 1045554 | 2016-07-01 00:06:43 | [diff] [blame] | 79 | "browser/layout_test/layout_test_first_device_bluetooth_chooser.cc", |
| 80 | "browser/layout_test/layout_test_first_device_bluetooth_chooser.h", |
mkwst | 6efe7f2e6 | 2014-10-08 15:09:01 | [diff] [blame] | 81 | "browser/layout_test/layout_test_javascript_dialog_manager.cc", |
| 82 | "browser/layout_test/layout_test_javascript_dialog_manager.h", |
Peter Beverloo | e8f2f9d | 2014-10-20 16:47:49 | [diff] [blame] | 83 | "browser/layout_test/layout_test_message_filter.cc", |
| 84 | "browser/layout_test/layout_test_message_filter.h", |
peter | cd7abb4 | 2014-10-17 13:34:01 | [diff] [blame] | 85 | "browser/layout_test/layout_test_notification_manager.cc", |
| 86 | "browser/layout_test/layout_test_notification_manager.h", |
mlamouri | 4e37202 | 2015-03-29 14:51:06 | [diff] [blame] | 87 | "browser/layout_test/layout_test_permission_manager.cc", |
| 88 | "browser/layout_test/layout_test_permission_manager.h", |
mvanouwerkerk | de895c9c | 2014-12-06 12:17:32 | [diff] [blame] | 89 | "browser/layout_test/layout_test_push_messaging_service.cc", |
| 90 | "browser/layout_test/layout_test_push_messaging_service.h", |
mkwst | 002d0290 | 2014-10-09 10:17:00 | [diff] [blame] | 91 | "browser/layout_test/layout_test_resource_dispatcher_host_delegate.cc", |
| 92 | "browser/layout_test/layout_test_resource_dispatcher_host_delegate.h", |
mkwst | 94388f79 | 2014-10-16 07:36:52 | [diff] [blame] | 93 | "browser/layout_test/layout_test_url_request_context_getter.cc", |
| 94 | "browser/layout_test/layout_test_url_request_context_getter.h", |
lukasza | 8e550a0 | 2016-04-18 18:34:17 | [diff] [blame] | 95 | "browser/layout_test/secondary_test_window_observer.cc", |
| 96 | "browser/layout_test/secondary_test_window_observer.h", |
jochen | e9ba6dd | 2016-02-23 17:20:49 | [diff] [blame] | 97 | "browser/layout_test/test_info_extractor.cc", |
| 98 | "browser/layout_test/test_info_extractor.h", |
peter | 11d5f56 | 2014-10-23 23:12:25 | [diff] [blame] | 99 | "browser/shell.cc", |
| 100 | "browser/shell.h", |
| 101 | "browser/shell_access_token_store.cc", |
| 102 | "browser/shell_access_token_store.h", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 103 | "browser/shell_android.cc", |
| 104 | "browser/shell_application_mac.h", |
| 105 | "browser/shell_application_mac.mm", |
| 106 | "browser/shell_browser_context.cc", |
| 107 | "browser/shell_browser_context.h", |
| 108 | "browser/shell_browser_main.cc", |
| 109 | "browser/shell_browser_main.h", |
| 110 | "browser/shell_browser_main_parts.cc", |
| 111 | "browser/shell_browser_main_parts.h", |
| 112 | "browser/shell_browser_main_parts_mac.mm", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 113 | "browser/shell_content_browser_client.cc", |
| 114 | "browser/shell_content_browser_client.h", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 115 | "browser/shell_devtools_frontend.cc", |
| 116 | "browser/shell_devtools_frontend.h", |
satorux | 7fa9d30 | 2015-02-16 00:44:52 | [diff] [blame] | 117 | "browser/shell_devtools_manager_delegate.cc", |
| 118 | "browser/shell_devtools_manager_delegate.h", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 119 | "browser/shell_download_manager_delegate.cc", |
| 120 | "browser/shell_download_manager_delegate.h", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 121 | "browser/shell_javascript_dialog.h", |
| 122 | "browser/shell_javascript_dialog_mac.mm", |
| 123 | "browser/shell_javascript_dialog_manager.cc", |
| 124 | "browser/shell_javascript_dialog_manager.h", |
| 125 | "browser/shell_javascript_dialog_win.cc", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 126 | "browser/shell_login_dialog.cc", |
| 127 | "browser/shell_login_dialog.h", |
| 128 | "browser/shell_login_dialog_mac.mm", |
| 129 | "browser/shell_mac.mm", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 130 | "browser/shell_net_log.cc", |
| 131 | "browser/shell_net_log.h", |
| 132 | "browser/shell_network_delegate.cc", |
| 133 | "browser/shell_network_delegate.h", |
mlamouri | 4e37202 | 2015-03-29 14:51:06 | [diff] [blame] | 134 | "browser/shell_permission_manager.cc", |
| 135 | "browser/shell_permission_manager.h", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 136 | "browser/shell_platform_data_aura.cc", |
| 137 | "browser/shell_platform_data_aura.h", |
| 138 | "browser/shell_plugin_service_filter.cc", |
| 139 | "browser/shell_plugin_service_filter.h", |
| 140 | "browser/shell_quota_permission_context.cc", |
| 141 | "browser/shell_quota_permission_context.h", |
| 142 | "browser/shell_resource_dispatcher_host_delegate.cc", |
| 143 | "browser/shell_resource_dispatcher_host_delegate.h", |
| 144 | "browser/shell_speech_recognition_manager_delegate.cc", |
| 145 | "browser/shell_speech_recognition_manager_delegate.h", |
| 146 | "browser/shell_url_request_context_getter.cc", |
| 147 | "browser/shell_url_request_context_getter.h", |
satorux | 7fa9d30 | 2015-02-16 00:44:52 | [diff] [blame] | 148 | "browser/shell_web_contents_view_delegate.h", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 149 | "browser/shell_web_contents_view_delegate_android.cc", |
| 150 | "browser/shell_web_contents_view_delegate_creator.h", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 151 | "browser/shell_web_contents_view_delegate_mac.mm", |
lukasza | 80f7f60 | 2016-03-22 23:13:19 | [diff] [blame] | 152 | "common/layout_test/layout_test_content_client.cc", |
| 153 | "common/layout_test/layout_test_content_client.h", |
peter | e0420359 | 2014-10-27 17:57:35 | [diff] [blame] | 154 | "common/layout_test/layout_test_messages.cc", |
| 155 | "common/layout_test/layout_test_messages.h", |
lukasza | 381b049 | 2016-03-10 16:48:43 | [diff] [blame] | 156 | "common/layout_test/layout_test_switches.cc", |
| 157 | "common/layout_test/layout_test_switches.h", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 158 | "common/leak_detection_result.h", |
| 159 | "common/shell_content_client.cc", |
| 160 | "common/shell_content_client.h", |
| 161 | "common/shell_messages.cc", |
| 162 | "common/shell_messages.h", |
iclelland | 186a896 | 2016-06-22 16:06:20 | [diff] [blame] | 163 | "common/shell_origin_trial_policy.cc", |
| 164 | "common/shell_origin_trial_policy.h", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 165 | "common/shell_switches.cc", |
| 166 | "common/shell_switches.h", |
tfarina | 685c3980 | 2015-05-04 22:11:22 | [diff] [blame] | 167 | "renderer/layout_test/blink_test_helpers.cc", |
| 168 | "renderer/layout_test/blink_test_helpers.h", |
tfarina | 8e08285f | 2015-05-02 03:17:39 | [diff] [blame] | 169 | "renderer/layout_test/blink_test_runner.cc", |
| 170 | "renderer/layout_test/blink_test_runner.h", |
sammc | 9b9e5b4 | 2016-10-12 12:32:32 | [diff] [blame] | 171 | "renderer/layout_test/interface_registry_js_wrapper.cc", |
| 172 | "renderer/layout_test/interface_registry_js_wrapper.h", |
mkwst | 02ec0d6 | 2014-10-07 22:07:29 | [diff] [blame] | 173 | "renderer/layout_test/layout_test_content_renderer_client.cc", |
| 174 | "renderer/layout_test/layout_test_content_renderer_client.h", |
mkwst | 3e72c1f | 2014-10-08 05:02:36 | [diff] [blame] | 175 | "renderer/layout_test/layout_test_render_frame_observer.cc", |
| 176 | "renderer/layout_test/layout_test_render_frame_observer.h", |
tyoshino | 832a58a | 2016-04-18 08:14:08 | [diff] [blame] | 177 | "renderer/layout_test/layout_test_render_thread_observer.cc", |
| 178 | "renderer/layout_test/layout_test_render_thread_observer.h", |
mkwst | 04b72d1 | 2014-10-08 15:52:55 | [diff] [blame] | 179 | "renderer/layout_test/leak_detector.cc", |
| 180 | "renderer/layout_test/leak_detector.h", |
jochen | 5126513 | 2015-05-28 07:33:45 | [diff] [blame] | 181 | "renderer/layout_test/test_media_stream_renderer_factory.cc", |
| 182 | "renderer/layout_test/test_media_stream_renderer_factory.h", |
chfremer | bcfff021 | 2016-06-06 18:29:41 | [diff] [blame] | 183 | "renderer/layout_test/test_media_stream_video_renderer.cc", |
| 184 | "renderer/layout_test/test_media_stream_video_renderer.h", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 185 | "renderer/shell_content_renderer_client.cc", |
| 186 | "renderer/shell_content_renderer_client.h", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 187 | "renderer/shell_render_view_observer.cc", |
| 188 | "renderer/shell_render_view_observer.h", |
rockot | b814a58 | 2015-06-05 00:30:52 | [diff] [blame] | 189 | "utility/shell_content_utility_client.cc", |
| 190 | "utility/shell_content_utility_client.h", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 191 | ] |
| 192 | |
brettw | bc8b2a2 | 2015-07-28 18:24:42 | [diff] [blame] | 193 | configs += [ |
thakis | ff2eab9c | 2015-11-13 00:29:58 | [diff] [blame] | 194 | ":content_shell_lib_warnings", |
brettw | bc8b2a2 | 2015-07-28 18:24:42 | [diff] [blame] | 195 | "//build/config:precompiled_headers", |
| 196 | |
| 197 | # TODO(jschuh): crbug.com/167187 fix size_t to int truncations. |
| 198 | "//build/config/compiler:no_size_t_to_int_warning", |
| 199 | ] |
brettw | d1c719a | 2015-02-19 23:17:04 | [diff] [blame] | 200 | |
xhwang | 41f1d0e | 2016-11-11 08:16:36 | [diff] [blame] | 201 | if (enable_mojo_media) { |
| 202 | configs += [ "//media/mojo/services:mojo_media_config" ] |
| 203 | } |
| 204 | |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 205 | defines = [ "CONTENT_SHELL_VERSION=\"$content_shell_version\"" ] |
| 206 | |
Brett Wilson | 0380637c | 2014-09-19 21:24:40 | [diff] [blame] | 207 | public_deps = [ |
| 208 | # This exposes all public content APIs. |
| 209 | "//content/public/app:both", |
| 210 | "//content/public/browser", |
| 211 | "//content/public/common", |
Brett Wilson | 0380637c | 2014-09-19 21:24:40 | [diff] [blame] | 212 | "//content/public/renderer", |
| 213 | "//content/public/utility", |
| 214 | ] |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 215 | deps = [ |
ortuno | f78c841 | 2016-03-31 18:59:59 | [diff] [blame] | 216 | ":mojo_bindings", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 217 | ":resources", |
| 218 | "//base", |
| 219 | "//base:base_static", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 220 | "//base/third_party/dynamic_annotations", |
| 221 | "//cc", |
xhwang | bcd68581 | 2016-09-22 23:35:55 | [diff] [blame] | 222 | "//components/cdm/renderer", |
scottmg | cfa5b01b | 2015-11-30 23:13:46 | [diff] [blame] | 223 | "//components/crash/content/app:app_breakpad_mac_win_to_be_deleted", |
juliatuttle | ca57a11b | 2016-11-15 19:07:53 | [diff] [blame] | 224 | "//components/keyed_service/content", |
chrishtr | 8a377e6 | 2015-06-01 19:20:08 | [diff] [blame] | 225 | "//components/plugins/renderer", |
rsleevi | 24f64dc2 | 2015-08-07 21:39:21 | [diff] [blame] | 226 | "//components/url_formatter", |
hanxi | 149b92d | 2014-09-11 21:57:18 | [diff] [blame] | 227 | "//components/web_cache/renderer", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 228 | "//content:resources", |
[email protected] | a9ca8d5 | 2014-08-22 10:21:08 | [diff] [blame] | 229 | "//content/app/resources", |
[email protected] | 6586a2e3 | 2014-08-09 19:24:12 | [diff] [blame] | 230 | "//content/app/strings", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 231 | "//content/gpu", |
ben | 51bb6c6 | 2016-11-17 20:15:57 | [diff] [blame] | 232 | "//content/public/common:service_names", |
dcheng | 59826e3 | 2017-02-22 10:31:36 | [diff] [blame] | 233 | "//content/shell/test_runner:test_runner", |
brettw | 6b0712a | 2016-07-15 17:48:20 | [diff] [blame] | 234 | "//content/test:content_test_mojo_bindings", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 235 | "//content/test:layouttest_support", |
brettw | b78fc9e | 2016-03-25 21:02:51 | [diff] [blame] | 236 | "//content/test:test_support", |
dpranke | 93211fc | 2015-04-29 04:59:42 | [diff] [blame] | 237 | "//device/bluetooth", |
ortuno | fd24faa | 2015-05-20 16:34:37 | [diff] [blame] | 238 | "//device/bluetooth:mocks", |
lethalantidote | 893681c | 2016-09-13 19:36:31 | [diff] [blame] | 239 | "//device/geolocation", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 240 | "//gin", |
| 241 | "//gpu", |
| 242 | "//ipc", |
| 243 | "//media", |
chfremer | b689c2a | 2016-10-27 23:04:46 | [diff] [blame] | 244 | "//media/capture", |
sammc | 9b9e5b4 | 2016-10-12 12:32:32 | [diff] [blame] | 245 | "//mojo/edk/js", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 246 | "//net", |
| 247 | "//net:net_resources", |
brettw | 4b46108 | 2016-11-19 18:55:16 | [diff] [blame] | 248 | "//ppapi/features", |
brettw | 6b0712a | 2016-07-15 17:48:20 | [diff] [blame] | 249 | "//sandbox", |
rockot | 734fb66 | 2016-10-15 16:41:30 | [diff] [blame] | 250 | "//services/service_manager/public/cpp", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 251 | "//skia", |
pilgrim | 4af8c21 | 2014-09-05 17:30:15 | [diff] [blame] | 252 | "//storage/browser", |
ortuno | fd24faa | 2015-05-20 16:34:37 | [diff] [blame] | 253 | "//testing/gmock", |
| 254 | "//testing/gtest", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 255 | "//third_party/WebKit/public:blink", |
brettw | cb4ab75a | 2016-11-02 19:25:59 | [diff] [blame] | 256 | "//third_party/WebKit/public:features", |
erg | a3c614c9 | 2015-04-03 17:47:51 | [diff] [blame] | 257 | "//third_party/WebKit/public:image_resources", |
[email protected] | 4eebe74d | 2014-08-13 02:54:46 | [diff] [blame] | 258 | "//third_party/WebKit/public:resources", |
[email protected] | 0e04359 | 2014-07-28 19:47:04 | [diff] [blame] | 259 | "//third_party/WebKit/public:test_support", |
[email protected] | 4eebe74d | 2014-08-13 02:54:46 | [diff] [blame] | 260 | "//third_party/icu", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 261 | "//ui/base", |
spang | 1c36fac | 2015-02-05 19:55:12 | [diff] [blame] | 262 | "//ui/base/ime", |
brettw | 6b0712a | 2016-07-15 17:48:20 | [diff] [blame] | 263 | "//ui/display", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 264 | "//ui/events:events_base", |
| 265 | "//ui/gfx", |
| 266 | "//ui/gfx/geometry", |
| 267 | "//ui/gfx/ipc", |
fsamuel | 6b98cf9 | 2016-04-28 05:42:24 | [diff] [blame] | 268 | "//ui/gfx/ipc/geometry", |
markdittmer | 99d77bf | 2016-03-31 19:03:24 | [diff] [blame] | 269 | "//ui/gfx/ipc/skia", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 270 | "//ui/gl", |
| 271 | "//url", |
| 272 | "//v8", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 273 | ] |
brettw | 6b0712a | 2016-07-15 17:48:20 | [diff] [blame] | 274 | |
| 275 | # Annoyingly, this target and layouttest_support have circular includes. |
| 276 | allow_circular_includes_from = [ "//content/test:layouttest_support" ] |
| 277 | |
jamesr | 5008174 | 2014-09-09 07:52:22 | [diff] [blame] | 278 | if (enable_plugins) { |
dcheng | 0d93c1a | 2015-12-03 02:46:41 | [diff] [blame] | 279 | deps += [ |
enne | 7b64edf3 | 2017-02-16 20:10:02 | [diff] [blame] | 280 | "//cc/paint", |
dcheng | 0d93c1a | 2015-12-03 02:46:41 | [diff] [blame] | 281 | "//content/ppapi_plugin", |
dcheng | c70b36e | 2016-03-02 02:36:10 | [diff] [blame] | 282 | "//ppapi:blink_deprecated_test_plugin", |
dcheng | 0d93c1a | 2015-12-03 02:46:41 | [diff] [blame] | 283 | "//ppapi:blink_test_plugin", |
brettw | b78fc9e | 2016-03-25 21:02:51 | [diff] [blame] | 284 | "//ppapi/shared_impl", |
dcheng | 0d93c1a | 2015-12-03 02:46:41 | [diff] [blame] | 285 | ] |
jamesr | 5008174 | 2014-09-09 07:52:22 | [diff] [blame] | 286 | } |
xhwang | be72003 | 2016-02-19 18:45:31 | [diff] [blame] | 287 | if (mojo_media_host == "browser") { |
xhwang | d3b5d3f | 2016-05-18 03:37:59 | [diff] [blame] | 288 | deps += [ "//media/mojo/services" ] |
alokp | aa2fdfb7 | 2016-02-03 22:55:54 | [diff] [blame] | 289 | } |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 290 | |
| 291 | if (is_win) { |
vchigrin | 61944ae | 2015-01-30 23:51:32 | [diff] [blame] | 292 | sources += [ |
| 293 | "common/v8_breakpad_support_win.cc", |
| 294 | "common/v8_breakpad_support_win.h", |
| 295 | ] |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 296 | } |
| 297 | |
| 298 | if (is_linux) { |
brettw | b78fc9e | 2016-03-25 21:02:51 | [diff] [blame] | 299 | deps += [ |
| 300 | "//build/linux:fontconfig", |
| 301 | "//ui/gfx:test_support", |
| 302 | ] |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 303 | } |
| 304 | |
| 305 | if (use_x11) { |
[email protected] | c7990dbf | 2014-07-23 22:35:10 | [diff] [blame] | 306 | # Some tests rely on this tool at runtime. Note: it might be better if |
| 307 | # the tests that needed it had this as a dep instead of adding it here. |
kylechar | ad71487 | 2016-04-20 16:09:52 | [diff] [blame] | 308 | deps += [ "//ui/events/devices/x11" ] |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 309 | } |
| 310 | |
| 311 | if (is_android) { |
jbudorick | 2d40c48d | 2017-01-09 21:05:00 | [diff] [blame] | 312 | sources += [ |
| 313 | "browser/layout_test/scoped_android_configuration.cc", |
| 314 | "browser/layout_test/scoped_android_configuration.h", |
| 315 | ] |
| 316 | deps += [ |
| 317 | "//base/test:test_support", |
| 318 | "//content/shell/android:content_shell_jni_headers", |
| 319 | ] |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 320 | } |
| 321 | |
torne | 1b1c978 | 2015-03-30 20:49:00 | [diff] [blame] | 322 | if (is_posix && !is_mac) { |
brettw | b78fc9e | 2016-03-25 21:02:51 | [diff] [blame] | 323 | deps += [ |
| 324 | "//components/crash/content/app", |
| 325 | "//components/crash/content/browser", |
| 326 | ] |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 327 | } |
| 328 | |
| 329 | if (use_aura) { |
| 330 | deps += [ |
ben | d906307 | 2016-11-12 01:32:51 | [diff] [blame] | 331 | "//services/navigation", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 332 | "//ui/aura", |
| 333 | "//ui/aura:test_support", |
| 334 | "//ui/events", |
| 335 | "//ui/strings", |
| 336 | "//ui/wm", |
| 337 | ] |
| 338 | |
| 339 | if (toolkit_views) { |
mohsen | 6eb57fb | 2016-07-22 03:14:08 | [diff] [blame] | 340 | sources += [ |
| 341 | "browser/shell_views.cc", |
| 342 | "browser/shell_web_contents_view_delegate_views.cc", |
| 343 | ] |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 344 | deps += [ |
| 345 | "//ui/resources", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 346 | "//ui/views", |
| 347 | "//ui/views:test_support", |
agrieve | d7a71c88 | 2015-11-20 19:53:28 | [diff] [blame] | 348 | "//ui/views/controls/webview", |
brettw | b78fc9e | 2016-03-25 21:02:51 | [diff] [blame] | 349 | "//ui/wm:test_support", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 350 | ] |
| 351 | } else { |
mohsen | 6eb57fb | 2016-07-22 03:14:08 | [diff] [blame] | 352 | sources += [ |
| 353 | "browser/shell_aura.cc", |
| 354 | "browser/shell_web_contents_view_delegate_aura.cc", |
| 355 | ] |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 356 | } |
James Robinson | 060f2e3 | 2014-09-10 22:31:37 | [diff] [blame] | 357 | } else { |
| 358 | sources -= [ |
| 359 | "browser/shell_platform_data_aura.cc", |
| 360 | "browser/shell_platform_data_aura.h", |
| 361 | ] |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 362 | } |
| 363 | |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 364 | if (is_chromeos) { |
| 365 | deps += [ |
mukai | 6ba7355 | 2014-10-09 19:05:17 | [diff] [blame] | 366 | "//chromeos", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 367 | "//ui/wm:test_support", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 368 | ] |
| 369 | } |
| 370 | |
bcf | 0ddf78a | 2016-02-02 18:52:21 | [diff] [blame] | 371 | if (is_linux) { |
drott | fe896a8 | 2017-03-06 12:12:54 | [diff] [blame] | 372 | deps += [ "//third_party/freetype" ] |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 373 | } |
| 374 | |
| 375 | if (!enable_plugins) { |
| 376 | sources -= [ |
| 377 | "browser/shell_plugin_service_filter.cc", |
| 378 | "browser/shell_plugin_service_filter.h", |
| 379 | ] |
| 380 | } |
| 381 | } |
| 382 | |
| 383 | grit("content_shell_resources_grit") { |
brettw | b78fc9e | 2016-03-25 21:02:51 | [diff] [blame] | 384 | # External code should depend on ":resources" instead. |
brettw | 9af4262 | 2014-09-06 21:21:02 | [diff] [blame] | 385 | visibility = [ ":*" ] |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 386 | source = "shell_resources.grd" |
| 387 | outputs = [ |
| 388 | "grit/shell_resources.h", |
| 389 | "shell_resources.pak", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 390 | ] |
| 391 | } |
| 392 | |
| 393 | copy("copy_shell_resources") { |
scottmg | 7afc409 | 2014-12-03 19:22:42 | [diff] [blame] | 394 | sources = [ |
| 395 | "$target_gen_dir/shell_resources.pak", |
| 396 | ] |
scottmg | 34fb7e5 | 2014-12-03 23:27:24 | [diff] [blame] | 397 | outputs = [ |
| 398 | "$root_out_dir/shell_resources.pak", |
| 399 | ] |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 400 | |
scottmg | 7afc409 | 2014-12-03 19:22:42 | [diff] [blame] | 401 | public_deps = [ |
| 402 | ":content_shell_resources_grit", |
| 403 | ] |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 404 | } |
| 405 | |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 406 | group("resources") { |
Brett Wilson | e5389527 | 2014-09-23 23:41:46 | [diff] [blame] | 407 | public_deps = [ |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 408 | ":copy_shell_resources", |
| 409 | ] |
tansell | fa69073 | 2016-11-26 07:06:32 | [diff] [blame] | 410 | deps = [ |
dcheng | 59826e3 | 2017-02-22 10:31:36 | [diff] [blame] | 411 | "//content/shell/test_runner:resources", |
tansell | fa69073 | 2016-11-26 07:06:32 | [diff] [blame] | 412 | ] |
tansell | 08c74c9 | 2016-11-02 05:45:47 | [diff] [blame] | 413 | data_deps = [ |
dcheng | 59826e3 | 2017-02-22 10:31:36 | [diff] [blame] | 414 | "//content/shell/test_runner:resources", |
tansell | 08c74c9 | 2016-11-02 05:45:47 | [diff] [blame] | 415 | ] |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 416 | } |
| 417 | |
| 418 | repack("pak") { |
| 419 | sources = [ |
erg | a3c614c9 | 2015-04-03 17:47:51 | [diff] [blame] | 420 | "$root_gen_dir/blink/public/resources/blink_image_resources_100_percent.pak", |
| 421 | "$root_gen_dir/blink/public/resources/blink_resources.pak", |
[email protected] | a9ca8d5 | 2014-08-22 10:21:08 | [diff] [blame] | 422 | "$root_gen_dir/content/app/resources/content_resources_100_percent.pak", |
[email protected] | 6586a2e3 | 2014-08-09 19:24:12 | [diff] [blame] | 423 | "$root_gen_dir/content/app/strings/content_strings_en-US.pak", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 424 | "$root_gen_dir/content/browser/tracing/tracing_resources.pak", |
[email protected] | 6586a2e3 | 2014-08-09 19:24:12 | [diff] [blame] | 425 | "$root_gen_dir/content/content_resources.pak", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 426 | "$root_gen_dir/content/shell/shell_resources.pak", |
| 427 | "$root_gen_dir/net/net_resources.pak", |
| 428 | "$root_gen_dir/ui/resources/ui_resources_100_percent.pak", |
| 429 | "$root_gen_dir/ui/resources/webui_resources.pak", |
| 430 | "$root_gen_dir/ui/strings/app_locale_settings_en-US.pak", |
| 431 | "$root_gen_dir/ui/strings/ui_strings_en-US.pak", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 432 | ] |
| 433 | |
| 434 | deps = [ |
| 435 | ":resources", |
| 436 | "//content:resources", |
[email protected] | a9ca8d5 | 2014-08-22 10:21:08 | [diff] [blame] | 437 | "//content/app/resources", |
[email protected] | 6586a2e3 | 2014-08-09 19:24:12 | [diff] [blame] | 438 | "//content/app/strings", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 439 | "//content/browser/tracing:resources", |
| 440 | "//net:net_resources", |
erg | a3c614c9 | 2015-04-03 17:47:51 | [diff] [blame] | 441 | "//third_party/WebKit/public:image_resources", |
[email protected] | 4eebe74d | 2014-08-13 02:54:46 | [diff] [blame] | 442 | "//third_party/WebKit/public:resources", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 443 | "//ui/resources", |
| 444 | "//ui/strings", |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 445 | ] |
| 446 | |
sadrul | 7bd20c9 | 2015-06-24 16:45:44 | [diff] [blame] | 447 | if (toolkit_views) { |
| 448 | deps += [ "//ui/views/resources" ] |
| 449 | sources += |
| 450 | [ "$root_gen_dir/ui/views/resources/views_resources_100_percent.pak" ] |
| 451 | } |
| 452 | |
thakis | 300faa7 | 2017-02-28 23:59:43 | [diff] [blame] | 453 | sources += [ "$root_gen_dir/content/browser/devtools/devtools_resources.pak" ] |
cjhopman | 2fd48fd | 2014-09-24 00:52:56 | [diff] [blame] | 454 | deps += [ "//content/browser/devtools:resources" ] |
| 455 | output = "$root_out_dir/content_shell.pak" |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 456 | } |
| 457 | |
agrieve | 993374cf | 2016-04-13 00:05:39 | [diff] [blame] | 458 | if (is_android) { |
| 459 | group("content_shell") { |
| 460 | testonly = true |
| 461 | deps = [ |
| 462 | "//content/shell/android:content_shell_apk", |
| 463 | ] |
| 464 | } |
| 465 | } else if (is_mac) { |
rsesek | 90112aa6 | 2016-05-03 17:33:36 | [diff] [blame] | 466 | tweak_info_plist("content_shell_plist") { |
| 467 | testonly = true |
| 468 | info_plist = "app/app-Info.plist" |
| 469 | args = [ |
| 470 | "--scm=1", |
| 471 | "--version", |
| 472 | content_shell_version, |
| 473 | ] |
| 474 | } |
rsesek | 7f9d12b | 2016-04-29 02:45:56 | [diff] [blame] | 475 | mac_app_bundle("content_shell") { |
agrieve | 993374cf | 2016-04-13 00:05:39 | [diff] [blame] | 476 | testonly = true |
rsesek | 7f9d12b | 2016-04-29 02:45:56 | [diff] [blame] | 477 | output_name = content_shell_product_name |
| 478 | sources = [ |
| 479 | "app/shell_main.cc", |
agrieve | 993374cf | 2016-04-13 00:05:39 | [diff] [blame] | 480 | ] |
rsesek | 7f9d12b | 2016-04-29 02:45:56 | [diff] [blame] | 481 | deps = [ |
| 482 | ":content_shell_framework_bundle_data", |
| 483 | ":content_shell_resources_bundle_data", |
rsesek | 1cfe20c3 | 2016-07-27 17:44:51 | [diff] [blame] | 484 | "//build/config/sanitizers:deps", |
rsesek | 7f9d12b | 2016-04-29 02:45:56 | [diff] [blame] | 485 | |
| 486 | # TODO(rsesek): Remove this after GYP is gone, since it only needs to |
| 487 | # be here per the comment in blink_test_platform_support_mac.mm about |
| 488 | # the bundle structure. |
dcheng | 59826e3 | 2017-02-22 10:31:36 | [diff] [blame] | 489 | "//content/shell/test_runner:resources", |
rsesek | 7f9d12b | 2016-04-29 02:45:56 | [diff] [blame] | 490 | ] |
rsesek | 6a8a5d0 | 2016-06-21 01:16:18 | [diff] [blame] | 491 | ldflags = [ |
| 492 | # The main app is at Content Shell.app/Contents/MacOS/Content Shell |
| 493 | # so set the rpath up to Contents/ so that the loader can find |
| 494 | # Framworks/. |
| 495 | "-rpath", |
| 496 | "@executable_path/../", |
| 497 | ] |
rsesek | 90112aa6 | 2016-05-03 17:33:36 | [diff] [blame] | 498 | info_plist_target = ":content_shell_plist" |
agrieve | 993374cf | 2016-04-13 00:05:39 | [diff] [blame] | 499 | } |
| 500 | } else { |
scottmg | 7afc409 | 2014-12-03 19:22:42 | [diff] [blame] | 501 | executable("content_shell") { |
| 502 | testonly = true |
James Robinson | 060f2e3 | 2014-09-10 22:31:37 | [diff] [blame] | 503 | |
scottmg | 7afc409 | 2014-12-03 19:22:42 | [diff] [blame] | 504 | sources = [ |
scottmg | 7afc409 | 2014-12-03 19:22:42 | [diff] [blame] | 505 | "app/shell_main.cc", |
| 506 | ] |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 507 | |
brucedawson | d4fde4c | 2016-05-02 19:03:58 | [diff] [blame] | 508 | if (is_win) { |
| 509 | sources += [ "app/shell.rc" ] |
| 510 | } |
| 511 | |
skobes | 502412ae | 2016-01-19 17:40:43 | [diff] [blame] | 512 | defines = [] |
| 513 | |
scottmg | 7afc409 | 2014-12-03 19:22:42 | [diff] [blame] | 514 | deps = [ |
| 515 | ":content_shell_lib", |
tansell | fa69073 | 2016-11-26 07:06:32 | [diff] [blame] | 516 | ":pak", |
brettw | ba7a73d | 2015-08-31 22:17:39 | [diff] [blame] | 517 | "//build/config/sanitizers:deps", |
brettw | 2e2220c | 2015-07-21 18:56:35 | [diff] [blame] | 518 | "//build/win:default_exe_manifest", |
scottmg | 7afc409 | 2014-12-03 19:22:42 | [diff] [blame] | 519 | ] |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 520 | |
tansell | 08c74c9 | 2016-11-02 05:45:47 | [diff] [blame] | 521 | data_deps = [ |
| 522 | ":pak", |
| 523 | ] |
| 524 | |
scottmg | 7afc409 | 2014-12-03 19:22:42 | [diff] [blame] | 525 | if (is_win) { |
| 526 | deps += [ "//sandbox" ] |
brucedawson | d4fde4c | 2016-05-02 19:03:58 | [diff] [blame] | 527 | |
| 528 | # This is a large module that can't do incremental linking in some cases. |
| 529 | configs -= [ "//build/config/win:default_incremental_linking" ] |
| 530 | configs += |
| 531 | [ "//build/config/win:default_large_module_incremental_linking" ] |
skobes | 502412ae | 2016-01-19 17:40:43 | [diff] [blame] | 532 | if (win_console_app) { |
| 533 | defines += [ "WIN_CONSOLE_APP" ] |
| 534 | } else { |
| 535 | # Set /SUBSYSTEM:WINDOWS unless a console build has been requested. |
scottmg | 7afc409 | 2014-12-03 19:22:42 | [diff] [blame] | 536 | configs -= [ "//build/config/win:console" ] |
| 537 | configs += [ "//build/config/win:windowed" ] |
| 538 | } |
| 539 | } |
| 540 | |
wangxianzhu | 1a34fa3 | 2016-03-10 21:03:00 | [diff] [blame] | 541 | if (is_linux && !is_component_build) { |
| 542 | # Set rpath to find our own libfreetype even in a non-component build. |
| 543 | configs += [ "//build/config/gcc:rpath_for_built_shared_libraries" ] |
| 544 | } |
[email protected] | 6b9028ab | 2014-07-23 17:15:38 | [diff] [blame] | 545 | } |
James Robinson | 060f2e3 | 2014-09-10 22:31:37 | [diff] [blame] | 546 | } |
tfarina | 10ae51f6 | 2015-05-13 03:35:57 | [diff] [blame] | 547 | |
tfarina | 795e01a | 2015-05-15 19:29:57 | [diff] [blame] | 548 | if (is_win) { |
brettw | 0d3b1df | 2015-12-03 00:10:01 | [diff] [blame] | 549 | executable("content_shell_crash_service") { |
tfarina | 795e01a | 2015-05-15 19:29:57 | [diff] [blame] | 550 | sources = [ |
| 551 | "tools/content_shell_crash_service.cc", |
| 552 | ] |
| 553 | |
| 554 | deps = [ |
| 555 | "//base", |
brettw | ba7a73d | 2015-08-31 22:17:39 | [diff] [blame] | 556 | "//build/config/sanitizers:deps", |
brucedawson | f9f7d629 | 2016-04-27 19:11:07 | [diff] [blame] | 557 | "//build/win:default_exe_manifest", |
sdefresne | 8ba0b88c | 2015-09-18 10:33:13 | [diff] [blame] | 558 | "//components/crash/content/tools:crash_service", |
tfarina | 795e01a | 2015-05-15 19:29:57 | [diff] [blame] | 559 | ] |
| 560 | |
| 561 | configs -= [ "//build/config/win:console" ] |
| 562 | configs += [ "//build/config/win:windowed" ] |
| 563 | } |
sebmarchand | a2df339 | 2016-07-13 15:34:59 | [diff] [blame] | 564 | |
| 565 | if (is_syzyasan) { |
| 566 | syzygy_asan("content_shell_syzyasan") { |
| 567 | binary_name = "content_shell.exe" |
| 568 | dest_dir = "$root_out_dir/syzygy" |
| 569 | deps = [ |
| 570 | "//content/shell:content_shell", |
| 571 | ] |
| 572 | testonly = true |
| 573 | } |
| 574 | } |
tfarina | 795e01a | 2015-05-15 19:29:57 | [diff] [blame] | 575 | } |
brettw | e1d4065 | 2015-10-23 23:06:10 | [diff] [blame] | 576 | |
| 577 | if (is_mac) { |
rsesek | 7f9d12b | 2016-04-29 02:45:56 | [diff] [blame] | 578 | mac_xib_bundle_data("content_shell_framework_xibs") { |
| 579 | sources = [ |
| 580 | "app/English.lproj/HttpAuth.xib", |
| 581 | "app/English.lproj/MainMenu.xib", |
| 582 | ] |
| 583 | output_path = "{{bundle_resources_dir}}/English.lproj" |
| 584 | } |
| 585 | |
| 586 | bundle_data("content_shell_framework_resources") { |
| 587 | sources = [ |
| 588 | "$root_out_dir/content_shell.pak", |
rsesek | 7f9d12b | 2016-04-29 02:45:56 | [diff] [blame] | 589 | "resources/missingImage.png", |
| 590 | "resources/textAreaResizeCorner.png", |
| 591 | ] |
| 592 | |
| 593 | public_deps = [ |
| 594 | ":pak", |
| 595 | ] |
| 596 | |
jshin | 359df9c9 | 2016-07-30 06:59:49 | [diff] [blame] | 597 | if (icu_use_data_file) { |
| 598 | sources += [ "$root_out_dir/icudtl.dat" ] |
| 599 | deps = [ |
| 600 | "//third_party/icu:icudata", |
| 601 | ] |
| 602 | } |
rsesek | 7f9d12b | 2016-04-29 02:45:56 | [diff] [blame] | 603 | |
| 604 | if (v8_use_external_startup_data) { |
| 605 | sources += [ |
| 606 | "$root_out_dir/natives_blob.bin", |
| 607 | "$root_out_dir/snapshot_blob.bin", |
| 608 | ] |
| 609 | public_deps += [ "//v8" ] |
| 610 | } |
| 611 | |
| 612 | outputs = [ |
| 613 | "{{bundle_resources_dir}}/{{source_file_part}}", |
| 614 | ] |
| 615 | } |
| 616 | |
| 617 | if (enable_plugins) { |
| 618 | bundle_data("content_shell_framework_plugins") { |
| 619 | sources = [ |
| 620 | "$root_out_dir/blink_deprecated_test_plugin.plugin", |
| 621 | "$root_out_dir/blink_test_plugin.plugin", |
| 622 | ] |
| 623 | |
| 624 | outputs = [ |
| 625 | "{{bundle_root_dir}}/{{source_file_part}}", |
| 626 | ] |
| 627 | |
| 628 | public_deps = [ |
| 629 | "//ppapi:blink_deprecated_test_plugin", |
| 630 | "//ppapi:blink_test_plugin", |
| 631 | ] |
| 632 | } |
| 633 | } |
| 634 | |
| 635 | content_shell_framework_name = "$content_shell_product_name Framework" |
| 636 | content_shell_helper_name = "$content_shell_product_name Helper" |
| 637 | |
rsesek | 90112aa6 | 2016-05-03 17:33:36 | [diff] [blame] | 638 | tweak_info_plist("content_shell_framework_plist") { |
| 639 | testonly = true |
| 640 | info_plist = "app/framework-Info.plist" |
| 641 | args = [ |
mark | 8ecf788 | 2016-08-02 17:46:32 | [diff] [blame] | 642 | "--breakpad=0", |
rsesek | 90112aa6 | 2016-05-03 17:33:36 | [diff] [blame] | 643 | "--keystone=0", |
| 644 | "--scm=1", |
| 645 | "--version", |
| 646 | content_shell_version, |
| 647 | "--branding", |
| 648 | content_shell_product_name, |
| 649 | ] |
| 650 | } |
| 651 | |
rsesek | 7f9d12b | 2016-04-29 02:45:56 | [diff] [blame] | 652 | mac_framework_bundle("content_shell_framework") { |
brettw | e1d4065 | 2015-10-23 23:06:10 | [diff] [blame] | 653 | testonly = true |
| 654 | |
rsesek | 7f9d12b | 2016-04-29 02:45:56 | [diff] [blame] | 655 | output_name = content_shell_framework_name |
brettw | e1d4065 | 2015-10-23 23:06:10 | [diff] [blame] | 656 | |
| 657 | sources = [ |
tfarina | c708f397 | 2015-10-25 17:42:50 | [diff] [blame] | 658 | "app/shell_content_main.cc", |
| 659 | "app/shell_content_main.h", |
brettw | e1d4065 | 2015-10-23 23:06:10 | [diff] [blame] | 660 | ] |
| 661 | |
rsesek | 7f9d12b | 2016-04-29 02:45:56 | [diff] [blame] | 662 | # TODO(rsesek): Handle these missing pieces: |
| 663 | # - crash_inspector |
| 664 | # - crash_report_sender.app |
| 665 | |
brettw | 6b0712a | 2016-07-15 17:48:20 | [diff] [blame] | 666 | public_deps = [ |
| 667 | ":content_shell_lib", |
| 668 | ] |
brettw | e1d4065 | 2015-10-23 23:06:10 | [diff] [blame] | 669 | deps = [ |
rsesek | 7f9d12b | 2016-04-29 02:45:56 | [diff] [blame] | 670 | ":content_shell_framework_resources", |
| 671 | ":content_shell_framework_xibs", |
rsesek | 7f9d12b | 2016-04-29 02:45:56 | [diff] [blame] | 672 | "//third_party/icu:icudata", |
brettw | e1d4065 | 2015-10-23 23:06:10 | [diff] [blame] | 673 | ] |
rsesek | 7f9d12b | 2016-04-29 02:45:56 | [diff] [blame] | 674 | |
| 675 | if (enable_plugins) { |
| 676 | deps += [ ":content_shell_framework_plugins" ] |
| 677 | } |
| 678 | |
rsesek | 6a8a5d0 | 2016-06-21 01:16:18 | [diff] [blame] | 679 | # Both the main :content_shell and :content_shell_helper_app executables |
| 680 | # need to link the framework. Because they are at different directory |
| 681 | # depths, using @executable_path as the install_name would require using |
| 682 | # install_name_tool on one of the executables. However install_name_tool |
| 683 | # only operates in-place, which is problematic to express in GN. Instead, |
| 684 | # use rpath-based loading. |
| 685 | # TODO(rsesek): After GYP is gone, re-write content_shell_main to be like |
| 686 | # chrome_main and use dlopen() instead of a linked framework. |
| 687 | ldflags = [ "-Wl,-install_name,@rpath/Frameworks/$output_name.framework/$output_name" ] |
| 688 | |
| 689 | if (is_component_build) { |
| 690 | # Set up the rpath for the framework so that it can find dylibs in the |
| 691 | # root output directory. The framework is at |
| 692 | # Content Shell.app/Contents/Frameworks/Content Shell Framework.framework/Content Shell Framework |
| 693 | # so use loader_path to go back to the root output directory. |
| 694 | ldflags += [ |
| 695 | "-rpath", |
| 696 | "@loader_path/../../../..", |
| 697 | ] |
| 698 | } |
rsesek | 7f9d12b | 2016-04-29 02:45:56 | [diff] [blame] | 699 | |
rsesek | 90112aa6 | 2016-05-03 17:33:36 | [diff] [blame] | 700 | info_plist_target = ":content_shell_framework_plist" |
| 701 | } |
| 702 | |
| 703 | tweak_info_plist("content_shell_helper_plist") { |
| 704 | testonly = true |
| 705 | info_plist = "app/helper-Info.plist" |
| 706 | args = [ |
| 707 | "--breakpad=0", |
| 708 | "--keystone=0", |
| 709 | "--scm=0", |
| 710 | "--version", |
| 711 | content_shell_version, |
| 712 | ] |
brettw | e1d4065 | 2015-10-23 23:06:10 | [diff] [blame] | 713 | } |
rsesek | 20a58a6 | 2016-04-15 20:59:23 | [diff] [blame] | 714 | |
| 715 | mac_app_bundle("content_shell_helper_app") { |
| 716 | testonly = true |
rsesek | 7f9d12b | 2016-04-29 02:45:56 | [diff] [blame] | 717 | output_name = content_shell_helper_name |
rsesek | 20a58a6 | 2016-04-15 20:59:23 | [diff] [blame] | 718 | sources = [ |
| 719 | "app/shell_main.cc", |
| 720 | ] |
| 721 | deps = [ |
rsesek | 7f9d12b | 2016-04-29 02:45:56 | [diff] [blame] | 722 | ":content_shell_framework+link", |
rsesek | 1cfe20c3 | 2016-07-27 17:44:51 | [diff] [blame] | 723 | "//build/config/sanitizers:deps", |
rsesek | 20a58a6 | 2016-04-15 20:59:23 | [diff] [blame] | 724 | ] |
rsesek | 02aa51c | 2016-05-11 02:13:57 | [diff] [blame] | 725 | ldflags = [ |
| 726 | # The helper is in Content Shell.app/Contents/Frameworks/Content Shell Helper.app/Contents/MacOS/ |
rsesek | 6a8a5d0 | 2016-06-21 01:16:18 | [diff] [blame] | 727 | # so set rpath up to Contents/ so that the loader can find Frameworks/. |
rsesek | 02aa51c | 2016-05-11 02:13:57 | [diff] [blame] | 728 | "-rpath", |
rsesek | 6a8a5d0 | 2016-06-21 01:16:18 | [diff] [blame] | 729 | "@executable_path/../../../..", |
rsesek | 02aa51c | 2016-05-11 02:13:57 | [diff] [blame] | 730 | ] |
rsesek | 90112aa6 | 2016-05-03 17:33:36 | [diff] [blame] | 731 | info_plist_target = ":content_shell_helper_plist" |
rsesek | 20a58a6 | 2016-04-15 20:59:23 | [diff] [blame] | 732 | } |
rsesek | 7f9d12b | 2016-04-29 02:45:56 | [diff] [blame] | 733 | |
rsesek | 7f9d12b | 2016-04-29 02:45:56 | [diff] [blame] | 734 | bundle_data("content_shell_framework_bundle_data") { |
| 735 | testonly = true |
| 736 | sources = [ |
| 737 | "$root_out_dir/$content_shell_framework_name.framework", |
| 738 | "$root_out_dir/$content_shell_helper_name.app", |
| 739 | ] |
| 740 | outputs = [ |
| 741 | "{{bundle_root_dir}}/Frameworks/{{source_file_part}}", |
| 742 | ] |
| 743 | public_deps = [ |
| 744 | ":content_shell_framework+link", |
rsesek | 6a8a5d0 | 2016-06-21 01:16:18 | [diff] [blame] | 745 | ":content_shell_helper_app", |
rsesek | 7f9d12b | 2016-04-29 02:45:56 | [diff] [blame] | 746 | ] |
| 747 | } |
| 748 | |
| 749 | bundle_data("content_shell_resources_bundle_data") { |
| 750 | testonly = true |
| 751 | sources = [ |
| 752 | "app/app.icns", |
| 753 | ] |
| 754 | outputs = [ |
| 755 | "{{bundle_resources_dir}}/{{source_file_part}}", |
| 756 | ] |
| 757 | } |
brettw | e1d4065 | 2015-10-23 23:06:10 | [diff] [blame] | 758 | } |
ortuno | f78c841 | 2016-03-31 18:59:59 | [diff] [blame] | 759 | |
| 760 | mojom("mojo_bindings") { |
| 761 | sources = [ |
jiameng | d518643 | 2017-02-08 01:48:22 | [diff] [blame] | 762 | "common/layout_test.mojom", |
ortuno | f78c841 | 2016-03-31 18:59:59 | [diff] [blame] | 763 | "common/layout_test/layout_test_bluetooth_fake_adapter_setter.mojom", |
| 764 | ] |
jiameng | d518643 | 2017-02-08 01:48:22 | [diff] [blame] | 765 | public_deps = [ |
| 766 | "//mojo/common:common_custom_types", |
| 767 | "//ui/gfx/geometry/mojo", |
| 768 | "//url/mojo:url_mojom_gurl", |
| 769 | ] |
ortuno | f78c841 | 2016-03-31 18:59:59 | [diff] [blame] | 770 | } |
jochen | 0426747e | 2017-02-09 17:01:19 | [diff] [blame] | 771 | |
| 772 | group("content_shell_crash_test") { |
| 773 | testonly = true |
| 774 | data_deps = [ |
| 775 | ":content_shell", |
| 776 | "//third_party/mesa:osmesa", |
| 777 | ] |
| 778 | data = [ |
| 779 | "//content/shell/tools/breakpad_integration_test.py", |
| 780 | "//testing/scripts/common.py", |
| 781 | "//testing/scripts/content_shell_crash_test.py", |
| 782 | "//testing/xvfb.py", |
| 783 | ] |
| 784 | if (is_posix) { |
| 785 | data += [ |
| 786 | "//components/crash/content/tools/generate_breakpad_symbols.py", |
| 787 | "//components/crash/content/tools/dmp2minidump.py", |
| 788 | ] |
| 789 | } |
| 790 | if (is_win) { |
| 791 | data_deps += [ ":content_shell_crash_service" ] |
| 792 | } |
| 793 | if (is_posix && !is_android) { |
| 794 | data_deps += [ |
| 795 | "//breakpad:dump_syms($host_toolchain)", |
| 796 | "//breakpad:minidump_stackwalk($host_toolchain)", |
| 797 | ] |
| 798 | } |
| 799 | if (is_android) { |
| 800 | data_deps += [ |
| 801 | "//breakpad:dump_syms", |
| 802 | "//breakpad:microdump_stackwalk", |
| 803 | "//breakpad:minidump_dump", |
| 804 | "//breakpad:minidump_stackwalk", |
| 805 | "//breakpad:symupload", |
| 806 | "//tools/android/forwarder2", |
| 807 | ] |
| 808 | } |
| 809 | } |