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/ui.gni") | 5 import("//build/config/ui.gni") |
6 import("//testing/test.gni") | 6 import("//testing/test.gni") |
7 import("//third_party/protobuf/proto_library.gni") | 7 import("//third_party/protobuf/proto_library.gni") |
8 | 8 |
9 assert(is_chromeos, "Non-ChromeOS builds must not depend on //chromeos") | 9 assert(is_chromeos, "Non-ChromeOS builds must not depend on //chromeos") |
10 | 10 |
11 declare_args() { | 11 declare_args() { |
12 # Use binder. Binder related code is compiled only when true. | 12 # Use binder. Binder related code is compiled only when true. |
13 use_binder = false | 13 use_binder = false |
14 } | 14 } |
15 | 15 |
16 gypi_values = exec_script("//build/gypi_to_gn.py", | 16 gypi_values = exec_script("//build/gypi_to_gn.py", |
17 [ rebase_path("chromeos.gyp") ], | 17 [ rebase_path("chromeos.gyp") ], |
18 "scope", | 18 "scope", |
19 [ "chromeos.gyp" ]) | 19 [ "chromeos.gyp" ]) |
20 | 20 |
21 component("chromeos") { | 21 component("chromeos") { |
22 configs += [ "//third_party/nss:system_nss_no_ssl_config" ] | 22 configs += [ "//third_party/nss:system_nss_no_ssl_config" ] |
23 public_deps = [ | 23 public_deps = [ |
24 "//dbus", | 24 "//dbus", |
25 ] | 25 ] |
26 deps = [ | 26 deps = [ |
| 27 ":attestation_proto", |
27 ":cryptohome_proto", | 28 ":cryptohome_proto", |
28 ":power_manager_proto", | 29 ":power_manager_proto", |
29 "//base", | 30 "//base", |
30 "//base:i18n", | 31 "//base:i18n", |
31 "//base/third_party/dynamic_annotations", | 32 "//base/third_party/dynamic_annotations", |
32 "//components/device_event_log", | 33 "//components/device_event_log", |
33 "//components/onc", | 34 "//components/onc", |
34 "//components/policy/proto", | 35 "//components/policy/proto", |
35 "//components/prefs", | 36 "//components/prefs", |
36 "//components/proxy_config", | 37 "//components/proxy_config", |
(...skipping 17 matching lines...) Expand all Loading... |
54 | 55 |
55 # This must be a static library instead of a source set because some of the | 56 # This must be a static library instead of a source set because some of the |
56 # files pull in things with dependencies that aren't linked in all cases. | 57 # files pull in things with dependencies that aren't linked in all cases. |
57 # | 58 # |
58 # TODO this should probably be changed such that it links in all cases and | 59 # TODO this should probably be changed such that it links in all cases and |
59 # can be converted to a source set. | 60 # can be converted to a source set. |
60 static_library("test_support") { | 61 static_library("test_support") { |
61 testonly = true | 62 testonly = true |
62 configs += [ "//build/config/linux/dbus" ] | 63 configs += [ "//build/config/linux/dbus" ] |
63 public_deps = [ | 64 public_deps = [ |
| 65 ":attestation_proto", |
64 ":chromeos", | 66 ":chromeos", |
65 ":cryptohome_proto", | 67 ":cryptohome_proto", |
66 ":power_manager_proto", | 68 ":power_manager_proto", |
67 ] | 69 ] |
68 deps = [ | 70 deps = [ |
69 ":test_support_without_gmock", | 71 ":test_support_without_gmock", |
70 "//components/signin/core/account_id", | 72 "//components/signin/core/account_id", |
71 "//dbus:test_support", | 73 "//dbus:test_support", |
72 "//google_apis", | 74 "//google_apis", |
73 "//net:test_support", | 75 "//net:test_support", |
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
119 "network/onc/onc_test_utils.h", | 121 "network/onc/onc_test_utils.h", |
120 "system/fake_statistics_provider.cc", | 122 "system/fake_statistics_provider.cc", |
121 "system/fake_statistics_provider.h", | 123 "system/fake_statistics_provider.h", |
122 ] | 124 ] |
123 } | 125 } |
124 | 126 |
125 static_library("test_support_without_gmock") { | 127 static_library("test_support_without_gmock") { |
126 testonly = true | 128 testonly = true |
127 configs += [ "//build/config/linux/dbus" ] | 129 configs += [ "//build/config/linux/dbus" ] |
128 deps = [ | 130 deps = [ |
| 131 ":attestation_proto", |
129 ":chromeos", | 132 ":chromeos", |
130 ":cryptohome_proto", | 133 ":cryptohome_proto", |
131 ":power_manager_proto", | 134 ":power_manager_proto", |
132 "//crypto", | 135 "//crypto", |
133 ] | 136 ] |
134 sources = [ | 137 sources = [ |
135 "dbus/fake_cros_disks_client.cc", | 138 "dbus/fake_cros_disks_client.cc", |
136 "dbus/fake_cros_disks_client.h", | 139 "dbus/fake_cros_disks_client.h", |
137 "dbus/fake_session_manager_client.cc", | 140 "dbus/fake_session_manager_client.cc", |
138 "dbus/fake_session_manager_client.h", | 141 "dbus/fake_session_manager_client.h", |
139 "dbus/fake_shill_manager_client.cc", | 142 "dbus/fake_shill_manager_client.cc", |
140 "dbus/fake_shill_manager_client.h", | 143 "dbus/fake_shill_manager_client.h", |
141 "dbus/fake_update_engine_client.cc", | 144 "dbus/fake_update_engine_client.cc", |
142 "dbus/fake_update_engine_client.h", | 145 "dbus/fake_update_engine_client.h", |
143 ] | 146 ] |
144 } | 147 } |
145 | 148 |
146 test("chromeos_unittests") { | 149 test("chromeos_unittests") { |
147 configs += [ | 150 configs += [ |
148 "//build/config/linux/dbus", | 151 "//build/config/linux/dbus", |
149 "//third_party/nss:system_nss_no_ssl_config", | 152 "//third_party/nss:system_nss_no_ssl_config", |
150 ] | 153 ] |
151 deps = [ | 154 deps = [ |
| 155 ":attestation_proto", |
152 ":cryptohome_proto", | 156 ":cryptohome_proto", |
153 ":power_manager_proto", | 157 ":power_manager_proto", |
154 ":test_support", | 158 ":test_support", |
155 "//base/test:run_all_unittests", | 159 "//base/test:run_all_unittests", |
156 "//base/test:test_support", | 160 "//base/test:test_support", |
157 "//components/onc", | 161 "//components/onc", |
158 "//components/prefs:test_support", | 162 "//components/prefs:test_support", |
159 "//components/proxy_config", | 163 "//components/proxy_config", |
160 "//components/signin/core/account_id", | 164 "//components/signin/core/account_id", |
161 "//crypto", | 165 "//crypto", |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
196 | 200 |
197 proto_library("cryptohome_proto") { | 201 proto_library("cryptohome_proto") { |
198 sources = [ | 202 sources = [ |
199 "//third_party/cros_system_api/dbus/cryptohome/key.proto", | 203 "//third_party/cros_system_api/dbus/cryptohome/key.proto", |
200 "//third_party/cros_system_api/dbus/cryptohome/rpc.proto", | 204 "//third_party/cros_system_api/dbus/cryptohome/rpc.proto", |
201 ] | 205 ] |
202 | 206 |
203 proto_out_dir = "chromeos/dbus/cryptohome" | 207 proto_out_dir = "chromeos/dbus/cryptohome" |
204 } | 208 } |
205 | 209 |
| 210 proto_library("attestation_proto") { |
| 211 sources = [ |
| 212 "dbus/proto/attestation.proto", |
| 213 ] |
| 214 |
| 215 proto_out_dir = "chromeos/cryptohome" |
| 216 } |
| 217 |
206 proto_library("cryptohome_signkey_proto") { | 218 proto_library("cryptohome_signkey_proto") { |
207 sources = [ | 219 sources = [ |
208 "//third_party/cros_system_api/dbus/cryptohome/signed_secret.proto", | 220 "//third_party/cros_system_api/dbus/cryptohome/signed_secret.proto", |
209 ] | 221 ] |
210 | 222 |
211 proto_out_dir = "chromeos/cryptohome" | 223 proto_out_dir = "chromeos/cryptohome" |
212 } | 224 } |
OLD | NEW |