Give names to all utility processes.
[chromium-blink-merge.git] / components / metrics / BUILD.gn
blob8a3e0cc25377030034d580329d33700843e4e42a
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
3 # found in the LICENSE file.
5 # GYP version: components/metrics.gypi:metrics
6 source_set("metrics") {
7   sources = [
8     "call_stack_profile_metrics_provider.cc",
9     "call_stack_profile_metrics_provider.h",
10     "clean_exit_beacon.cc",
11     "clean_exit_beacon.h",
12     "client_info.cc",
13     "client_info.h",
14     "cloned_install_detector.cc",
15     "cloned_install_detector.h",
16     "compression_utils.cc",
17     "compression_utils.h",
18     "daily_event.cc",
19     "daily_event.h",
20     "histogram_encoder.cc",
21     "histogram_encoder.h",
22     "histogram_manager.cc",
23     "histogram_manager.h",
24     "machine_id_provider.h",
25     "machine_id_provider_stub.cc",
26     "machine_id_provider_win.cc",
27     "metrics_hashes.cc",
28     "metrics_hashes.h",
29     "metrics_log.cc",
30     "metrics_log.h",
31     "metrics_log_manager.cc",
32     "metrics_log_manager.h",
33     "metrics_log_uploader.cc",
34     "metrics_log_uploader.h",
35     "metrics_pref_names.cc",
36     "metrics_pref_names.h",
37     "metrics_provider.cc",
38     "metrics_provider.h",
39     "metrics_reporting_scheduler.cc",
40     "metrics_reporting_scheduler.h",
41     "metrics_service.cc",
42     "metrics_service.h",
43     "metrics_service_accessor.cc",
44     "metrics_service_accessor.h",
45     "metrics_service_client.cc",
46     "metrics_service_client.h",
47     "metrics_state_manager.cc",
48     "metrics_state_manager.h",
49     "metrics_switches.cc",
50     "metrics_switches.h",
51     "persisted_logs.cc",
52     "persisted_logs.h",
53     "url_constants.cc",
54     "url_constants.h",
55   ]
57   public_deps = [
58     "//components/metrics/proto",
59   ]
60   deps = [
61     "//base",
62     "//base:i18n",
63     "//base:prefs",
64     "//components/variations",
65     "//third_party/zlib",
66   ]
68   if (is_chromeos) {
69     deps += [ ":serialization" ]
70   }
72   if (is_win) {
73     sources -= [ "machine_id_provider_stub.cc" ]
74   }
77 # GYP version: components/metrics.gypi:metrics_gpu
78 source_set("gpu") {
79   sources = [
80     "gpu/gpu_metrics_provider.cc",
81     "gpu/gpu_metrics_provider.h",
82   ]
84   public_deps = [
85     ":metrics",
86   ]
87   deps = [
88     "//base",
89     "//content/public/browser",
90     "//gpu/config",
91     "//ui/gfx",
92   ]
95 # GYP version: components/metrics.gypi:metrics_net
96 static_library("net") {
97   sources = [
98     "net/net_metrics_log_uploader.cc",
99     "net/net_metrics_log_uploader.h",
100     "net/network_metrics_provider.cc",
101     "net/network_metrics_provider.h",
102     "net/wifi_access_point_info_provider.cc",
103     "net/wifi_access_point_info_provider.h",
104     "net/wifi_access_point_info_provider_chromeos.cc",
105     "net/wifi_access_point_info_provider_chromeos.h",
106   ]
108   public_deps = [
109     ":metrics",
110   ]
111   deps = [
112     "//base",
113     "//net",
114     "//url",
115   ]
118 # GYP version: components/metrics.gypi:metrics_profiler
119 source_set("profiler") {
120   sources = [
121     "profiler/profiler_metrics_provider.cc",
122     "profiler/profiler_metrics_provider.h",
123     "profiler/tracking_synchronizer.cc",
124     "profiler/tracking_synchronizer.h",
125     "profiler/tracking_synchronizer_observer.h",
126   ]
128   public_deps = [
129     ":metrics",
130   ]
131   deps = [
132     "//base",
133     "//components/variations",
134     "//content/public/browser",
135     "//content/public/common",
136   ]
139 # GYP version: components/metrics.gypi:metrics_test_support
140 source_set("test_support") {
141   sources = [
142     "test_metrics_service_client.cc",
143     "test_metrics_service_client.h",
144   ]
146   public_deps = [
147     ":metrics",
148   ]
149   deps = [
150     "//base",
151   ]
154 if (is_linux) {
155   # GYP version: components/metrics.gypi:metrics_serialization
156   source_set("serialization") {
157     sources = [
158       "serialization/metric_sample.cc",
159       "serialization/metric_sample.h",
160       "serialization/serialization_utils.cc",
161       "serialization/serialization_utils.h",
162     ]
163     deps = [
164       "//base",
165     ]
166   }
169 source_set("unit_tests") {
170   testonly = true
171   sources = [
172     "compression_utils_unittest.cc",
173     "daily_event_unittest.cc",
174     "histogram_encoder_unittest.cc",
175     "histogram_manager_unittest.cc",
176     "machine_id_provider_win_unittest.cc",
177     "metrics_hashes_unittest.cc",
178     "metrics_log_manager_unittest.cc",
179     "metrics_log_unittest.cc",
180     "metrics_reporting_scheduler_unittest.cc",
181     "metrics_service_unittest.cc",
182     "metrics_state_manager_unittest.cc",
183     "persisted_logs_unittest.cc",
184     "profiler/profiler_metrics_provider_unittest.cc",
185     "profiler/tracking_synchronizer_unittest.cc",
186   ]
188   deps = [
189     ":metrics",
190     ":profiler",
191     ":test_support",
192     "//base:prefs_test_support",
193     "//base/test:test_support",
194     "//components/variations",
195     "//content/public/common",
196     "//testing/gtest",
197   ]
199 # TODO(GYP): metrics_chromeos