Explicitly add python-numpy dependency to install-build-deps.
[chromium-blink-merge.git] / extensions / common / BUILD.gn
blobc8c1971f47e24234edd89deb68136eb1715dfa9b
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/features.gni")
6 import("//mojo/public/tools/bindings/mojom.gni")
8 # GYP version: extensions/extensions.gyp:extensions_common_constants
9 source_set("common_constants") {
10   sources = [
11     "constants.cc",
12     "constants.h",
13   ]
15   if (is_win) {
16     cflags = [
17       "/wd4267", # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
18     ]
19   }
22 if (enable_extensions) {
24 mojom("mojo") {
25   sources = [
26     "mojo/keep_alive.mojom",
27     "mojo/stash.mojom",
28   ]
32 # GYP version: extensions/extensions.gyp:extensions_common
33 source_set("common") {
34   sources = [
35     "api/messaging/message.h",
36     "api/bluetooth/bluetooth_manifest_data.cc",
37     "api/bluetooth/bluetooth_manifest_data.h",
38     "api/bluetooth/bluetooth_manifest_handler.cc",
39     "api/bluetooth/bluetooth_manifest_handler.h",
40     "api/bluetooth/bluetooth_manifest_permission.cc",
41     "api/bluetooth/bluetooth_manifest_permission.h",
42     "api/sockets/sockets_manifest_data.cc",
43     "api/sockets/sockets_manifest_data.h",
44     "api/sockets/sockets_manifest_handler.cc",
45     "api/sockets/sockets_manifest_handler.h",
46     "api/sockets/sockets_manifest_permission.cc",
47     "api/sockets/sockets_manifest_permission.h",
48     "common_manifest_handlers.cc",
49     "common_manifest_handlers.h",
50     "csp_validator.cc",
51     "csp_validator.h",
52     "dom_action_types.h",
53     "draggable_region.cc",
54     "draggable_region.h",
55     "error_utils.cc",
56     "error_utils.h",
57     "event_filter.cc",
58     "event_filter.h",
59     "event_filtering_info.cc",
60     "event_filtering_info.h",
61     "event_matcher.cc",
62     "event_matcher.h",
63     "extension.cc",
64     "extension.h",
65     "extension_api.cc",
66     "extension_api.h",
67     "extension_icon_set.cc",
68     "extension_icon_set.h",
69     "extension_l10n_util.cc",
70     "extension_l10n_util.h",
71     "extension_message_generator.cc",
72     "extension_message_generator.h",
73     "extension_messages.cc",
74     "extension_messages.h",
75     "extension_paths.cc",
76     "extension_paths.h",
77     "extension_resource.cc",
78     "extension_resource.h",
79     "extension_set.cc",
80     "extension_set.h",
81     "extension_urls.cc",
82     "extension_urls.h",
83     "extensions_client.cc",
84     "extensions_client.h",
85     "feature_switch.cc",
86     "feature_switch.h",
87     "features/api_feature.cc",
88     "features/api_feature.h",
89     "features/base_feature_provider.cc",
90     "features/base_feature_provider.h",
91     "features/complex_feature.cc",
92     "features/complex_feature.h",
93     "features/feature.cc",
94     "features/feature.h",
95     "features/feature_provider.cc",
96     "features/feature_provider.h",
97     "features/json_feature_provider_source.cc",
98     "features/json_feature_provider_source.h",
99     "features/manifest_feature.cc",
100     "features/manifest_feature.h",
101     "features/permission_feature.cc",
102     "features/permission_feature.h",
103     "features/simple_feature.cc",
104     "features/simple_feature.h",
105     "features/simple_feature_filter.cc",
106     "features/simple_feature_filter.h",
107     "file_util.cc",
108     "file_util.h",
109     "guest_view/guest_view_constants.cc",
110     "guest_view/guest_view_constants.h",
111     "install_warning.cc",
112     "install_warning.h",
113     "manifest.cc",
114     "manifest.h",
115     "manifest_constants.cc",
116     "manifest_constants.h",
117     "manifest_handler.cc",
118     "manifest_handler.h",
119     "manifest_handler_helpers.cc",
120     "manifest_handler_helpers.h",
121     "manifest_handlers/background_info.cc",
122     "manifest_handlers/background_info.h",
123     "manifest_handlers/csp_info.cc",
124     "manifest_handlers/csp_info.h",
125     "manifest_handlers/default_locale_handler.cc",
126     "manifest_handlers/default_locale_handler.h",
127     "manifest_handlers/externally_connectable.cc",
128     "manifest_handlers/externally_connectable.h",
129     "manifest_handlers/file_handler_info.cc",
130     "manifest_handlers/file_handler_info.h",
131     "manifest_handlers/icons_handler.cc",
132     "manifest_handlers/icons_handler.h",
133     "manifest_handlers/incognito_info.cc",
134     "manifest_handlers/incognito_info.h",
135     "manifest_handlers/kiosk_mode_info.cc",
136     "manifest_handlers/kiosk_mode_info.h",
137     "manifest_handlers/launcher_page_info.cc",
138     "manifest_handlers/launcher_page_info.h",
139     "manifest_handlers/oauth2_manifest_handler.cc",
140     "manifest_handlers/oauth2_manifest_handler.h",
141     "manifest_handlers/offline_enabled_info.cc",
142     "manifest_handlers/offline_enabled_info.h",
143     "manifest_handlers/options_page_info.cc",
144     "manifest_handlers/options_page_info.h",
145     "manifest_handlers/permissions_parser.cc",
146     "manifest_handlers/permissions_parser.h",
147     "manifest_handlers/requirements_info.cc",
148     "manifest_handlers/requirements_info.h",
149     "manifest_handlers/sandboxed_page_info.cc",
150     "manifest_handlers/sandboxed_page_info.h",
151     "manifest_handlers/shared_module_info.cc",
152     "manifest_handlers/shared_module_info.h",
153     "manifest_handlers/web_accessible_resources_info.cc",
154     "manifest_handlers/web_accessible_resources_info.h",
155     "manifest_handlers/webview_info.cc",
156     "manifest_handlers/webview_info.h",
157     "manifest_url_handlers.cc",
158     "manifest_url_handlers.h",
159     "message_bundle.cc",
160     "message_bundle.h",
161     "one_shot_event.cc",
162     "one_shot_event.h",
163     "permissions/api_permission.cc",
164     "permissions/api_permission.h",
165     "permissions/api_permission_set.cc",
166     "permissions/api_permission_set.h",
167     "permissions/base_set_operators.h",
168     "permissions/extensions_api_permissions.cc",
169     "permissions/extensions_api_permissions.h",
170     "permissions/manifest_permission.cc",
171     "permissions/manifest_permission.h",
172     "permissions/manifest_permission_set.cc",
173     "permissions/manifest_permission_set.h",
174     "permissions/media_galleries_permission.cc",
175     "permissions/media_galleries_permission.h",
176     "permissions/media_galleries_permission_data.cc",
177     "permissions/media_galleries_permission_data.h",
178     "permissions/permission_message.cc",
179     "permissions/permission_message.h",
180     "permissions/permission_message_provider.cc",
181     "permissions/permission_message_provider.h",
182     "permissions/permission_message_util.cc",
183     "permissions/permission_message_util.h",
184     "permissions/permission_set.cc",
185     "permissions/permission_set.h",
186     "permissions/permissions_data.cc",
187     "permissions/permissions_data.h",
188     "permissions/permissions_info.cc",
189     "permissions/permissions_info.h",
190     "permissions/permissions_provider.h",
191     "permissions/set_disjunction_permission.h",
192     "permissions/settings_override_permission.cc",
193     "permissions/settings_override_permission.h",
194     "permissions/socket_permission.cc",
195     "permissions/socket_permission.h",
196     "permissions/socket_permission_data.cc",
197     "permissions/socket_permission_data.h",
198     "permissions/socket_permission_entry.cc",
199     "permissions/socket_permission_entry.h",
200     "permissions/usb_device_permission.cc",
201     "permissions/usb_device_permission.h",
202     "permissions/usb_device_permission_data.cc",
203     "permissions/usb_device_permission_data.h",
204     "stack_frame.cc",
205     "stack_frame.h",
206     "switches.cc",
207     "switches.h",
208     "update_manifest.cc",
209     "update_manifest.h",
210     "url_pattern.cc",
211     "url_pattern.h",
212     "url_pattern_set.cc",
213     "url_pattern_set.h",
214     "user_script.cc",
215     "user_script.h",
216     "value_counter.cc",
217     "value_counter.h",
218     "view_type.cc",
219     "view_type.h",
220   ]
222   deps = [
223     ":common_constants",
224     ":mojo",
225     # TODO(benwells): figure out what to do with the api target and
226     # api resources compiled into the chrome resource bundle.
227     # http://crbug.com/162530
228     "//chrome:resources",
229     "//components/crx_file",
230     "//components/url_matcher",
231     "//content/public/common",
232     "//crypto",
233     "//device/bluetooth",
234     "//device/usb",
235     "//extensions/common/api",
236     "//extensions/strings",
237     "//extensions:extensions_resources",
238     "//ipc",
239     "//net",
240     "//third_party/icu",
241     "//third_party/libxml",
242     "//third_party/re2",
243     "//ui/base",
244     "//ui/gfx/geometry",
245     "//ui/gfx/ipc",
246     "//url",
247   ]
249   if (enable_nacl) {
250     sources += [
251       "manifest_handlers/nacl_modules_handler.cc",
252       "manifest_handlers/nacl_modules_handler.h",
253     ]
254   }
256   if (is_win) {
257     cflags = [
258       "/wd4267", # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
259     ]
260   }
263 } # enable_extensions