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("//build/config/ui.gni")
8 gypi_values = exec_script(
9 "//build/gypi_to_gn.py",
10 [ rebase_path("ash.gyp") ],
15 sources = gypi_values.ash_sources
17 defines = [ "ASH_IMPLEMENTATION" ]
24 "//base/third_party/dynamic_annotations",
26 "//components/user_manager",
27 "//content/public/browser",
38 "//ui/events:events_base",
42 "//ui/message_center",
46 "//ui/views/controls/webview",
52 forward_dependent_configs_from = [
59 "sticky_keys/sticky_keys_controller.cc",
60 "sticky_keys/sticky_keys_controller.h",
62 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
63 cflags = [ "/wd4267" ]
68 "//build/config/linux:xfixes",
72 "accelerators/key_hold_detector.cc",
73 "accelerators/key_hold_detector.h",
74 "accelerators/magnifier_key_scroller.cc",
75 "accelerators/magnifier_key_scroller.h",
76 "accelerators/spoken_feedback_toggler.cc",
77 "accelerators/spoken_feedback_toggler.h",
86 #'../chromeos/chromeos.gyp:chromeos', TODO(GYP)
87 # Ash #includes power_supply_properties.pb.h directly.
88 #'../chromeos/chromeos.gyp:power_manager_proto', TODO(GYP)
89 #'../ui/chromeos/ui_chromeos.gyp:ui_chromeos_resources', TODO(GYP)
90 #'../ui/chromeos/ui_chromeos.gyp:ui_chromeos_strings', TODO(GYP)
91 #'../ui/chromeos/ui_chromeos.gyp:ui_chromeos', TODO(GYP)
95 "display/display_configurator_animation.cc",
96 "display/display_configurator_animation.h",
97 "display/resolution_notification_controller.cc",
98 "display/resolution_notification_controller.h",
99 "system/tray/media_security/media_capture_observer.h",
100 "system/tray/media_security/multi_profile_media_tray_item.cc",
101 "system/tray/media_security/multi_profile_media_tray_item.h",
105 if (!use_x11 || !is_chromeos) {
107 "touch/touch_transformer_controller.cc",
108 "touch/touch_transformer_controller.h",
114 "display/mouse_cursor_event_filter_ozone.cc",
120 "host/ash_window_tree_host_ozone.cc",
125 component("ash_with_content") {
127 "content_support/ash_with_content_export.h",
128 "content_support/gpu_support_impl.cc",
129 "content_support/gpu_support_impl.h",
130 "screensaver/screensaver_view.cc",
131 "screensaver/screensaver_view.h",
132 "keyboard_overlay/keyboard_overlay_delegate.cc",
133 "keyboard_overlay/keyboard_overlay_delegate.h",
134 "keyboard_overlay/keyboard_overlay_view.cc",
135 "keyboard_overlay/keyboard_overlay_view.h",
138 defines = [ "ASH_WITH_CONTENT_IMPLEMENTATION" ]
143 "//base/third_party/dynamic_annotations",
144 "//content/public/browser",
156 "//ui/views/controls/webview",
161 forward_dependent_configs_from = [
166 static_library("test_support") {
167 sources = gypi_values.ash_test_support_sources
174 "//ui/accessibility",
181 "test/test_metro_viewer_process_host.cc",
182 "test/test_metro_viewer_process_host.h",
186 #'../ui/metro_viewer/metro_viewer.gyp:metro_viewer_messages', TODO(GYP)
187 #'../win8/win8.gyp:metro_viewer', TODO(GYP)
188 #'../win8/win8.gyp:test_support_win8', TODO(GYP)
189 #'../win8/win8_tests.gyp:test_registrar', TODO(GYP)
194 static_library("ash_shell_lib") {
195 sources = gypi_values.ash_shell_lib_sources
205 #"//chrome:packed_resources", TODO(GYP)
207 "//content/shell:content_shell_lib",
218 "//ui/message_center",
221 "//ui/views:test_support",
222 #'../ui/views/examples/examples.gyp:views_examples_lib', TODO(GYP)
223 #'../ui/views/examples/examples.gyp:views_examples_with_content_lib', TODO(GYP)
227 if (false) { # TODO(GYP) enable ash shell and unit tests when they link.
229 test("ash_unittests") {
230 sources = gypi_values.ash_unittests_sources
240 "//base/test:test_support",
241 "//components/user_manager",
242 "//content/public/browser",
243 "//content/test:test_support",
247 "//ui/accessibility",
249 "//ui/aura:test_support",
251 "//ui/base:test_support",
253 "//ui/compositor:test_support",
255 "//ui/events:test_support",
256 "//ui/events:gesture_detection",
260 "//ui/message_center",
261 "//ui/message_center:test_support",
264 "//ui/views:test_support",
265 "//ui/views/controls/webview:test_support",
273 # TODO(zork): fix this test to build on Windows. See: crosbug.com/26906
274 "focus_cycler_unittest.cc",
275 # All tests for multiple displays: not supported on Windows Ash.
276 "accelerators/nested_dispatcher_controller_unittest.cc",
277 "wm/drag_window_resizer_unittest.cc",
278 # Can't resize on Windows Ash. http://crbug.com/165962
279 "ash_root_window_transformer_unittest.cc",
280 "magnifier/magnification_controller_unittest.cc",
281 "wm/workspace/workspace_window_resizer_unittest.cc",
282 "sticky_keys/sticky_keys_overlay_unittest.cc",
283 "sticky_keys/sticky_keys_unittest.cc",
284 "system/tray/media_security/multi_profile_media_tray_item_unittest.cc",
285 "autoclick/autoclick_unittest.cc",
288 #'<(SHARED_INTERMEDIATE_DIR)/ui/resources/ui_unscaled_resources.rc', TODO(GYP)
293 cflags = [ "/wd4267" ]
298 "accelerators/magnifier_key_scroller_unittest.cc",
299 "accelerators/spoken_feedback_toggler_unittest.cc",
300 "touch/touch_transformer_controller_unittest.cc",
304 sources += [ "first_run/first_run_helper_unittest.cc" ]
306 "//device/bluetooth",
308 "//ui/display:test_util",
309 "//ui/display/types",
310 #'../chromeos/chromeos.gyp:chromeos_test_support_without_gmock', TODO(GYP)
311 #'../chromeos/chromeos.gyp:power_manager_proto', TODO(GYP)
315 "display/resolution_notification_controller_unittest.cc",
316 "touch/touch_transformer_controller_unittest.cc",
320 # TODO(GYP) is this necessary?
321 #['OS=="linux" and component=="shared_library" and use_allocator!="none"', {
322 # ldflags = "-rdynamic"
326 "sticky_keys/sticky_keys_unittest.cc", # crbug.com/354035
331 executable("ash_shell") {
333 "shell/shell_main.cc",
338 "//components/user_manager",
342 configs -= [ "//build/config/win:console" ]
343 configs += [ "//build/config/win:windowed" ]
351 "../device/bluetooth/bluetooth.gyp:device_bluetooth",
356 test("ash_shell_unittests") {
358 "shell/window_watcher_unittest.cc",
359 "test/ash_unittests.cc",
363 "//base/test:test_support",
364 "//components/user_manager",
365 "//content/test:test_support",
368 "//ui/aaccessibility",
372 deps += [ "//ui/display" ]