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/crypto.gni")
6 import("//build/config/features.gni")
7 import("//build/config/ui.gni")
9 assert(enable_extensions)
12 exec_script("//build/gypi_to_gn.py",
13 [ rebase_path("../../chrome_browser_extensions.gypi") ],
15 [ "../../chrome_browser_extensions.gypi" ])
17 # GYP version: chrome/chrome_browser_extensions.gypi:browser_extensions
18 source_set("extensions") {
20 sources += rebase_path(gypi_values.chrome_browser_extensions_enabled_sources,
26 # Since browser and browser_extensions actually depend on each other,
27 # we must omit the dependency from browser_extensions to browser.
28 # However, this means browser_extensions and browser should more or less
29 # have the same dependencies. Once browser_extensions is untangled from
30 # browser, then we can clean up these dependencies.
32 "//chrome/common/extensions/api",
33 "//content/public/browser",
36 "//chrome:extra_resources",
39 "//chrome/app/resources:platform_locale_settings",
40 "//chrome/app/theme:theme_resources",
41 "//chrome/browser/devtools",
43 "//chrome/common/extensions/api:api_registration",
44 "//chrome/common/net",
45 "//chrome/common/safe_browsing:proto",
46 "//chrome/installer/util",
47 "//components/copresence",
48 "//components/dom_distiller/core",
50 "//components/proximity_auth",
51 "//components/strings",
52 "//components/update_client",
53 "//components/url_matcher",
54 "//content/app/resources",
55 "//content/public/common",
59 "//extensions/browser",
60 "//extensions/common/api",
61 "//extensions/common/api:api_registration",
62 "//extensions/strings",
63 "//extensions:extensions_resources",
68 "//third_party/WebKit/public:image_resources",
69 "//third_party/WebKit/public:resources",
70 "//third_party/cacheinvalidation",
72 "//third_party/leveldatabase",
73 "//third_party/libaddressinput:util",
75 "//third_party/webrtc/modules/desktop_capture",
76 "//ui/accessibility:ax_gen",
89 rebase_path(gypi_values.chrome_browser_extensions_chromeos_sources,
92 sources -= [ "api/music_manager_private/device_id_linux.cc" ]
93 configs += [ "//build/config/linux:dbus" ]
95 "//third_party/libevent",
96 "//third_party/protobuf:protobuf_lite",
97 "//chromeos/ime:gencode",
98 "//components/chrome_apps",
99 "//remoting/host/it2me:common",
107 rebase_path(gypi_values.chrome_browser_extensions_non_chromeos_sources,
114 "api/tabs/ash_panel_contents.cc",
115 "api/tabs/ash_panel_contents.h",
122 "//ui/keyboard:resources",
127 deps += [ "//ui/views" ]
131 configs += [ "//build/config/linux:fontconfig" ]
134 configs += [ "//build/config/linux:x11" ]
136 "//ui/events:events_base",
137 "//ui/events/platform",
138 "//ui/events/platform/x11",
143 if (enable_configuration_policy) {
144 deps += [ "//components/policy" ]
146 "policy_handlers.cc",
149 sources += rebase_path(gypi_values.chrome_browser_extensions_policy_sources,
155 sources += [ "api/webrtc_logging_private/webrtc_logging_private_api.cc" ]
158 [ "api/webrtc_logging_private/webrtc_logging_private_api_stub.cc" ]
162 deps += [ "//build/config/linux:libbrlapi" ]
163 sources += rebase_path(gypi_values.chrome_browser_extensions_brlapi_sources,
167 sources += [ "api/braille_display_private/braille_controller_stub.cc" ]
170 # chromeos uses its own global_shortcut_listener, _x11 is not necessary.
171 if (is_chromeos || !use_x11) {
173 "global_shortcut_listener_x11.cc",
174 "global_shortcut_listener_x11.h",
178 if (is_win || is_mac) {
179 deps += [ "//components/wifi" ]
180 sources += rebase_path(
181 gypi_values.chrome_browser_extensions_networking_private_sources_winmac,
188 "//third_party/iaccessible2",
189 "//third_party/isimpledom",
191 } else if (use_aura && !is_chromeos) {
193 "display_info_provider_aura.cc",
194 "display_info_provider_aura.h",
198 if (enable_app_list) {
200 rebase_path(gypi_values.chrome_browser_extensions_app_list_sources,
205 if (is_chromeos && use_ozone) {
206 sources -= [ "global_shortcut_listener_chromeos.cc" ]
209 sources -= [ "global_shortcut_listener_ozone.cc" ]