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,
24 configs += [ "//build/config:precompiled_headers" ]
27 # Since browser and browser_extensions actually depend on each other,
28 # we must omit the dependency from browser_extensions to browser.
29 # However, this means browser_extensions and browser should more or less
30 # have the same dependencies. Once browser_extensions is untangled from
31 # browser, then we can clean up these dependencies.
33 "//chrome/common/extensions/api",
34 "//content/public/browser",
37 "//chrome:extra_resources",
40 "//chrome/app/resources:platform_locale_settings",
41 "//chrome/app/theme:theme_resources",
42 "//chrome/browser/devtools",
44 "//chrome/common/extensions/api:api_registration",
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/protobuf:protobuf_lite",
96 "//chromeos/ime:gencode",
97 "//components/chrome_apps",
98 "//remoting/host/it2me:common",
106 rebase_path(gypi_values.chrome_browser_extensions_non_chromeos_sources,
113 "api/tabs/ash_panel_contents.cc",
114 "api/tabs/ash_panel_contents.h",
121 "//ui/keyboard:resources",
126 deps += [ "//ui/views" ]
130 configs += [ "//build/config/linux:fontconfig" ]
133 configs += [ "//build/config/linux:x11" ]
135 "//ui/events:events_base",
136 "//ui/events/platform",
137 "//ui/events/platform/x11",
142 if (enable_configuration_policy) {
143 deps += [ "//components/policy" ]
145 "policy_handlers.cc",
148 sources += rebase_path(gypi_values.chrome_browser_extensions_policy_sources,
154 sources += [ "api/webrtc_logging_private/webrtc_logging_private_api.cc" ]
157 [ "api/webrtc_logging_private/webrtc_logging_private_api_stub.cc" ]
161 deps += [ "//build/linux:libbrlapi" ]
162 sources += rebase_path(gypi_values.chrome_browser_extensions_brlapi_sources,
166 sources += [ "api/braille_display_private/braille_controller_stub.cc" ]
169 # chromeos uses its own global_shortcut_listener, _x11 is not necessary.
170 if (is_chromeos || !use_x11) {
172 "global_shortcut_listener_x11.cc",
173 "global_shortcut_listener_x11.h",
177 if (is_win || is_mac) {
178 deps += [ "//components/wifi" ]
179 sources += rebase_path(
180 gypi_values.chrome_browser_extensions_networking_private_sources_winmac,
187 "//third_party/iaccessible2",
188 "//third_party/isimpledom",
190 } else if (use_aura && !is_chromeos) {
192 "display_info_provider_aura.cc",
193 "display_info_provider_aura.h",
197 if (enable_app_list) {
199 rebase_path(gypi_values.chrome_browser_extensions_app_list_sources,
204 if (is_chromeos && use_ozone) {
205 sources -= [ "global_shortcut_listener_chromeos.cc" ]
208 sources -= [ "global_shortcut_listener_ozone.cc" ]