| OLD | NEW |
| 1 # Copyright 2014 The Chromium Authors. All rights reserved. | 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 | 2 # Use of this source code is governed by a BSD-style license that can be |
| 3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
| 4 | 4 |
| 5 import("//build/config/features.gni") | 5 import("//build/config/features.gni") |
| 6 import("//build/config/ui.gni") | 6 import("//build/config/ui.gni") |
| 7 import("//extensions/shell/app_shell.gni") | |
| 8 | 7 |
| 9 # Technically, this directory should not depend on files from src/chrome, but | 8 # Technically, this directory should not depend on files from src/chrome, but |
| 10 # that's where the VERSION file is. This should probably all be moved to | 9 # that's where the VERSION file is. This should probably all be moved to |
| 11 # src/build. | 10 # src/build. |
| 12 import("//chrome/version.gni") | 11 import("//chrome/version.gni") |
| 13 import("//testing/test.gni") | 12 import("//testing/test.gni") |
| 14 import("//tools/grit/grit_rule.gni") | 13 import("//tools/grit/grit_rule.gni") |
| 15 | 14 |
| 16 assert(enable_extensions) | 15 assert(enable_extensions) |
| 17 | 16 |
| (...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 57 "//extensions/shell/common/api:extensions_features", | 56 "//extensions/shell/common/api:extensions_features", |
| 58 "//extensions/utility", | 57 "//extensions/utility", |
| 59 "//skia", | 58 "//skia", |
| 60 "//third_party/WebKit/public:blink", | 59 "//third_party/WebKit/public:blink", |
| 61 "//third_party/cld", | 60 "//third_party/cld", |
| 62 "//ui/base", | 61 "//ui/base", |
| 63 "//ui/base/ime", | 62 "//ui/base/ime", |
| 64 "//v8", | 63 "//v8", |
| 65 ] | 64 ] |
| 66 | 65 |
| 67 sources = rebase_path(app_shell_gypi_values.app_shell_lib_sources, | 66 sources = [ |
| 68 ".", | 67 "app/paths_mac.h", |
| 69 "//extensions/shell") | 68 "app/paths_mac.mm", |
| 69 "app/shell_main_delegate.cc", |
| 70 "app/shell_main_delegate.h", |
| 71 "browser/api/identity/identity_api.cc", |
| 72 "browser/api/identity/identity_api.h", |
| 73 "browser/default_shell_browser_main_delegate.cc", |
| 74 "browser/default_shell_browser_main_delegate.h", |
| 75 "browser/desktop_controller.cc", |
| 76 "browser/desktop_controller.h", |
| 77 "browser/media_capture_util.cc", |
| 78 "browser/media_capture_util.h", |
| 79 "browser/shell_app_delegate.cc", |
| 80 "browser/shell_app_delegate.h", |
| 81 "browser/shell_app_view_guest_delegate.cc", |
| 82 "browser/shell_app_view_guest_delegate.h", |
| 83 "browser/shell_app_window_client.cc", |
| 84 "browser/shell_app_window_client.h", |
| 85 "browser/shell_app_window_client_mac.mm", |
| 86 "browser/shell_audio_controller_chromeos.cc", |
| 87 "browser/shell_audio_controller_chromeos.h", |
| 88 "browser/shell_browser_context.cc", |
| 89 "browser/shell_browser_context.h", |
| 90 "browser/shell_browser_context_keyed_service_factories.cc", |
| 91 "browser/shell_browser_context_keyed_service_factories.h", |
| 92 "browser/shell_browser_main_delegate.h", |
| 93 "browser/shell_browser_main_parts.cc", |
| 94 "browser/shell_browser_main_parts.h", |
| 95 "browser/shell_browser_main_parts_mac.h", |
| 96 "browser/shell_browser_main_parts_mac.mm", |
| 97 "browser/shell_content_browser_client.cc", |
| 98 "browser/shell_content_browser_client.h", |
| 99 "browser/shell_desktop_controller_mac.h", |
| 100 "browser/shell_desktop_controller_mac.mm", |
| 101 "browser/shell_device_client.cc", |
| 102 "browser/shell_device_client.h", |
| 103 "browser/shell_display_info_provider.cc", |
| 104 "browser/shell_display_info_provider.h", |
| 105 "browser/shell_extension_host_delegate.cc", |
| 106 "browser/shell_extension_host_delegate.h", |
| 107 "browser/shell_extension_system.cc", |
| 108 "browser/shell_extension_system.h", |
| 109 "browser/shell_extension_system_factory.cc", |
| 110 "browser/shell_extension_system_factory.h", |
| 111 "browser/shell_extension_web_contents_observer.cc", |
| 112 "browser/shell_extension_web_contents_observer.h", |
| 113 "browser/shell_extensions_api_client.cc", |
| 114 "browser/shell_extensions_api_client.h", |
| 115 "browser/shell_extensions_browser_client.cc", |
| 116 "browser/shell_extensions_browser_client.h", |
| 117 "browser/shell_native_app_window.cc", |
| 118 "browser/shell_native_app_window.h", |
| 119 "browser/shell_native_app_window_mac.h", |
| 120 "browser/shell_native_app_window_mac.mm", |
| 121 "browser/shell_network_controller_chromeos.cc", |
| 122 "browser/shell_network_controller_chromeos.h", |
| 123 "browser/shell_network_delegate.cc", |
| 124 "browser/shell_network_delegate.h", |
| 125 "browser/shell_oauth2_token_service.cc", |
| 126 "browser/shell_oauth2_token_service.h", |
| 127 "browser/shell_oauth2_token_service_delegate.cc", |
| 128 "browser/shell_oauth2_token_service_delegate.h", |
| 129 "browser/shell_prefs.cc", |
| 130 "browser/shell_prefs.h", |
| 131 "browser/shell_runtime_api_delegate.cc", |
| 132 "browser/shell_runtime_api_delegate.h", |
| 133 "browser/shell_special_storage_policy.cc", |
| 134 "browser/shell_special_storage_policy.h", |
| 135 "browser/shell_speech_recognition_manager_delegate.cc", |
| 136 "browser/shell_speech_recognition_manager_delegate.h", |
| 137 "browser/shell_update_query_params_delegate.cc", |
| 138 "browser/shell_update_query_params_delegate.h", |
| 139 "browser/shell_url_request_context_getter.cc", |
| 140 "browser/shell_url_request_context_getter.h", |
| 141 "common/shell_content_client.cc", |
| 142 "common/shell_content_client.h", |
| 143 "common/shell_extensions_client.cc", |
| 144 "common/shell_extensions_client.h", |
| 145 "common/switches.cc", |
| 146 "common/switches.h", |
| 147 "renderer/shell_content_renderer_client.cc", |
| 148 "renderer/shell_content_renderer_client.h", |
| 149 "renderer/shell_extensions_renderer_client.cc", |
| 150 "renderer/shell_extensions_renderer_client.h", |
| 151 "utility/shell_content_utility_client.cc", |
| 152 "utility/shell_content_utility_client.h", |
| 153 ] |
| 70 | 154 |
| 71 if (use_aura) { | 155 if (use_aura) { |
| 156 sources += [ |
| 157 "browser/shell_app_window_client_aura.cc", |
| 158 "browser/shell_desktop_controller_aura.cc", |
| 159 "browser/shell_desktop_controller_aura.h", |
| 160 "browser/shell_native_app_window_aura.cc", |
| 161 "browser/shell_native_app_window_aura.h", |
| 162 "browser/shell_screen.cc", |
| 163 "browser/shell_screen.h", |
| 164 ] |
| 72 deps += [ "//ui/wm" ] | 165 deps += [ "//ui/wm" ] |
| 73 | |
| 74 aura_sources = rebase_path(app_shell_gypi_values.app_shell_lib_sources_aura, | |
| 75 ".", | |
| 76 "//extensions/shell") | |
| 77 sources += aura_sources | |
| 78 } | 166 } |
| 79 | 167 |
| 80 if (is_chromeos) { | 168 if (is_chromeos) { |
| 169 sources += [ "browser/api/vpn_provider/vpn_service_factory.cc" ] |
| 81 deps += [ | 170 deps += [ |
| 82 "//chromeos", | 171 "//chromeos", |
| 83 "//ui/chromeos", | 172 "//ui/chromeos", |
| 84 "//ui/display", | 173 "//ui/display", |
| 85 ] | 174 ] |
| 86 chromeos_sources = | |
| 87 rebase_path(app_shell_gypi_values.app_shell_lib_sources_chromeos, | |
| 88 ".", | |
| 89 "//extensions/shell") | |
| 90 sources += chromeos_sources | |
| 91 } | 175 } |
| 92 | 176 |
| 93 if (enable_nacl) { | 177 if (enable_nacl) { |
| 94 sources += [ | 178 sources += [ |
| 95 "browser/shell_nacl_browser_delegate.cc", | 179 "browser/shell_nacl_browser_delegate.cc", |
| 96 "browser/shell_nacl_browser_delegate.h", | 180 "browser/shell_nacl_browser_delegate.h", |
| 97 ] | 181 ] |
| 98 | 182 |
| 99 deps += [ | 183 deps += [ |
| 100 "//components/nacl/browser", | 184 "//components/nacl/browser", |
| 101 "//components/nacl/common", | 185 "//components/nacl/common", |
| 102 "//components/nacl/loader", | 186 "//components/nacl/loader", |
| 103 "//components/nacl/renderer", | 187 "//components/nacl/renderer", |
| 104 "//components/nacl/renderer/plugin:nacl_trusted_plugin", | 188 "//components/nacl/renderer/plugin:nacl_trusted_plugin", |
| 105 ] | 189 ] |
| 106 | 190 |
| 107 if (is_linux) { | 191 if (is_linux) { |
| 108 deps += [ "//components/nacl/loader:nacl_helper" ] | 192 deps += [ "//components/nacl/loader:nacl_helper" ] |
| 109 | 193 |
| 110 if (enable_nacl_nonsfi) { | 194 if (enable_nacl_nonsfi) { |
| 111 deps += [ "//components/nacl/loader:helper_nonsfi" ] | 195 deps += [ "//components/nacl/loader:helper_nonsfi" ] |
| 112 } | 196 } |
| 113 } | 197 } |
| 114 } | 198 } |
| 115 } | 199 } |
| 116 | 200 |
| 117 executable("app_shell") { | 201 executable("app_shell") { |
| 118 # testonly because :app_shell_lib is testonly. See :app_shell_lib comment. | 202 # testonly because :app_shell_lib is testonly. See :app_shell_lib comment. |
| 119 testonly = true | 203 testonly = true |
| 120 sources = rebase_path(app_shell_gypi_values.app_shell_sources, | 204 sources = [ |
| 121 ".", | 205 "app/shell_main.cc", |
| 122 "//extensions/shell") | 206 ] |
| 207 |
| 123 deps = [ | 208 deps = [ |
| 124 ":app_shell_lib", | 209 ":app_shell_lib", |
| 125 "//build/config/sanitizers:deps", | 210 "//build/config/sanitizers:deps", |
| 126 "//build/win:default_exe_manifest", | 211 "//build/win:default_exe_manifest", |
| 127 "//extensions:shell_and_test_pak", | 212 "//extensions:shell_and_test_pak", |
| 128 ] | 213 ] |
| 129 | 214 |
| 130 if (is_win) { | 215 if (is_win) { |
| 131 configs += [ "//build/config/win:windowed" ] | 216 configs += [ "//build/config/win:windowed" ] |
| 132 configs -= [ "//build/config/win:console" ] | 217 configs -= [ "//build/config/win:console" ] |
| 133 } | 218 } |
| 134 | 219 |
| 135 if (is_mac) { | 220 if (is_mac) { |
| 136 output_name = "App Shell" | 221 output_name = "App Shell" |
| 137 | 222 |
| 138 # TODO(GYP): Mac bundling. See also content_shell which this is basically | 223 # TODO(GYP): Mac bundling. See also content_shell which this is basically |
| 139 # a copy-paste of. | 224 # a copy-paste of. |
| 140 deps += [ ":app_shell_framework" ] | 225 deps += [ ":app_shell_framework" ] |
| 141 | 226 |
| 142 # TODO(GYP): Mac app_shell_helper stuff. | 227 # TODO(GYP): Mac app_shell_helper stuff. |
| 143 } | 228 } |
| 144 } | 229 } |
| 145 | 230 |
| 146 test("app_shell_unittests") { | 231 test("app_shell_unittests") { |
| 147 sources = rebase_path(app_shell_gypi_values.app_shell_unittests_sources, | 232 sources = [ |
| 148 ".", | 233 "../test/extensions_unittests_main.cc", |
| 149 "//extensions/shell") | 234 "browser/api/identity/identity_api_unittest.cc", |
| 235 "browser/shell_oauth2_token_service_unittest.cc", |
| 236 "browser/shell_prefs_unittest.cc", |
| 237 "common/shell_content_client_unittest.cc", |
| 238 ] |
| 150 | 239 |
| 151 data = [ | 240 data = [ |
| 152 "//extensions/test/data/", | 241 "//extensions/test/data/", |
| 153 "$root_out_dir/extensions_shell_and_test.pak", | 242 "$root_out_dir/extensions_shell_and_test.pak", |
| 154 | 243 |
| 155 #"$root_out_dir/natives_blob.bin", # move to gin | 244 #"$root_out_dir/natives_blob.bin", # move to gin |
| 156 #"$root_out_dir/snapshot_blob.bin", | 245 #"$root_out_dir/snapshot_blob.bin", |
| 157 ] | 246 ] |
| 158 | 247 |
| 159 deps = [ | 248 deps = [ |
| 160 ":app_shell_lib", | 249 ":app_shell_lib", |
| 161 "//base", | 250 "//base", |
| 162 "//base/test:test_support", | 251 "//base/test:test_support", |
| 163 "//content/test:test_support", | 252 "//content/test:test_support", |
| 164 "//extensions:shell_and_test_pak", | 253 "//extensions:shell_and_test_pak", |
| 165 "//extensions:test_support", | 254 "//extensions:test_support", |
| 166 "//testing/gtest", | 255 "//testing/gtest", |
| 167 ] | 256 ] |
| 168 | 257 |
| 169 data_deps = [ | 258 data_deps = [ |
| 170 # "//gin", # TODO(dpranke): Either gin or v8 data is needed ... | 259 # "//gin", # TODO(dpranke): Either gin or v8 data is needed ... |
| 171 "//third_party/mesa:osmesa", | 260 "//third_party/mesa:osmesa", |
| 172 ] | 261 ] |
| 173 | 262 |
| 174 if (use_aura) { | 263 if (use_aura) { |
| 264 sources += [ |
| 265 "browser/shell_desktop_controller_aura_unittest.cc", |
| 266 "browser/shell_native_app_window_aura_unittest.cc", |
| 267 "browser/shell_screen_unittest.cc", |
| 268 ] |
| 175 deps += [ "//ui/aura:test_support" ] | 269 deps += [ "//ui/aura:test_support" ] |
| 176 | |
| 177 aura_sources = | |
| 178 rebase_path(app_shell_gypi_values.app_shell_unittests_sources_aura, | |
| 179 ".", | |
| 180 "//extensions/shell") | |
| 181 sources += aura_sources | |
| 182 } | 270 } |
| 183 | 271 |
| 184 if (is_chromeos) { | 272 if (is_chromeos) { |
| 273 sources += [ "browser/shell_audio_controller_chromeos_unittest.cc" ] |
| 185 deps += [ "//chromeos:test_support_without_gmock" ] | 274 deps += [ "//chromeos:test_support_without_gmock" ] |
| 186 | |
| 187 chromeos_sources = | |
| 188 rebase_path(app_shell_gypi_values.app_shell_unittests_sources_chromeos, | |
| 189 ".", | |
| 190 "//extensions/shell") | |
| 191 sources += chromeos_sources | |
| 192 } | 275 } |
| 193 | 276 |
| 194 if (enable_nacl) { | 277 if (enable_nacl) { |
| 195 sources += | 278 sources += [ "browser/shell_nacl_browser_delegate_unittest.cc" ] |
| 196 rebase_path(app_shell_gypi_values.app_shell_unittests_sources_nacl, | |
| 197 ".", | |
| 198 "//extensions/shell") | |
| 199 } | 279 } |
| 200 } | 280 } |
| 201 | 281 |
| 202 process_version("version_header") { | 282 process_version("version_header") { |
| 203 template_file = "common/version.h.in" | 283 template_file = "common/version.h.in" |
| 204 output = "$target_gen_dir/common/version.h" | 284 output = "$target_gen_dir/common/version.h" |
| 205 } | 285 } |
| 206 | 286 |
| 207 if (is_mac) { | 287 if (is_mac) { |
| 208 # TODO(GYP) this should be a bundle. Lots of other stuff in this target. | 288 # TODO(GYP) this should be a bundle. Lots of other stuff in this target. |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 264 "//extensions/browser", | 344 "//extensions/browser", |
| 265 ] | 345 ] |
| 266 | 346 |
| 267 if (is_chromeos) { | 347 if (is_chromeos) { |
| 268 deps += [ | 348 deps += [ |
| 269 "//chromeos:test_support", | 349 "//chromeos:test_support", |
| 270 "//components/keyed_service/content", | 350 "//components/keyed_service/content", |
| 271 ] | 351 ] |
| 272 } | 352 } |
| 273 } | 353 } |
| OLD | NEW |