OLD | NEW |
1 # Copyright 2015 The Chromium Authors. All rights reserved. | 1 # Copyright 2015 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("//testing/test.gni") | 6 import("//testing/test.gni") |
7 import("//services/service_manager/public/cpp/service.gni") | 7 import("//services/service_manager/public/cpp/service.gni") |
8 import("//services/service_manager/public/service_manifest.gni") | 8 import("//services/service_manager/public/service_manifest.gni") |
| 9 import("//services/service_manager/public/constants.gni") |
9 import("//tools/grit/repack.gni") | 10 import("//tools/grit/repack.gni") |
10 | 11 |
11 group("all") { | 12 group("all") { |
12 testonly = true | 13 testonly = true |
13 deps = [ | 14 deps = [ |
14 ":ui", | 15 ":ui", |
15 "//services/ui/ime/test_ime_driver", | 16 "//services/ui/ime/test_ime_driver", |
16 "//services/ui/test_wm", | 17 "//services/ui/test_wm", |
17 ] | 18 ] |
18 } | 19 } |
19 | 20 |
20 service("ui") { | 21 service("ui") { |
21 sources = [ | 22 sources = [ |
22 "main.cc", | 23 "main.cc", |
23 ] | 24 ] |
24 | 25 |
25 deps = [ | 26 deps = [ |
| 27 ":copy_gl_libraries", |
26 ":lib", | 28 ":lib", |
| 29 ":resources_100", |
| 30 ":resources_200", |
| 31 ":resources_strings", |
27 "//services/service_manager/public/cpp:sources", | 32 "//services/service_manager/public/cpp:sources", |
28 "//services/tracing/public/interfaces", | 33 "//services/tracing/public/interfaces", |
29 ] | 34 ] |
30 | 35 |
31 data_deps = [ | 36 data_deps = [ |
| 37 ":copy_gl_libraries", |
32 ":manifest", | 38 ":manifest", |
33 ":resources_100", | |
34 ":resources_200", | |
35 ":resources_strings", | |
36 "//services/ui/ime/test_ime_driver", | 39 "//services/ui/ime/test_ime_driver", |
37 ] | 40 ] |
| 41 |
| 42 resources = [ |
| 43 "$root_out_dir/mus_app_resources_strings.pak", |
| 44 "$root_out_dir/mus_app_resources_100.pak", |
| 45 "$root_out_dir/mus_app_resources_200.pak", |
| 46 ] |
38 } | 47 } |
39 | 48 |
40 service_manifest("manifest") { | 49 service_manifest("manifest") { |
41 name = "ui" | 50 name = "ui" |
42 source = "manifest.json" | 51 source = "manifest.json" |
43 } | 52 } |
44 | 53 |
| 54 copy("copy_gl_libraries") { |
| 55 deps = [ |
| 56 "//third_party/mesa:osmesa", |
| 57 ] |
| 58 |
| 59 if (is_win) { |
| 60 deps += [ |
| 61 "//third_party/angle:libEGL", |
| 62 "//third_party/angle:libGLESv2", |
| 63 ] |
| 64 |
| 65 sources = [ |
| 66 "$root_shlib_dir/libEGL.dll", |
| 67 "$root_shlib_dir/libGLESv2.dll", |
| 68 "$root_shlib_dir/osmesa.dll", |
| 69 ] |
| 70 } else if (is_android || is_linux) { |
| 71 sources = [ |
| 72 "$root_shlib_dir/libosmesa.so", |
| 73 ] |
| 74 } else { |
| 75 sources = [] |
| 76 } |
| 77 |
| 78 outputs = [ |
| 79 "$root_out_dir/$packages_directory/ui/{{source_file_part}}", |
| 80 ] |
| 81 } |
| 82 |
45 source_set("lib") { | 83 source_set("lib") { |
46 sources = [ | 84 sources = [ |
47 "service.cc", | 85 "service.cc", |
48 "service.h", | 86 "service.h", |
49 ] | 87 ] |
50 | 88 |
51 public_deps = [ | 89 public_deps = [ |
52 "//services/ui/common:mus_common", | 90 "//services/ui/common:mus_common", |
53 ] | 91 ] |
54 deps = [ | 92 deps = [ |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
110 | 148 |
111 repack("resources_200") { | 149 repack("resources_200") { |
112 sources = [ | 150 sources = [ |
113 "$root_gen_dir/ui/resources/ui_resources_200_percent.pak", | 151 "$root_gen_dir/ui/resources/ui_resources_200_percent.pak", |
114 ] | 152 ] |
115 output = "$root_out_dir/mus_app_resources_200.pak" | 153 output = "$root_out_dir/mus_app_resources_200.pak" |
116 deps = [ | 154 deps = [ |
117 "//ui/resources", | 155 "//ui/resources", |
118 ] | 156 ] |
119 } | 157 } |
OLD | NEW |