Include all dupe types (event when value is zero) in scan stats.
[chromium-blink-merge.git] / components / autofill / core / browser / BUILD.gn
blob1c6a5fa6720cf7d816822fa4021b4613a7ba7de2
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 import("//build/config/chrome_build.gni")
7 # This config sets the define that controls which Wallet service to contact
8 # for features using Wallet integration. Unofficial builds won't have the
9 # proper API keys so it uses the "sandbox" test servers instead.
10 config("wallet_service") {
11   if (is_official_build) {
12     defines = [ "ENABLE_PROD_WALLET_SERVICE=1" ]
13   }
16 # GYP version: components/autofill.gyp:autofill_core_browser
17 static_library("browser") {
18   sources = [
19     "address.cc",
20     "address.h",
21     "address_field.cc",
22     "address_field.h",
23     "address_i18n.cc",
24     "address_i18n.h",
25     "autocomplete_history_manager.cc",
26     "autocomplete_history_manager.h",
27     "autofill-inl.h",
28     "autofill_cc_infobar_delegate.cc",
29     "autofill_cc_infobar_delegate.h",
30     "autofill_client.h",
31     "autofill_country.cc",
32     "autofill_country.h",
33     "autofill_data_model.cc",
34     "autofill_data_model.h",
35     "autofill_download_manager.cc",
36     "autofill_download_manager.h",
37     "autofill_driver.h",
38     "autofill_experiments.cc",
39     "autofill_experiments.h",
40     "autofill_external_delegate.cc",
41     "autofill_external_delegate.h",
42     "autofill_field.cc",
43     "autofill_field.h",
44     "autofill_ie_toolbar_import_win.cc",
45     "autofill_ie_toolbar_import_win.h",
46     "autofill_manager.cc",
47     "autofill_manager.h",
48     "autofill_manager_test_delegate.h",
49     "autofill_metrics.cc",
50     "autofill_metrics.h",
51     "autofill_popup_delegate.h",
52     "autofill_profile.cc",
53     "autofill_profile.h",
54     "autofill_regex_constants.cc",
55     "autofill_regex_constants.h",
56     "autofill_scanner.cc",
57     "autofill_scanner.h",
58     "autofill_server_field_info.h",
59     "autofill_sync_constants.cc",
60     "autofill_sync_constants.h",
61     "autofill_type.cc",
62     "autofill_type.h",
63     "autofill_xml_parser.cc",
64     "autofill_xml_parser.h",
65     "card_unmask_delegate.cc",
66     "card_unmask_delegate.h",
67     "contact_info.cc",
68     "contact_info.h",
69     "credit_card.cc",
70     "credit_card.h",
71     "credit_card_field.cc",
72     "credit_card_field.h",
73     "detail_input.cc",
74     "detail_input.h",
75     "dialog_section.h",
76     "email_field.cc",
77     "email_field.h",
78     "field_types.h",
79     "form_field.cc",
80     "form_field.h",
81     "form_group.cc",
82     "form_group.h",
83     "form_structure.cc",
84     "form_structure.h",
85     "name_field.cc",
86     "name_field.h",
87     "options_util.cc",
88     "options_util.h",
89     "password_generator.cc",
90     "password_generator.h",
91     "personal_data_manager.cc",
92     "personal_data_manager.h",
93     "personal_data_manager_mac.mm",
94     "personal_data_manager_observer.h",
95     "phone_field.cc",
96     "phone_field.h",
97     "phone_number.cc",
98     "phone_number.h",
99     "phone_number_i18n.cc",
100     "phone_number_i18n.h",
101     "popup_item_ids.h",
102     "server_field_types_util.cc",
103     "server_field_types_util.h",
104     "state_names.cc",
105     "state_names.h",
106     "suggestion.cc",
107     "suggestion.h",
108     "ui/card_unmask_prompt_controller.h",
109     "ui/card_unmask_prompt_controller_impl.cc",
110     "ui/card_unmask_prompt_controller_impl.h",
111     "ui/card_unmask_prompt_view.h",
112     "validation.cc",
113     "validation.h",
114     "wallet/real_pan_wallet_client.cc",
115     "wallet/real_pan_wallet_client.h",
116     "webdata/autocomplete_syncable_service.cc",
117     "webdata/autocomplete_syncable_service.h",
118     "webdata/autofill_change.cc",
119     "webdata/autofill_change.h",
120     "webdata/autofill_entry.cc",
121     "webdata/autofill_entry.h",
122     "webdata/autofill_profile_syncable_service.cc",
123     "webdata/autofill_profile_syncable_service.h",
124     "webdata/autofill_table.cc",
125     "webdata/autofill_table.h",
126     "webdata/autofill_wallet_syncable_service.cc",
127     "webdata/autofill_wallet_syncable_service.h",
128     "webdata/autofill_webdata.h",
129     "webdata/autofill_webdata_backend.h",
130     "webdata/autofill_webdata_backend_impl.cc",
131     "webdata/autofill_webdata_backend_impl.h",
132     "webdata/autofill_webdata_service.cc",
133     "webdata/autofill_webdata_service.h",
134     "webdata/autofill_webdata_service_observer.h",
135   ]
137   deps = [
138     "//base",
139     "//base:i18n",
140     "//base:prefs",
141     "//components/autofill/core/common",
142     "//components/infobars/core",
143     "//components/keyed_service/core",
144     "//components/os_crypt",
145     "//components/pref_registry",
146     "//components/resources",
147     "//components/signin/core/common",
148     "//components/strings",
149     "//components/webdata/common",
150     "//google_apis",
151     "//net",
152     "//skia",
153     "//sql",
154     "//sync",
155     "//third_party/fips181",
156     "//third_party/icu",
157     "//third_party/libaddressinput:util",
158     "//third_party/libphonenumber",
159     "//third_party/libjingle",
160     "//ui/base",
161     "//ui/gfx",
162     "//ui/gfx/geometry",
163     "//url",
164   ]
166   configs += [
167     ":wallet_service",
168     "//build/config/compiler:no_size_t_to_int_warning",
169   ]
171   if (is_mac) {
172     libs = [ "AddressBook.framework" ]
173   }
176 static_library("test_support") {
177   testonly = true
178   sources = [
179     "autofill_test_utils.cc",
180     "autofill_test_utils.h",
181     "data_driven_test.cc",
182     "data_driven_test.h",
183     "suggestion_test_helpers.h",
184     "test_autofill_client.cc",
185     "test_autofill_client.h",
186     "test_autofill_driver.cc",
187     "test_autofill_driver.h",
188     "test_autofill_external_delegate.cc",
189     "test_autofill_external_delegate.h",
190     "test_personal_data_manager.cc",
191     "test_personal_data_manager.h",
192   ]
194   deps = [
195     ":browser",
196     "//base",
197     "//base:prefs",
198     "//base:prefs_test_support",
199     "//base/test:test_support",
200     "//components/autofill/core/browser",
201     "//components/autofill/core/common",
202     "//components/os_crypt",
203     "//components/pref_registry",
204     "//components/rappor",
205     "//google_apis:test_support",
206     "//skia",
207     "//testing/gtest",
208   ]
211 source_set("unit_tests") {
212   testonly = true
213   sources = [
214     "address_field_unittest.cc",
215     "address_unittest.cc",
216     "autocomplete_history_manager_unittest.cc",
217     "autofill_country_unittest.cc",
218     "autofill_data_model_unittest.cc",
219     "autofill_download_manager_unittest.cc",
220     "autofill_external_delegate_unittest.cc",
221     "autofill_field_unittest.cc",
222     "autofill_ie_toolbar_import_win_unittest.cc",
223     "autofill_manager_unittest.cc",
224     "autofill_merge_unittest.cc",
225     "autofill_metrics_unittest.cc",
226     "autofill_profile_unittest.cc",
227     "autofill_type_unittest.cc",
228     "autofill_xml_parser_unittest.cc",
229     "contact_info_unittest.cc",
230     "credit_card_field_unittest.cc",
231     "credit_card_unittest.cc",
232     "form_field_unittest.cc",
233     "form_structure_unittest.cc",
234     "name_field_unittest.cc",
235     "options_util_unittest.cc",
236     "password_generator_unittest.cc",
237     "personal_data_manager_unittest.cc",
238     "phone_field_unittest.cc",
239     "phone_number_i18n_unittest.cc",
240     "phone_number_unittest.cc",
241     "validation_unittest.cc",
242     "webdata/autofill_profile_syncable_service_unittest.cc",
243     "webdata/autofill_table_unittest.cc",
244     "webdata/web_data_service_unittest.cc",
245   ]
247   deps = [
248     ":browser",
249     ":test_support",
250     "//base",
251     "//base:prefs",
252     "//base/test:test_support",
253     "//components/autofill/core/common",
254     "//components/os_crypt",
255     "//components/rappor:test_support",
256     "//components/resources",
257     "//components/signin/core/browser:test_support",
258     "//components/strings",
259     "//components/sync_driver",
260     "//components/webdata/common",
261     "//net:test_support",
262     "//sql",
263     "//sync",
264     "//sync:test_support_sync_api",
265     "//testing/gmock",
266     "//testing/gtest",
267     "//third_party/libphonenumber",
268     "//third_party/libjingle",
269     "//ui/base",
270     "//url",
271   ]