[email protected] | 81f30ce | 2012-01-18 22:10:33 | [diff] [blame] | 1 | # Copyright (c) 2012 The Chromium Authors. All rights reserved. |
[email protected] | 5629e0c | 2011-09-12 22:07:36 | [diff] [blame] | 2 | # Use of this source code is governed by a BSD-style license that can be |
| 3 | # found in the LICENSE file. |
| 4 | |
| 5 | { |
[email protected] | 85ff1604 | 2012-03-06 23:46:34 | [diff] [blame] | 6 | 'variables': { |
| 7 | 'content_shell_product_name': 'Content Shell', |
| 8 | }, |
[email protected] | 5629e0c | 2011-09-12 22:07:36 | [diff] [blame] | 9 | 'targets': [ |
| 10 | { |
[email protected] | c1f87b2 | 2011-10-05 21:59:33 | [diff] [blame] | 11 | 'target_name': 'content_shell_lib', |
| 12 | 'type': 'static_library', |
[email protected] | 03ff5e5 | 2011-09-30 00:28:14 | [diff] [blame] | 13 | 'defines!': ['CONTENT_IMPLEMENTATION'], |
[email protected] | 9fbd3f86 | 2011-09-20 23:31:34 | [diff] [blame] | 14 | 'variables': { |
| 15 | 'chromium_code': 1, |
| 16 | }, |
[email protected] | 5629e0c | 2011-09-12 22:07:36 | [diff] [blame] | 17 | 'dependencies': [ |
| 18 | 'content_app', |
| 19 | 'content_browser', |
| 20 | 'content_common', |
| 21 | 'content_gpu', |
| 22 | 'content_plugin', |
| 23 | 'content_ppapi_plugin', |
| 24 | 'content_renderer', |
[email protected] | ee75b899 | 2012-01-27 07:53:57 | [diff] [blame] | 25 | 'content_shell_resources', |
[email protected] | 5629e0c | 2011-09-12 22:07:36 | [diff] [blame] | 26 | 'content_utility', |
| 27 | 'content_worker', |
[email protected] | 0faa0a2b | 2011-11-15 18:03:14 | [diff] [blame] | 28 | 'content_resources.gyp:content_resources', |
[email protected] | aa6e7976 | 2011-09-29 20:53:52 | [diff] [blame] | 29 | '../base/base.gyp:base', |
| 30 | '../base/third_party/dynamic_annotations/dynamic_annotations.gyp:dynamic_annotations', |
| 31 | '../build/temp_gyp/googleurl.gyp:googleurl', |
| 32 | '../ipc/ipc.gyp:ipc', |
[email protected] | 433df47 | 2012-03-07 20:33:39 | [diff] [blame] | 33 | '../media/media.gyp:media', |
[email protected] | aa6e7976 | 2011-09-29 20:53:52 | [diff] [blame] | 34 | '../net/net.gyp:net', |
[email protected] | 5629e0c | 2011-09-12 22:07:36 | [diff] [blame] | 35 | '../skia/skia.gyp:skia', |
[email protected] | ee582a5 | 2012-05-22 07:38:52 | [diff] [blame] | 36 | '<(webkit_src_dir)/Source/WebKit/chromium/WebKit.gyp:webkit', |
[email protected] | 5629e0c | 2011-09-12 22:07:36 | [diff] [blame] | 37 | '../ui/ui.gyp:ui', |
[email protected] | 12bc28fcb | 2011-09-21 15:53:50 | [diff] [blame] | 38 | '../v8/tools/gyp/v8.gyp:v8', |
[email protected] | 0104871 | 2012-07-09 23:26:27 | [diff] [blame] | 39 | '../webkit/support/webkit_support.gyp:webkit_support', |
[email protected] | 5629e0c | 2011-09-12 22:07:36 | [diff] [blame] | 40 | ], |
| 41 | 'include_dirs': [ |
| 42 | '..', |
| 43 | ], |
| 44 | 'sources': [ |
[email protected] | 6cfccd1 | 2012-06-28 12:14:05 | [diff] [blame] | 45 | 'shell/geolocation/shell_access_token_store.cc', |
| 46 | 'shell/geolocation/shell_access_token_store.h', |
[email protected] | cccb5cf | 2012-06-06 22:20:04 | [diff] [blame] | 47 | 'shell/layout_test_controller.cc', |
| 48 | 'shell/layout_test_controller.h', |
[email protected] | 74830f0 | 2012-01-30 22:27:04 | [diff] [blame] | 49 | 'shell/layout_test_controller_bindings.cc', |
| 50 | 'shell/layout_test_controller_bindings.h', |
[email protected] | cccb5cf | 2012-06-06 22:20:04 | [diff] [blame] | 51 | 'shell/layout_test_controller_host.cc', |
| 52 | 'shell/layout_test_controller_host.h', |
[email protected] | e1aff17 | 2012-03-22 22:41:17 | [diff] [blame] | 53 | 'shell/paths_mac.h', |
| 54 | 'shell/paths_mac.mm', |
[email protected] | 9fbd3f86 | 2011-09-20 23:31:34 | [diff] [blame] | 55 | 'shell/shell.cc', |
| 56 | 'shell/shell.h', |
[email protected] | a08029b4 | 2012-04-25 03:18:46 | [diff] [blame] | 57 | 'shell/shell_android.cc', |
[email protected] | fa4a4583 | 2012-04-12 21:32:48 | [diff] [blame] | 58 | 'shell/shell_aura.cc', |
[email protected] | 9fbd3f86 | 2011-09-20 23:31:34 | [diff] [blame] | 59 | 'shell/shell_gtk.cc', |
| 60 | 'shell/shell_mac.mm', |
| 61 | 'shell/shell_win.cc', |
[email protected] | c4e78d7 | 2012-03-24 22:55:41 | [diff] [blame] | 62 | 'shell/shell_application_mac.h', |
| 63 | 'shell/shell_application_mac.mm', |
[email protected] | b0f146f | 2011-09-15 22:14:25 | [diff] [blame] | 64 | 'shell/shell_browser_context.cc', |
| 65 | 'shell/shell_browser_context.h', |
[email protected] | 5629e0c | 2011-09-12 22:07:36 | [diff] [blame] | 66 | 'shell/shell_browser_main.cc', |
| 67 | 'shell/shell_browser_main.h', |
[email protected] | 147f809 | 2012-03-21 11:47:45 | [diff] [blame] | 68 | 'shell/shell_browser_main_parts.cc', |
| 69 | 'shell/shell_browser_main_parts.h', |
| 70 | 'shell/shell_browser_main_parts_mac.mm', |
[email protected] | 5629e0c | 2011-09-12 22:07:36 | [diff] [blame] | 71 | 'shell/shell_content_browser_client.cc', |
| 72 | 'shell/shell_content_browser_client.h', |
| 73 | 'shell/shell_content_client.cc', |
| 74 | 'shell/shell_content_client.h', |
[email protected] | 5629e0c | 2011-09-12 22:07:36 | [diff] [blame] | 75 | 'shell/shell_content_renderer_client.cc', |
| 76 | 'shell/shell_content_renderer_client.h', |
[email protected] | ee75b899 | 2012-01-27 07:53:57 | [diff] [blame] | 77 | 'shell/shell_devtools_delegate.cc', |
| 78 | 'shell/shell_devtools_delegate.h', |
[email protected] | 98d6f15 | 2011-09-29 19:35:51 | [diff] [blame] | 79 | 'shell/shell_download_manager_delegate.cc', |
| 80 | 'shell/shell_download_manager_delegate.h', |
[email protected] | f221002 | 2012-03-29 00:36:08 | [diff] [blame] | 81 | 'shell/shell_javascript_dialog_creator.cc', |
| 82 | 'shell/shell_javascript_dialog_creator.h', |
| 83 | 'shell/shell_javascript_dialog_mac.mm', |
[email protected] | 7fc8382 | 2012-03-30 19:53:29 | [diff] [blame] | 84 | 'shell/shell_javascript_dialog_win.cc', |
[email protected] | f221002 | 2012-03-29 00:36:08 | [diff] [blame] | 85 | 'shell/shell_javascript_dialog.h', |
[email protected] | e3503ac | 2012-04-05 15:01:36 | [diff] [blame] | 86 | 'shell/shell_login_dialog_mac.mm', |
| 87 | 'shell/shell_login_dialog.cc', |
| 88 | 'shell/shell_login_dialog.h', |
[email protected] | c1f87b2 | 2011-10-05 21:59:33 | [diff] [blame] | 89 | 'shell/shell_main_delegate.cc', |
| 90 | 'shell/shell_main_delegate.h', |
[email protected] | efb5f57 | 2012-01-29 10:57:33 | [diff] [blame] | 91 | 'shell/shell_messages.cc', |
| 92 | 'shell/shell_messages.h', |
[email protected] | 33bc283 | 2012-03-29 08:18:17 | [diff] [blame] | 93 | 'shell/shell_network_delegate.cc', |
| 94 | 'shell/shell_network_delegate.h', |
[email protected] | 74830f0 | 2012-01-30 22:27:04 | [diff] [blame] | 95 | 'shell/shell_render_process_observer.cc', |
| 96 | 'shell/shell_render_process_observer.h', |
[email protected] | c5f1e33 | 2011-09-27 01:08:03 | [diff] [blame] | 97 | 'shell/shell_resource_context.cc', |
| 98 | 'shell/shell_resource_context.h', |
[email protected] | e3503ac | 2012-04-05 15:01:36 | [diff] [blame] | 99 | 'shell/shell_resource_dispatcher_host_delegate.cc', |
| 100 | 'shell/shell_resource_dispatcher_host_delegate.h', |
[email protected] | efb5f57 | 2012-01-29 10:57:33 | [diff] [blame] | 101 | 'shell/shell_switches.cc', |
| 102 | 'shell/shell_switches.h', |
[email protected] | c5f1e33 | 2011-09-27 01:08:03 | [diff] [blame] | 103 | 'shell/shell_url_request_context_getter.cc', |
| 104 | 'shell/shell_url_request_context_getter.h', |
[email protected] | 5629e0c | 2011-09-12 22:07:36 | [diff] [blame] | 105 | ], |
| 106 | 'msvs_settings': { |
| 107 | 'VCLinkerTool': { |
| 108 | 'SubSystem': '2', # Set /SUBSYSTEM:WINDOWS |
| 109 | }, |
| 110 | }, |
| 111 | 'conditions': [ |
| 112 | ['OS=="win" and win_use_allocator_shim==1', { |
| 113 | 'dependencies': [ |
| 114 | '../base/allocator/allocator.gyp:allocator', |
| 115 | ], |
| 116 | }], |
[email protected] | 9fbd3f86 | 2011-09-20 23:31:34 | [diff] [blame] | 117 | ['OS=="win"', { |
| 118 | 'resource_include_dirs': [ |
| 119 | '<(SHARED_INTERMEDIATE_DIR)/webkit', |
| 120 | ], |
[email protected] | 9fbd3f86 | 2011-09-20 23:31:34 | [diff] [blame] | 121 | 'dependencies': [ |
[email protected] | 9fbd3f86 | 2011-09-20 23:31:34 | [diff] [blame] | 122 | '<(DEPTH)/webkit/support/webkit_support.gyp:webkit_resources', |
| 123 | '<(DEPTH)/webkit/support/webkit_support.gyp:webkit_strings', |
| 124 | ], |
| 125 | 'configurations': { |
| 126 | 'Debug_Base': { |
| 127 | 'msvs_settings': { |
| 128 | 'VCLinkerTool': { |
| 129 | 'LinkIncremental': '<(msvs_large_module_debug_link_mode)', |
| 130 | }, |
| 131 | }, |
| 132 | }, |
| 133 | }, |
[email protected] | 85ff1604 | 2012-03-06 23:46:34 | [diff] [blame] | 134 | }], # OS=="win" |
[email protected] | a08029b4 | 2012-04-25 03:18:46 | [diff] [blame] | 135 | ['OS!="android"', { |
| 136 | 'dependencies': [ |
| 137 | # This dependency is for running DRT against the content shell, and |
| 138 | # this combination is not yet supported on Android. |
| 139 | '../webkit/support/webkit_support.gyp:webkit_support', |
| 140 | ], |
[email protected] | 82e9e2b1 | 2012-07-19 00:32:01 | [diff] [blame^] | 141 | }, { # else: OS=="android" |
| 142 | 'dependencies': [ |
| 143 | 'content_shell_jni_headers', |
| 144 | ], |
| 145 | 'include_dirs': [ |
| 146 | '<(SHARED_INTERMEDIATE_DIR)/content/shell', |
| 147 | ], |
| 148 | }], # OS=="android" |
[email protected] | fa4a4583 | 2012-04-12 21:32:48 | [diff] [blame] | 149 | ['use_aura==1', { |
| 150 | 'sources/': [ |
| 151 | ['exclude', 'shell/shell_gtk.cc'], |
| 152 | ['exclude', 'shell/shell_win.cc'], |
| 153 | ], |
[email protected] | 96b80b47 | 2012-07-03 19:41:56 | [diff] [blame] | 154 | }], # use_aura==1 |
| 155 | ['inside_chromium_build==0 or component!="shared_library"', { |
| 156 | 'dependencies': [ |
| 157 | '<(webkit_src_dir)/Source/WebCore/WebCore.gyp/WebCore.gyp:webcore_test_support', |
| 158 | '<(webkit_src_dir)/Source/WTF/WTF.gyp/WTF.gyp:wtf', |
| 159 | ], |
| 160 | 'include_dirs': [ |
| 161 | # Required for WebTestingSupport.cpp to find our custom config.h. |
| 162 | 'shell/', |
| 163 | '<(webkit_src_dir)/Source/WebKit/chromium/public', |
| 164 | # WARNING: Do not view this particular case as a precedent for |
| 165 | # including WebCore headers in the content shell. |
| 166 | '<(webkit_src_dir)/Source/WebCore/testing/v8', # for WebCoreTestSupport.h needed to link in window.internals code. |
| 167 | ], |
| 168 | 'sources': [ |
| 169 | 'shell/config.h', |
| 170 | '<(webkit_src_dir)/Source/WebKit/chromium/src/WebTestingSupport.cpp', |
| 171 | '<(webkit_src_dir)/Source/WebKit/chromium/public/WebTestingSupport.h', |
| 172 | ], |
[email protected] | fa4a4583 | 2012-04-12 21:32:48 | [diff] [blame] | 173 | }], |
[email protected] | 5629e0c | 2011-09-12 22:07:36 | [diff] [blame] | 174 | ], |
| 175 | }, |
[email protected] | c1f87b2 | 2011-10-05 21:59:33 | [diff] [blame] | 176 | { |
[email protected] | ee75b899 | 2012-01-27 07:53:57 | [diff] [blame] | 177 | 'target_name': 'content_shell_resources', |
| 178 | 'type': 'none', |
[email protected] | b581eb40 | 2012-03-09 01:31:46 | [diff] [blame] | 179 | 'dependencies': [ |
| 180 | 'generate_content_shell_resources', |
| 181 | ], |
| 182 | 'variables': { |
| 183 | 'grit_out_dir': '<(SHARED_INTERMEDIATE_DIR)/content', |
| 184 | }, |
| 185 | 'includes': [ '../build/grit_target.gypi' ], |
| 186 | 'copies': [ |
| 187 | { |
| 188 | 'destination': '<(PRODUCT_DIR)', |
| 189 | 'files': [ |
| 190 | '<(SHARED_INTERMEDIATE_DIR)/content/shell_resources.pak' |
| 191 | ], |
| 192 | }, |
| 193 | ], |
[email protected] | 4cb792f4 | 2012-03-24 03:12:42 | [diff] [blame] | 194 | }, |
| 195 | { |
[email protected] | b581eb40 | 2012-03-09 01:31:46 | [diff] [blame] | 196 | 'target_name': 'generate_content_shell_resources', |
| 197 | 'type': 'none', |
[email protected] | ee75b899 | 2012-01-27 07:53:57 | [diff] [blame] | 198 | 'variables': { |
| 199 | 'grit_out_dir': '<(SHARED_INTERMEDIATE_DIR)/content', |
| 200 | }, |
| 201 | 'actions': [ |
| 202 | { |
| 203 | 'action_name': 'content_shell_resources', |
| 204 | 'variables': { |
| 205 | 'grit_grd_file': 'shell/shell_resources.grd', |
| 206 | }, |
| 207 | 'includes': [ '../build/grit_action.gypi' ], |
| 208 | }, |
| 209 | ], |
[email protected] | ee75b899 | 2012-01-27 07:53:57 | [diff] [blame] | 210 | }, |
| 211 | { |
[email protected] | 81f30ce | 2012-01-18 22:10:33 | [diff] [blame] | 212 | # We build a minimal set of resources so WebKit in content_shell has |
| 213 | # access to necessary resources. |
| 214 | 'target_name': 'content_shell_pak', |
| 215 | 'type': 'none', |
[email protected] | ee75b899 | 2012-01-27 07:53:57 | [diff] [blame] | 216 | 'dependencies': [ |
| 217 | 'browser/debugger/devtools_resources.gyp:devtools_resources', |
| 218 | 'content_shell_resources', |
[email protected] | 6c3e649 | 2012-02-27 17:07:45 | [diff] [blame] | 219 | '<(DEPTH)/net/net.gyp:net_resources', |
| 220 | '<(DEPTH)/ui/ui.gyp:ui_resources', |
[email protected] | ee75b899 | 2012-01-27 07:53:57 | [diff] [blame] | 221 | ], |
[email protected] | 81f30ce | 2012-01-18 22:10:33 | [diff] [blame] | 222 | 'variables': { |
| 223 | 'repack_path': '<(DEPTH)/tools/grit/grit/format/repack.py', |
| 224 | }, |
| 225 | 'actions': [ |
| 226 | { |
| 227 | 'action_name': 'repack_content_shell_pack', |
| 228 | 'variables': { |
| 229 | 'pak_inputs': [ |
| 230 | '<(SHARED_INTERMEDIATE_DIR)/content/content_resources.pak', |
[email protected] | ee75b899 | 2012-01-27 07:53:57 | [diff] [blame] | 231 | '<(SHARED_INTERMEDIATE_DIR)/content/shell_resources.pak', |
[email protected] | 81f30ce | 2012-01-18 22:10:33 | [diff] [blame] | 232 | '<(SHARED_INTERMEDIATE_DIR)/net/net_resources.pak', |
[email protected] | f8126f5 | 2012-07-18 19:37:49 | [diff] [blame] | 233 | '<(SHARED_INTERMEDIATE_DIR)/ui/ui_resources/ui_resources_standard.pak', |
[email protected] | ee75b899 | 2012-01-27 07:53:57 | [diff] [blame] | 234 | '<(SHARED_INTERMEDIATE_DIR)/webkit/devtools_resources.pak', |
[email protected] | 81f30ce | 2012-01-18 22:10:33 | [diff] [blame] | 235 | '<(SHARED_INTERMEDIATE_DIR)/webkit/webkit_chromium_resources.pak', |
| 236 | '<(SHARED_INTERMEDIATE_DIR)/webkit/webkit_resources.pak', |
| 237 | ], |
[email protected] | 81f30ce | 2012-01-18 22:10:33 | [diff] [blame] | 238 | }, |
| 239 | 'inputs': [ |
| 240 | '<(repack_path)', |
| 241 | '<@(pak_inputs)', |
| 242 | ], |
[email protected] | 81f30ce | 2012-01-18 22:10:33 | [diff] [blame] | 243 | 'action': ['python', '<(repack_path)', '<@(_outputs)', |
| 244 | '<@(pak_inputs)'], |
[email protected] | a08029b4 | 2012-04-25 03:18:46 | [diff] [blame] | 245 | 'conditions': [ |
| 246 | ['OS!="android"', { |
| 247 | 'outputs': [ |
| 248 | '<(PRODUCT_DIR)/content_shell.pak', |
| 249 | ], |
| 250 | }, { |
| 251 | 'outputs': [ |
| 252 | '<(PRODUCT_DIR)/content_shell/assets/content_shell.pak', |
| 253 | ], |
| 254 | }], |
| 255 | ], |
[email protected] | 81f30ce | 2012-01-18 22:10:33 | [diff] [blame] | 256 | }, |
| 257 | ], |
| 258 | }, |
| 259 | { |
[email protected] | c1f87b2 | 2011-10-05 21:59:33 | [diff] [blame] | 260 | 'target_name': 'content_shell', |
| 261 | 'type': 'executable', |
[email protected] | 85ff1604 | 2012-03-06 23:46:34 | [diff] [blame] | 262 | 'mac_bundle': 1, |
[email protected] | c1f87b2 | 2011-10-05 21:59:33 | [diff] [blame] | 263 | 'defines!': ['CONTENT_IMPLEMENTATION'], |
| 264 | 'variables': { |
| 265 | 'chromium_code': 1, |
| 266 | }, |
| 267 | 'dependencies': [ |
| 268 | 'content_shell_lib', |
[email protected] | 81f30ce | 2012-01-18 22:10:33 | [diff] [blame] | 269 | 'content_shell_pak', |
[email protected] | c1f87b2 | 2011-10-05 21:59:33 | [diff] [blame] | 270 | ], |
| 271 | 'include_dirs': [ |
| 272 | '..', |
| 273 | ], |
| 274 | 'sources': [ |
[email protected] | 711f428e | 2012-06-22 02:18:23 | [diff] [blame] | 275 | 'app/startup_helper_win.cc', |
[email protected] | c1f87b2 | 2011-10-05 21:59:33 | [diff] [blame] | 276 | 'shell/shell_main.cc', |
| 277 | ], |
[email protected] | 85ff1604 | 2012-03-06 23:46:34 | [diff] [blame] | 278 | 'mac_bundle_resources': [ |
| 279 | 'shell/mac/app.icns', |
| 280 | 'shell/mac/app-Info.plist', |
| 281 | ], |
| 282 | # TODO(mark): Come up with a fancier way to do this. It should only |
| 283 | # be necessary to list app-Info.plist once, not the three times it is |
| 284 | # listed here. |
| 285 | 'mac_bundle_resources!': [ |
| 286 | 'shell/mac/app-Info.plist', |
| 287 | ], |
| 288 | 'xcode_settings': { |
| 289 | 'INFOPLIST_FILE': 'shell/mac/app-Info.plist', |
| 290 | }, |
[email protected] | c1f87b2 | 2011-10-05 21:59:33 | [diff] [blame] | 291 | 'msvs_settings': { |
| 292 | 'VCLinkerTool': { |
| 293 | 'SubSystem': '2', # Set /SUBSYSTEM:WINDOWS |
| 294 | }, |
| 295 | }, |
| 296 | 'conditions': [ |
| 297 | ['OS=="win" and win_use_allocator_shim==1', { |
| 298 | 'dependencies': [ |
| 299 | '../base/allocator/allocator.gyp:allocator', |
| 300 | ], |
| 301 | }], |
| 302 | ['OS=="win"', { |
[email protected] | 7fc8382 | 2012-03-30 19:53:29 | [diff] [blame] | 303 | 'sources': [ |
| 304 | 'shell/shell.rc', |
| 305 | ], |
[email protected] | c1f87b2 | 2011-10-05 21:59:33 | [diff] [blame] | 306 | 'configurations': { |
| 307 | 'Debug_Base': { |
| 308 | 'msvs_settings': { |
| 309 | 'VCLinkerTool': { |
| 310 | 'LinkIncremental': '<(msvs_large_module_debug_link_mode)', |
| 311 | }, |
| 312 | }, |
| 313 | }, |
| 314 | }, |
[email protected] | 85ff1604 | 2012-03-06 23:46:34 | [diff] [blame] | 315 | }], # OS=="win" |
[email protected] | 27315ce4 | 2011-10-14 01:25:12 | [diff] [blame] | 316 | ['OS == "win" or (toolkit_uses_gtk == 1 and selinux == 0)', { |
| 317 | 'dependencies': [ |
| 318 | '../sandbox/sandbox.gyp:sandbox', |
| 319 | ], |
[email protected] | 85ff1604 | 2012-03-06 23:46:34 | [diff] [blame] | 320 | }], # OS=="win" or (toolkit_uses_gtk == 1 and selinux == 0) |
[email protected] | 39899089 | 2012-01-20 03:25:58 | [diff] [blame] | 321 | ['toolkit_uses_gtk == 1', { |
| 322 | 'dependencies': [ |
| 323 | '<(DEPTH)/build/linux/system.gyp:gtk', |
| 324 | ], |
[email protected] | 85ff1604 | 2012-03-06 23:46:34 | [diff] [blame] | 325 | }], # toolkit_uses_gtk |
| 326 | ['OS=="mac"', { |
| 327 | 'product_name': '<(content_shell_product_name)', |
| 328 | 'dependencies!': [ |
| 329 | 'content_shell_lib', |
| 330 | ], |
| 331 | 'dependencies': [ |
| 332 | 'content_shell_framework', |
[email protected] | 180df8f | 2012-03-09 22:36:10 | [diff] [blame] | 333 | 'content_shell_helper_app', |
| 334 | ], |
| 335 | 'copies': [ |
| 336 | { |
| 337 | 'destination': '<(PRODUCT_DIR)/<(content_shell_product_name).app/Contents/Frameworks', |
| 338 | 'files': [ |
| 339 | '<(PRODUCT_DIR)/<(content_shell_product_name) Helper.app', |
| 340 | ], |
| 341 | }, |
[email protected] | 85ff1604 | 2012-03-06 23:46:34 | [diff] [blame] | 342 | ], |
| 343 | 'postbuilds': [ |
| 344 | { |
| 345 | 'postbuild_name': 'Copy <(content_shell_product_name) Framework.framework', |
| 346 | 'action': [ |
| 347 | '../build/mac/copy_framework_unversioned.sh', |
| 348 | '${BUILT_PRODUCTS_DIR}/<(content_shell_product_name) Framework.framework', |
| 349 | '${BUILT_PRODUCTS_DIR}/${CONTENTS_FOLDER_PATH}/Frameworks', |
| 350 | ], |
| 351 | }, |
| 352 | { |
| 353 | 'postbuild_name': 'Fix Framework Link', |
| 354 | 'action': [ |
| 355 | 'install_name_tool', |
| 356 | '-change', |
| 357 | '/Library/Frameworks/<(content_shell_product_name) Framework.framework/Versions/A/<(content_shell_product_name) Framework', |
| 358 | '@executable_path/../Frameworks/<(content_shell_product_name) Framework.framework/<(content_shell_product_name) Framework', |
| 359 | '${BUILT_PRODUCTS_DIR}/${EXECUTABLE_PATH}' |
| 360 | ], |
| 361 | }, |
| 362 | { |
| 363 | # Modify the Info.plist as needed. |
| 364 | 'postbuild_name': 'Tweak Info.plist', |
| 365 | 'action': ['../build/mac/tweak_info_plist.py', |
[email protected] | 8fcde31f6 | 2012-03-07 06:25:17 | [diff] [blame] | 366 | '--svn=1'], |
[email protected] | 85ff1604 | 2012-03-06 23:46:34 | [diff] [blame] | 367 | }, |
| 368 | { |
[email protected] | 180df8f | 2012-03-09 22:36:10 | [diff] [blame] | 369 | # This postbuid step is responsible for creating the following |
| 370 | # helpers: |
| 371 | # |
| 372 | # Content Shell Helper EH.app and Content Shell Helper NP.app are |
| 373 | # created from Content Shell Helper.app. |
| 374 | # |
| 375 | # The EH helper is marked for an executable heap. The NP helper |
| 376 | # is marked for no PIE (ASLR). |
| 377 | 'postbuild_name': 'Make More Helpers', |
| 378 | 'action': [ |
| 379 | '../build/mac/make_more_helpers.sh', |
| 380 | 'Frameworks', |
| 381 | '<(content_shell_product_name)', |
| 382 | ], |
| 383 | }, |
| 384 | { |
[email protected] | 85ff1604 | 2012-03-06 23:46:34 | [diff] [blame] | 385 | # Make sure there isn't any Objective-C in the shell's |
| 386 | # executable. |
| 387 | 'postbuild_name': 'Verify No Objective-C', |
| 388 | 'action': [ |
| 389 | '../build/mac/verify_no_objc.sh', |
| 390 | ], |
| 391 | }, |
| 392 | ], |
| 393 | }], # OS=="mac" |
[email protected] | c1f87b2 | 2011-10-05 21:59:33 | [diff] [blame] | 394 | ], |
| 395 | }, |
[email protected] | 5629e0c | 2011-09-12 22:07:36 | [diff] [blame] | 396 | ], |
[email protected] | 85ff1604 | 2012-03-06 23:46:34 | [diff] [blame] | 397 | 'conditions': [ |
| 398 | ['OS=="mac"', { |
| 399 | 'targets': [ |
| 400 | { |
| 401 | 'target_name': 'content_shell_framework', |
| 402 | 'type': 'shared_library', |
| 403 | 'product_name': '<(content_shell_product_name) Framework', |
| 404 | 'mac_bundle': 1, |
| 405 | 'mac_bundle_resources': [ |
[email protected] | e3503ac | 2012-04-05 15:01:36 | [diff] [blame] | 406 | 'shell/mac/English.lproj/HttpAuth.xib', |
[email protected] | 85ff1604 | 2012-03-06 23:46:34 | [diff] [blame] | 407 | 'shell/mac/English.lproj/MainMenu.xib', |
[email protected] | 4cb792f4 | 2012-03-24 03:12:42 | [diff] [blame] | 408 | '<(PRODUCT_DIR)/content_shell.pak' |
[email protected] | 85ff1604 | 2012-03-06 23:46:34 | [diff] [blame] | 409 | ], |
| 410 | 'dependencies': [ |
| 411 | 'content_shell_lib', |
| 412 | ], |
| 413 | 'include_dirs': [ |
| 414 | '..', |
| 415 | ], |
| 416 | 'sources': [ |
| 417 | 'shell/shell_content_main.cc', |
| 418 | 'shell/shell_content_main.h', |
| 419 | ], |
[email protected] | 180df8f | 2012-03-09 22:36:10 | [diff] [blame] | 420 | }, # target content_shell_framework |
| 421 | { |
| 422 | 'target_name': 'content_shell_helper_app', |
| 423 | 'type': 'executable', |
| 424 | 'variables': { 'enable_wexit_time_destructors': 1, }, |
| 425 | 'product_name': '<(content_shell_product_name) Helper', |
| 426 | 'mac_bundle': 1, |
| 427 | 'dependencies': [ |
| 428 | 'content_shell_framework', |
| 429 | ], |
| 430 | 'sources': [ |
| 431 | 'shell/shell_main.cc', |
| 432 | 'shell/mac/helper-Info.plist', |
| 433 | ], |
| 434 | # TODO(mark): Come up with a fancier way to do this. It should only |
| 435 | # be necessary to list helper-Info.plist once, not the three times it |
| 436 | # is listed here. |
| 437 | 'mac_bundle_resources!': [ |
| 438 | 'shell/mac/helper-Info.plist', |
| 439 | ], |
| 440 | # TODO(mark): For now, don't put any resources into this app. Its |
| 441 | # resources directory will be a symbolic link to the browser app's |
| 442 | # resources directory. |
| 443 | 'mac_bundle_resources/': [ |
| 444 | ['exclude', '.*'], |
| 445 | ], |
| 446 | 'xcode_settings': { |
| 447 | 'INFOPLIST_FILE': 'shell/mac/helper-Info.plist', |
| 448 | }, |
| 449 | 'postbuilds': [ |
| 450 | { |
| 451 | # The framework defines its load-time path |
| 452 | # (DYLIB_INSTALL_NAME_BASE) relative to the main executable |
| 453 | # (chrome). A different relative path needs to be used in |
| 454 | # content_shell_helper_app. |
| 455 | 'postbuild_name': 'Fix Framework Link', |
| 456 | 'action': [ |
| 457 | 'install_name_tool', |
| 458 | '-change', |
| 459 | '/Library/Frameworks/<(content_shell_product_name) Framework.framework/Versions/A/<(content_shell_product_name) Framework', |
| 460 | '@executable_path/../../../../Frameworks/<(content_shell_product_name) Framework.framework/<(content_shell_product_name) Framework', |
| 461 | '${BUILT_PRODUCTS_DIR}/${EXECUTABLE_PATH}' |
| 462 | ], |
| 463 | }, |
| 464 | { |
| 465 | # Modify the Info.plist as needed. The script explains why this |
| 466 | # is needed. This is also done in the chrome and chrome_dll |
| 467 | # targets. In this case, --breakpad=0, --keystone=0, and --svn=0 |
| 468 | # are used because Breakpad, Keystone, and Subversion keys are |
| 469 | # never placed into the helper. |
| 470 | 'postbuild_name': 'Tweak Info.plist', |
| 471 | 'action': ['../build/mac/tweak_info_plist.py', |
| 472 | '--breakpad=0', |
| 473 | '--keystone=0', |
| 474 | '--svn=0'], |
| 475 | }, |
| 476 | { |
| 477 | # Make sure there isn't any Objective-C in the helper app's |
| 478 | # executable. |
| 479 | 'postbuild_name': 'Verify No Objective-C', |
| 480 | 'action': [ |
| 481 | '../build/mac/verify_no_objc.sh', |
| 482 | ], |
| 483 | }, |
| 484 | ], |
[email protected] | ec40c38f | 2012-06-28 16:37:49 | [diff] [blame] | 485 | 'conditions': [ |
| 486 | ['component=="shared_library"', { |
| 487 | 'xcode_settings': { |
| 488 | 'LD_RUNPATH_SEARCH_PATHS': [ |
| 489 | # Get back from Content Shell.app/Contents/Frameworks/ |
| 490 | # Helper.app/Contents/MacOS |
| 491 | '@loader_path/../../../../../..', |
| 492 | ], |
| 493 | }, |
| 494 | }], |
| 495 | ], |
[email protected] | 180df8f | 2012-03-09 22:36:10 | [diff] [blame] | 496 | }, # target content_shell_helper_app |
[email protected] | 85ff1604 | 2012-03-06 23:46:34 | [diff] [blame] | 497 | ], |
| 498 | }], # OS=="mac" |
[email protected] | cc66d28 | 2012-03-30 11:44:06 | [diff] [blame] | 499 | ['OS=="android"', { |
| 500 | 'targets': [ |
| 501 | { |
[email protected] | a08029b4 | 2012-04-25 03:18:46 | [diff] [blame] | 502 | # TODO(jrg): Update this action and other jni generators to only |
| 503 | # require specifying the java directory and generate the rest. |
| 504 | 'target_name': 'content_shell_jni_headers', |
| 505 | 'type': 'none', |
| 506 | 'variables': { |
| 507 | 'java_sources': [ |
[email protected] | dccbbb1 | 2012-06-26 21:05:56 | [diff] [blame] | 508 | 'shell/android/java/src/org/chromium/content_shell/ShellManager.java', |
[email protected] | 82e9e2b1 | 2012-07-19 00:32:01 | [diff] [blame^] | 509 | 'shell/android/java/src/org/chromium/content_shell/Shell.java', |
[email protected] | a08029b4 | 2012-04-25 03:18:46 | [diff] [blame] | 510 | ], |
| 511 | 'jni_headers': [ |
| 512 | '<(SHARED_INTERMEDIATE_DIR)/content/shell/jni/shell_manager_jni.h', |
[email protected] | 82e9e2b1 | 2012-07-19 00:32:01 | [diff] [blame^] | 513 | '<(SHARED_INTERMEDIATE_DIR)/content/shell/jni/shell_jni.h', |
[email protected] | a08029b4 | 2012-04-25 03:18:46 | [diff] [blame] | 514 | ], |
| 515 | }, |
| 516 | 'includes': [ '../build/jni_generator.gypi' ], |
| 517 | }, |
| 518 | { |
[email protected] | c110158 | 2012-06-25 17:07:18 | [diff] [blame] | 519 | 'target_name': 'libcontent_shell_content_view', |
[email protected] | a08029b4 | 2012-04-25 03:18:46 | [diff] [blame] | 520 | 'type': 'shared_library', |
| 521 | 'dependencies': [ |
| 522 | 'content_shell_jni_headers', |
| 523 | 'content_shell_lib', |
| 524 | 'content_shell_pak', |
| 525 | # Skia is necessary to ensure the dependencies needed by |
| 526 | # WebContents are included. |
| 527 | '../skia/skia.gyp:skia', |
| 528 | '<(DEPTH)/media/media.gyp:player_android', |
| 529 | ], |
| 530 | 'include_dirs': [ |
| 531 | '<(SHARED_INTERMEDIATE_DIR)/content/shell', |
| 532 | ], |
| 533 | 'sources': [ |
| 534 | 'shell/android/shell_library_loader.cc', |
| 535 | 'shell/android/shell_library_loader.h', |
| 536 | 'shell/android/shell_manager.cc', |
| 537 | 'shell/android/shell_manager.h', |
[email protected] | a08029b4 | 2012-04-25 03:18:46 | [diff] [blame] | 538 | ], |
[email protected] | f83a4739 | 2012-07-12 22:15:04 | [diff] [blame] | 539 | 'sources!': [ |
| 540 | 'shell/shell_main.cc', |
| 541 | 'shell/shell_main.h', |
| 542 | ], |
[email protected] | 7abcaa8 | 2012-06-27 17:09:48 | [diff] [blame] | 543 | 'conditions': [ |
| 544 | ['android_build_type==1', { |
| 545 | 'ldflags': [ |
| 546 | '-lgabi++', # For rtti |
| 547 | ], |
| 548 | }], |
| 549 | ], |
[email protected] | a08029b4 | 2012-04-25 03:18:46 | [diff] [blame] | 550 | }, |
| 551 | { |
[email protected] | cc66d28 | 2012-03-30 11:44:06 | [diff] [blame] | 552 | 'target_name': 'content_shell_apk', |
| 553 | 'type': 'none', |
| 554 | 'actions': [ |
| 555 | { |
[email protected] | a08029b4 | 2012-04-25 03:18:46 | [diff] [blame] | 556 | 'action_name': 'copy_base_jar', |
[email protected] | e082556 | 2012-05-10 01:50:47 | [diff] [blame] | 557 | 'inputs': ['<(PRODUCT_DIR)/lib.java/chromium_base.jar'], |
[email protected] | a08029b4 | 2012-04-25 03:18:46 | [diff] [blame] | 558 | 'outputs': ['<(PRODUCT_DIR)/content_shell/java/libs/chromium_base.jar'], |
| 559 | 'action': ['cp', '<@(_inputs)', '<@(_outputs)'], |
| 560 | }, |
| 561 | { |
[email protected] | e082556 | 2012-05-10 01:50:47 | [diff] [blame] | 562 | 'action_name': 'copy_net_jar', |
| 563 | 'inputs': ['<(PRODUCT_DIR)/lib.java/chromium_net.jar'], |
| 564 | 'outputs': ['<(PRODUCT_DIR)/content_shell/java/libs/chromium_net.jar'], |
| 565 | 'action': ['cp', '<@(_inputs)', '<@(_outputs)'], |
| 566 | }, |
| 567 | { |
| 568 | 'action_name': 'copy_media_jar', |
| 569 | 'inputs': ['<(PRODUCT_DIR)/lib.java/chromium_media.jar'], |
| 570 | 'outputs': ['<(PRODUCT_DIR)/content_shell/java/libs/chromium_media.jar'], |
| 571 | 'action': ['cp', '<@(_inputs)', '<@(_outputs)'], |
| 572 | }, |
| 573 | { |
[email protected] | a08029b4 | 2012-04-25 03:18:46 | [diff] [blame] | 574 | 'action_name': 'copy_content_jar', |
[email protected] | e082556 | 2012-05-10 01:50:47 | [diff] [blame] | 575 | 'inputs': ['<(PRODUCT_DIR)/lib.java/chromium_content.jar'], |
[email protected] | a08029b4 | 2012-04-25 03:18:46 | [diff] [blame] | 576 | 'outputs': ['<(PRODUCT_DIR)/content_shell/java/libs/chromium_content.jar'], |
| 577 | 'action': ['cp', '<@(_inputs)', '<@(_outputs)'], |
| 578 | }, |
| 579 | { |
[email protected] | 9c32064 | 2012-05-07 16:25:57 | [diff] [blame] | 580 | 'action_name': 'copy_and_strip_so', |
[email protected] | 73919ea | 2012-04-26 00:48:41 | [diff] [blame] | 581 | 'inputs': ['<(SHARED_LIB_DIR)/libcontent_shell_content_view.so'], |
[email protected] | de5b7a4 | 2012-05-16 06:18:41 | [diff] [blame] | 582 | 'outputs': ['<(PRODUCT_DIR)/content_shell/libs/<(android_app_abi)/libcontent_shell_content_view.so'], |
[email protected] | 9c32064 | 2012-05-07 16:25:57 | [diff] [blame] | 583 | 'action': [ |
| 584 | '<!(/bin/echo -n $STRIP)', |
| 585 | '--strip-unneeded', # All symbols not needed for relocation. |
| 586 | '<@(_inputs)', |
| 587 | '-o', |
[email protected] | c9a433d | 2012-07-12 20:28:45 | [diff] [blame] | 588 | '<@(_outputs)', |
[email protected] | 9c32064 | 2012-05-07 16:25:57 | [diff] [blame] | 589 | ], |
[email protected] | 73919ea | 2012-04-26 00:48:41 | [diff] [blame] | 590 | }, |
| 591 | { |
[email protected] | cc66d28 | 2012-03-30 11:44:06 | [diff] [blame] | 592 | 'action_name': 'content_shell_apk', |
| 593 | 'inputs': [ |
[email protected] | 19bbc47 | 2012-07-14 13:33:34 | [diff] [blame] | 594 | 'shell/android/java/content_shell_apk.xml', |
| 595 | 'shell/android/java/AndroidManifest.xml', |
[email protected] | cc66d28 | 2012-03-30 11:44:06 | [diff] [blame] | 596 | '<!@(find shell/android/java -name "*.java")', |
[email protected] | a08029b4 | 2012-04-25 03:18:46 | [diff] [blame] | 597 | '<!@(find shell/android/res -name "*")', |
| 598 | '<(PRODUCT_DIR)/content_shell/java/libs/chromium_base.jar', |
[email protected] | e082556 | 2012-05-10 01:50:47 | [diff] [blame] | 599 | '<(PRODUCT_DIR)/content_shell/java/libs/chromium_net.jar', |
| 600 | '<(PRODUCT_DIR)/content_shell/java/libs/chromium_media.jar', |
[email protected] | a08029b4 | 2012-04-25 03:18:46 | [diff] [blame] | 601 | '<(PRODUCT_DIR)/content_shell/java/libs/chromium_content.jar', |
[email protected] | f83a4739 | 2012-07-12 22:15:04 | [diff] [blame] | 602 | '<(PRODUCT_DIR)/content_shell/assets/content_shell.pak', |
[email protected] | de5b7a4 | 2012-05-16 06:18:41 | [diff] [blame] | 603 | '<(PRODUCT_DIR)/content_shell/libs/<(android_app_abi)/libcontent_shell_content_view.so', |
[email protected] | cc66d28 | 2012-03-30 11:44:06 | [diff] [blame] | 604 | ], |
| 605 | 'outputs': [ |
| 606 | # Awkwardly, we build a Debug APK even when gyp is in |
| 607 | # Release mode. I don't think it matters (e.g. we're |
| 608 | # probably happy to not codesign) but naming should be |
| 609 | # fixed. |
[email protected] | c9a433d | 2012-07-12 20:28:45 | [diff] [blame] | 610 | '<(PRODUCT_DIR)/content_shell/ContentShell-debug.apk', |
[email protected] | cc66d28 | 2012-03-30 11:44:06 | [diff] [blame] | 611 | ], |
| 612 | 'action': [ |
[email protected] | 19bbc47 | 2012-07-14 13:33:34 | [diff] [blame] | 613 | # Pass the build type to ant. Currently it only assumes |
| 614 | # debug mode in java. Release mode will break the current |
| 615 | # workflow. |
[email protected] | 77da4713 | 2012-07-18 18:32:03 | [diff] [blame] | 616 | # 'shell/content_shell_ant_helper.sh', |
[email protected] | cc66d28 | 2012-03-30 11:44:06 | [diff] [blame] | 617 | 'ant', |
[email protected] | ef7ed7a | 2012-05-29 23:19:13 | [diff] [blame] | 618 | '-DPRODUCT_DIR=<(ant_build_out)', |
[email protected] | de5b7a4 | 2012-05-16 06:18:41 | [diff] [blame] | 619 | '-DAPP_ABI=<(android_app_abi)', |
[email protected] | cc66d28 | 2012-03-30 11:44:06 | [diff] [blame] | 620 | '-buildfile', |
[email protected] | 19bbc47 | 2012-07-14 13:33:34 | [diff] [blame] | 621 | 'shell/android/java/content_shell_apk.xml', |
[email protected] | 77da4713 | 2012-07-18 18:32:03 | [diff] [blame] | 622 | # '<(CONFIGURATION_NAME)', |
[email protected] | cc66d28 | 2012-03-30 11:44:06 | [diff] [blame] | 623 | ] |
| 624 | } |
| 625 | ], |
| 626 | }, |
[email protected] | c9a433d | 2012-07-12 20:28:45 | [diff] [blame] | 627 | { |
| 628 | 'target_name': 'content_shell_test_apk', |
| 629 | 'type': 'none', |
| 630 | 'dependencies': [ |
| 631 | 'content_shell_apk', |
| 632 | ], |
| 633 | 'actions': [ |
| 634 | { |
| 635 | 'action_name': 'content_shell_test_generate_apk', |
| 636 | 'inputs': [ |
| 637 | '<(DEPTH)/content/shell/android/javatests/content_shell_test_apk.xml', |
| 638 | '<(DEPTH)/content/shell/android/javatests/AndroidManifest.xml', |
| 639 | ], |
| 640 | 'outputs': [ |
| 641 | '<(PRODUCT_DIR)/content_shell_test/ContentShellTest-debug.apk', |
| 642 | ], |
| 643 | 'action': [ |
| 644 | 'ant', |
| 645 | '-DPRODUCT_DIR=<(ant_build_out)', |
| 646 | '-DAPP_ABI=<(android_app_abi)', |
| 647 | '-buildfile', |
| 648 | '<(DEPTH)/content/shell/android/javatests/content_shell_test_apk.xml', |
| 649 | ] |
| 650 | } |
| 651 | ], |
| 652 | }, |
[email protected] | cc66d28 | 2012-03-30 11:44:06 | [diff] [blame] | 653 | ], |
| 654 | }], # OS=="android" |
| 655 | ] |
[email protected] | 5629e0c | 2011-09-12 22:07:36 | [diff] [blame] | 656 | } |