Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(87)

Side by Side Diff: mojo/runner/BUILD.gn

Issue 1091513005: Separate mojo/shell into a runner and the application manager (shell) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 5 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « mojo/application/BUILD.gn ('k') | mojo/runner/DEPS » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/ui.gni") 5 import("//build/config/ui.gni")
6 import("//third_party/mojo/src/mojo/public/mojo.gni") 6 import("//third_party/mojo/src/mojo/public/mojo.gni")
7 import("//third_party/mojo/src/mojo/public/mojo_application.gni") 7 import("//third_party/mojo/src/mojo/public/mojo_application.gni")
8 import("//third_party/mojo/src/mojo/public/tools/bindings/mojom.gni") 8 import("//third_party/mojo/src/mojo/public/tools/bindings/mojom.gni")
9 import("//testing/test.gni") 9 import("//testing/test.gni")
10 10
11 # We don't support building in the component build since mojo apps are 11 # We don't support building in the component build since mojo apps are
12 # inherently components. 12 # inherently components.
13 assert(!is_component_build) 13 assert(!is_component_build)
14 14
15 group("shell") { 15 group("runner") {
16 testonly = true 16 testonly = true
17 17
18 deps = [ 18 deps = [
19 ":mojo_shell", 19 ":mojo_runner",
20 ":tests", 20 ":tests",
21 "//mojo/shell/application_manager:tests", 21 "//mojo/shell:tests",
22 ] 22 ]
23 23
24 if (is_android) { 24 if (is_android) {
25 deps += [ 25 deps += [
26 ":mojo_shell_apk", 26 ":mojo_runner_apk",
27 ":tests_apk", 27 ":tests_apk",
28 ] 28 ]
29 } 29 }
30 } 30 }
31 31
32 if (is_android) { 32 if (is_android) {
33 import("//build/config/android/config.gni") 33 import("//build/config/android/config.gni")
34 import("//build/config/android/rules.gni") 34 import("//build/config/android/rules.gni")
35 } 35 }
36 36
37 executable("mojo_shell") { 37 executable("mojo_runner") {
38 sources = [] 38 sources = []
39 39
40 deps = [ 40 deps = [
41 ":lib", 41 ":lib",
42 "//base", 42 "//base",
43 "//build/config/sanitizers:deps", 43 "//build/config/sanitizers:deps",
44 "//mojo/common", 44 "//mojo/common",
45 "//mojo/environment:chromium", 45 "//mojo/environment:chromium",
46 ] 46 ]
47 47
(...skipping 10 matching lines...) Expand all
58 "android/main.h", 58 "android/main.h",
59 ] 59 ]
60 60
61 # On android, the executable is also the native library used by the apk. 61 # On android, the executable is also the native library used by the apk.
62 # It means dynamic symbols must be preserved and exported. 62 # It means dynamic symbols must be preserved and exported.
63 ldflags = [ "-Wl,--export-dynamic" ] 63 ldflags = [ "-Wl,--export-dynamic" ]
64 64
65 deps += [ 65 deps += [
66 ":jni_headers", 66 ":jni_headers",
67 "//components/native_viewport:lib", 67 "//components/native_viewport:lib",
68 "//mojo/shell/application_manager", 68 "//mojo/shell",
69 "//ui/gl", 69 "//ui/gl",
70 ] 70 ]
71 } 71 }
72 } 72 }
73 73
74 source_set("in_process_native_runner") { 74 source_set("in_process_native_runner") {
75 sources = [ 75 sources = [
76 "in_process_native_runner.cc", 76 "in_process_native_runner.cc",
77 "in_process_native_runner.h", 77 "in_process_native_runner.h",
78 ] 78 ]
79 79
80 public_deps = [ 80 public_deps = [
81 ":native_application_support", 81 ":native_application_support",
82 "//mojo/shell/application_manager", 82 "//mojo/shell",
83 ] 83 ]
84 84
85 deps = [ 85 deps = [
86 "//base", 86 "//base",
87 ] 87 ]
88 } 88 }
89 89
90 source_set("lib") { 90 source_set("lib") {
91 sources = [ 91 sources = [
92 "child_process.cc", 92 "child_process.cc",
(...skipping 21 matching lines...) Expand all
114 "//base", 114 "//base",
115 "//base/third_party/dynamic_annotations", 115 "//base/third_party/dynamic_annotations",
116 "//base:base_static", 116 "//base:base_static",
117 "//mojo/application", 117 "//mojo/application",
118 "//mojo/common", 118 "//mojo/common",
119 "//mojo/common:tracing_impl", 119 "//mojo/common:tracing_impl",
120 "//third_party/mojo/src/mojo/edk/system", 120 "//third_party/mojo/src/mojo/edk/system",
121 "//third_party/mojo/src/mojo/public/cpp/bindings", 121 "//third_party/mojo/src/mojo/public/cpp/bindings",
122 "//third_party/mojo/src/mojo/public/interfaces/application", 122 "//third_party/mojo/src/mojo/public/interfaces/application",
123 "//mojo/services/network/public/interfaces", 123 "//mojo/services/network/public/interfaces",
124 "//mojo/shell/application_manager", 124 "//mojo/shell",
125 "//mojo/services/tracing:bindings", 125 "//mojo/services/tracing:bindings",
126 "//ui/gl", 126 "//ui/gl",
127 "//url", 127 "//url",
128 ] 128 ]
129 129
130 public_deps = [ 130 public_deps = [
131 ":switches", 131 ":switches",
132 ] 132 ]
133 133
134 if (is_android) { 134 if (is_android) {
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after
254 deps = [ 254 deps = [
255 "//base:base_java", 255 "//base:base_java",
256 ] 256 ]
257 } 257 }
258 258
259 android_resources("resources") { 259 android_resources("resources") {
260 resource_dirs = [ "android/apk/res" ] 260 resource_dirs = [ "android/apk/res" ]
261 custom_package = "org.chromium.mojo.shell" 261 custom_package = "org.chromium.mojo.shell"
262 } 262 }
263 263
264 mojo_shell_assets_dir = "$root_build_dir/mojo_shell_assets" 264 mojo_runner_assets_dir = "$root_build_dir/mojo_runner_assets"
265 mojo_shell_test_assets_dir = "$root_build_dir/mojo_shell_test_assets" 265 mojo_runner_test_assets_dir = "$root_build_dir/mojo_runner_test_assets"
266 266
267 copy_ex("copy_mojo_shell_assets") { 267 copy_ex("copy_mojo_runner_assets") {
268 clear_dir = true 268 clear_dir = true
269 dest = mojo_shell_assets_dir 269 dest = mojo_runner_assets_dir
270 sources = [ 270 sources = [
271 "$root_out_dir/lib.stripped/libbootstrap.so", 271 "$root_out_dir/lib.stripped/libbootstrap.so",
272 "$root_out_dir/network_service.mojo", 272 "$root_out_dir/network_service.mojo",
273 "$root_out_dir/obj/mojo/shell/bootstrap_java.dex.jar", 273 "$root_out_dir/obj/mojo/runner/bootstrap_java.dex.jar",
274 ] 274 ]
275 } 275 }
276 276
277 copy("copy_mojo_shell") { 277 copy("copy_mojo_runner") {
278 sources = [ 278 sources = [
279 "$root_out_dir/exe.stripped/mojo_shell", 279 "$root_out_dir/exe.stripped/mojo_runner",
280 ] 280 ]
281 outputs = [ 281 outputs = [
282 "$root_out_dir/lib.stripped/libmojo_shell.so", 282 "$root_out_dir/lib.stripped/libmojo_runner.so",
283 ] 283 ]
284 } 284 }
285 285
286 copy_ex("copy_mojo_shell_test_assets") { 286 copy_ex("copy_mojo_runner_test_assets") {
287 clear_dir = true 287 clear_dir = true
288 dest = mojo_shell_test_assets_dir 288 dest = mojo_runner_test_assets_dir
289 sources = [ 289 sources = [
290 "$root_out_dir/test_app.mojo", 290 "$root_out_dir/test_app.mojo",
291 "$root_out_dir/test_request_tracker_app.mojo", 291 "$root_out_dir/test_request_tracker_app.mojo",
292 ] 292 ]
293 } 293 }
294 294
295 android_apk("mojo_shell_apk") { 295 android_apk("mojo_runner_apk") {
296 apk_name = "MojoShell" 296 apk_name = "MojoRunner"
297 297
298 android_manifest = "android/apk/AndroidManifest.xml" 298 android_manifest = "android/apk/AndroidManifest.xml"
299 299
300 native_libs = [ "libmojo_shell.so" ] 300 native_libs = [ "libmojo_runner.so" ]
301 301
302 asset_location = mojo_shell_assets_dir 302 asset_location = mojo_runner_assets_dir
303 303
304 deps = [ 304 deps = [
305 ":copy_mojo_shell", 305 ":copy_mojo_runner",
306 ":copy_mojo_shell_assets", 306 ":copy_mojo_runner_assets",
307 ":java", 307 ":java",
308 ":resources", 308 ":resources",
309 "//base:base_java", 309 "//base:base_java",
310 "//components/native_viewport:native_viewport_java", 310 "//components/native_viewport:native_viewport_java",
311 "//third_party/android_tools:google_play_services_default_resources", 311 "//third_party/android_tools:google_play_services_default_resources",
312 ] 312 ]
313 } 313 }
314 314
315 android_library("mojo_shell_tests_java") { 315 android_library("mojo_runner_tests_java") {
316 java_files = 316 java_files =
317 [ "android/tests/src/org/chromium/mojo/shell/ShellTestBase.java" ] 317 [ "android/tests/src/org/chromium/mojo/shell/ShellTestBase.java" ]
318 318
319 deps = [ 319 deps = [
320 ":java", 320 ":java",
321 "//base:base_java", 321 "//base:base_java",
322 ] 322 ]
323 } 323 }
324 } 324 }
325 325
326 mojom("child_process_bindings") { 326 mojom("child_process_bindings") {
327 sources = [ 327 sources = [
328 "child_process.mojom", 328 "child_process.mojom",
329 ] 329 ]
330 330
331 deps = [ 331 deps = [
332 "//third_party/mojo/src/mojo/public/interfaces/application", 332 "//third_party/mojo/src/mojo/public/interfaces/application",
333 ] 333 ]
334 } 334 }
335 335
336 test("tests") { 336 test("tests") {
337 output_name = "mojo_shell_unittests" 337 output_name = "mojo_runner_unittests"
338 338
339 sources = [ 339 sources = [
340 "child_process_host_unittest.cc", 340 "child_process_host_unittest.cc",
341 "data_pipe_peek_unittest.cc", 341 "data_pipe_peek_unittest.cc",
342 "in_process_native_runner_unittest.cc", 342 "in_process_native_runner_unittest.cc",
343 "native_runner_unittest.cc", 343 "native_runner_unittest.cc",
344 "shell_test_base.cc", 344 "shell_test_base.cc",
345 "shell_test_base.h", 345 "shell_test_base.h",
346 "shell_test_base_android.cc", 346 "shell_test_base_android.cc",
347 "shell_test_base_unittest.cc", 347 "shell_test_base_unittest.cc",
348 "shell_test_main.cc", 348 "shell_test_main.cc",
349 "url_resolver_unittest.cc", 349 "url_resolver_unittest.cc",
350 ] 350 ]
351 351
352 deps = [ 352 deps = [
353 ":in_process_native_runner", 353 ":in_process_native_runner",
354 ":lib", 354 ":lib",
355 "//base", 355 "//base",
356 "//base:i18n", 356 "//base:i18n",
357 "//base/test:test_support", 357 "//base/test:test_support",
358 "//testing/gtest", 358 "//testing/gtest",
359 "//url", 359 "//url",
360 "//mojo/common", 360 "//mojo/common",
361 "//third_party/mojo/src/mojo/edk/system", 361 "//third_party/mojo/src/mojo/edk/system",
362 "//mojo/environment:chromium", 362 "//mojo/environment:chromium",
363 "//third_party/mojo/src/mojo/public/cpp/bindings", 363 "//third_party/mojo/src/mojo/public/cpp/bindings",
364 "//mojo/services/test_service:bindings", 364 "//mojo/services/test_service:bindings",
365 "//mojo/shell/application_manager", 365 "//mojo/shell",
366 ] 366 ]
367 367
368 datadeps = [ 368 datadeps = [
369 "//mojo/services/test_service:test_app", 369 "//mojo/services/test_service:test_app",
370 "//mojo/services/test_service:test_request_tracker_app", 370 "//mojo/services/test_service:test_request_tracker_app",
371 ] 371 ]
372 372
373 if (is_android) { 373 if (is_android) {
374 sources += [ "android/background_application_loader_unittest.cc" ] 374 sources += [ "android/background_application_loader_unittest.cc" ]
375 375
376 deps += [ ":jni_headers" ] 376 deps += [ ":jni_headers" ]
377 377
378 apk_deps = [ 378 apk_deps = [
379 ":copy_mojo_shell_test_assets", 379 ":copy_mojo_runner_test_assets",
380 ":mojo_shell_tests_java", 380 ":mojo_runner_tests_java",
381 ] 381 ]
382 382
383 apk_asset_location = mojo_shell_test_assets_dir 383 apk_asset_location = mojo_runner_test_assets_dir
384 } 384 }
385 } 385 }
386 386
387 mojo_native_application("apptests") { 387 mojo_native_application("apptests") {
388 output_name = "shell_apptests" 388 output_name = "runner_apptests"
389 389
390 testonly = true 390 testonly = true
391 391
392 sources = [ 392 sources = [
393 # TODO(jam): needs http_server service. 393 # TODO(jam): needs http_server service.
394 #"shell_apptest.cc", 394 #"shell_apptest.cc",
395 ] 395 ]
396 396
397 deps = [ 397 deps = [
398 "//base", 398 "//base",
399 "//mojo/application", 399 "//mojo/application",
400 "//mojo/application:test_support", 400 "//mojo/application:test_support",
401 "//mojo/common:common", 401 "//mojo/common:common",
402 "//third_party/mojo/src/mojo/public/cpp/bindings:callback", 402 "//third_party/mojo/src/mojo/public/cpp/bindings:callback",
403 "//third_party/mojo/src/mojo/public/cpp/environment", 403 "//third_party/mojo/src/mojo/public/cpp/environment",
404 "//third_party/mojo/src/mojo/public/cpp/system:system", 404 "//third_party/mojo/src/mojo/public/cpp/system:system",
405 405
406 "//mojo/runner/test:bindings",
sky 2015/04/27 19:25:30 nit: sort.
407
406 #"//mojo/services/http_server/public/cpp", 408 #"//mojo/services/http_server/public/cpp",
407 #"//mojo/services/http_server/public/interfaces", 409 #"//mojo/services/http_server/public/interfaces",
408 "//mojo/services/network/public/interfaces", 410 "//mojo/services/network/public/interfaces",
409 "//mojo/shell/test:bindings",
410 ] 411 ]
411 412
412 #data_deps = [ "//services/http_server:http_server($default_toolchain)" ] 413 #data_deps = [ "//services/http_server:http_server($default_toolchain)" ]
413 } 414 }
OLDNEW
« no previous file with comments | « mojo/application/BUILD.gn ('k') | mojo/runner/DEPS » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698