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.
6 import("//build/config/android/config.gni")
7 autofill_enable_sync = !is_android_webview_build
9 autofill_enable_sync = true
12 config("autofill_browser_config") {
13 if (autofill_enable_sync) {
14 defines = [ "AUTOFILL_ENABLE_SYNC" ]
18 # GYP version: components/autofill.gyp:autofill_regexes
20 visibility = "//components/autofill/*"
21 script = "//build/escape_unicode.py"
24 "autofill_regex_constants.cc.utf8",
27 "$target_gen_dir/autofill_regex_constants.cc",
30 args = [ "-o", rebase_path(target_gen_dir, root_build_dir) ]
31 args += rebase_path(inputs, root_build_dir)
34 # GYP version: components/autofill.gyp:autofill_core_browser
35 static_library("browser") {
43 "autocomplete_history_manager.cc",
44 "autocomplete_history_manager.h",
46 "autofill_country.cc",
48 "autofill_data_model.cc",
49 "autofill_data_model.h",
50 "autofill_download_manager.cc",
51 "autofill_download_manager.h",
53 "autofill_external_delegate.cc",
54 "autofill_external_delegate.h",
57 "autofill_ie_toolbar_import_win.cc",
58 "autofill_ie_toolbar_import_win.h",
59 "autofill_manager.cc",
62 "autofill_manager_test_delegate.h",
63 "autofill_metrics.cc",
65 "autofill_popup_delegate.h",
66 "autofill_profile.cc",
68 "autofill_regex_constants.cc.utf8",
69 "autofill_regex_constants.h",
70 "autofill_regexes.cc",
72 "autofill_scanner.cc",
74 "autofill_server_field_info.h",
77 "autofill_xml_parser.cc",
78 "autofill_xml_parser.h",
83 "credit_card_field.cc",
84 "credit_card_field.h",
96 "password_generator.cc",
97 "password_generator.h",
98 "personal_data_manager.cc",
99 "personal_data_manager.h",
100 "personal_data_manager_mac.mm",
101 "personal_data_manager_observer.h",
106 "phone_number_i18n.cc",
107 "phone_number_i18n.h",
113 "webdata/autofill_change.cc",
114 "webdata/autofill_change.h",
115 "webdata/autofill_entry.cc",
116 "webdata/autofill_entry.h",
117 "webdata/autofill_profile_syncable_service.cc",
118 "webdata/autofill_profile_syncable_service.h",
119 "webdata/autofill_table.cc",
120 "webdata/autofill_table.h",
121 "webdata/autofill_webdata.h",
122 "webdata/autofill_webdata_backend.h",
123 "webdata/autofill_webdata_backend_impl.cc",
124 "webdata/autofill_webdata_backend_impl.h",
125 "webdata/autofill_webdata_service.cc",
126 "webdata/autofill_webdata_service.h",
127 "webdata/autofill_webdata_service_observer.h",
130 # Compile the generated regex file.
131 sources += get_target_outputs(":regexes")
138 "//components/autofill/core/common",
139 "//components/keyed_service/core",
140 "//components/os_crypt",
141 "//components/pref_registry",
142 "//components/resources",
143 "//components/strings",
144 "//components/webdata/common",
148 "//third_party/fips181",
150 "//third_party/libaddressinput:util",
151 "//third_party/libphonenumber",
156 # TODO(GYP) also remove libjingle_stub_config below when this is added:
157 #'../third_party/libjingle/libjingle.gyp:libjingle', TODO(GYP)
160 configs += [ "//content:libjingle_stub_config" ]
161 direct_dependent_configs = [ ":autofill_browser_config" ]
163 if (autofill_enable_sync) {
167 "webdata/autofill_profile_syncable_service.cc",
168 "webdata/autofill_profile_syncable_service.h",
173 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
174 cflags = [ "/wd4267" ]
178 static_library("test_support") {
180 "autofill_test_utils.cc",
181 "autofill_test_utils.h",
182 "data_driven_test.cc",
183 "data_driven_test.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",
196 "//components/autofill/core/browser",
197 "//components/autofill/core/common",
203 source_set("unit_tests") {
205 "address_field_unittest.cc",
206 "address_unittest.cc",
207 "autocomplete_history_manager_unittest.cc",
208 "autofill_country_unittest.cc",
209 "autofill_data_model_unittest.cc",
210 "autofill_download_manager_unittest.cc",
211 "autofill_external_delegate_unittest.cc",
212 "autofill_field_unittest.cc",
213 "autofill_ie_toolbar_import_win_unittest.cc",
214 "autofill_manager_unittest.cc",
215 "autofill_merge_unittest.cc",
216 "autofill_metrics_unittest.cc",
217 "autofill_profile_unittest.cc",
218 "autofill_regexes_unittest.cc",
219 "autofill_type_unittest.cc",
220 "autofill_xml_parser_unittest.cc",
221 "contact_info_unittest.cc",
222 "credit_card_field_unittest.cc",
223 "credit_card_unittest.cc",
224 "form_field_unittest.cc",
225 "form_structure_unittest.cc",
226 "name_field_unittest.cc",
227 "password_generator_unittest.cc",
228 "personal_data_manager_unittest.cc",
229 "phone_field_unittest.cc",
230 "phone_number_i18n_unittest.cc",
231 "phone_number_unittest.cc",
232 "validation_unittest.cc",
233 "webdata/autofill_profile_syncable_service_unittest.cc",
234 "webdata/autofill_table_unittest.cc",
235 "webdata/web_data_service_unittest.cc",
238 configs += [ "//content:libjingle_stub_config" ]
243 "//components/resources",
244 "//components/strings",
246 "//third_party/libphonenumber",
247 #'../third_party/libjingle/libjingle.gyp:libjingle', TODO(GYP)