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")
7 import("//testing/test.gni")
9 gypi_values = exec_script("//build/gypi_to_gn.py",
10 [ rebase_path("ash.gyp") ],
15 sources = gypi_values.ash_sources
17 configs += [ "//build/config:precompiled_headers" ]
18 defines = [ "ASH_IMPLEMENTATION" ]
27 "//base/third_party/dynamic_annotations",
29 "//components/device_event_log",
30 "//components/user_manager",
31 "//components/wallpaper",
32 "//content/public/browser",
44 "//ui/events:events_base",
45 "//ui/events:gesture_detection",
46 "//ui/events/devices",
50 "//ui/message_center",
54 "//ui/views/controls/webview",
62 "sticky_keys/sticky_keys_controller.cc",
63 "sticky_keys/sticky_keys_controller.h",
66 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
67 configs += [ "//build/config/compiler:no_size_t_to_int_warning" ]
72 "//build/config/linux:x11",
73 "//build/config/linux:xfixes",
76 "//ui/events/platform",
81 "host/ash_window_tree_host_x11.cc",
82 "host/ash_window_tree_host_x11.h",
83 "wm/maximize_mode/scoped_disable_internal_mouse_and_keyboard_x11.cc",
84 "wm/maximize_mode/scoped_disable_internal_mouse_and_keyboard_x11.h",
90 "//ui/events/ozone:events_ozone",
101 "//chromeos:power_manager_proto",
102 "//third_party/qcms",
103 "//ui/chromeos/resources",
104 "//ui/chromeos/strings",
105 "//ui/chromeos:ui_chromeos",
109 "accelerators/key_hold_detector.cc",
110 "accelerators/key_hold_detector.h",
111 "accelerators/magnifier_key_scroller.cc",
112 "accelerators/magnifier_key_scroller.h",
113 "accelerators/spoken_feedback_toggler.cc",
114 "accelerators/spoken_feedback_toggler.h",
115 "display/display_configurator_animation.cc",
116 "display/display_configurator_animation.h",
117 "display/resolution_notification_controller.cc",
118 "display/resolution_notification_controller.h",
119 "system/tray/media_security/media_capture_observer.h",
120 "system/tray/media_security/multi_profile_media_tray_item.cc",
121 "system/tray/media_security/multi_profile_media_tray_item.h",
122 "touch/touch_transformer_controller.cc",
123 "touch/touch_transformer_controller.h",
124 "touch/touchscreen_util.cc",
125 "touch/touchscreen_util.h",
126 "virtual_keyboard_controller.cc",
127 "virtual_keyboard_controller.h",
133 "host/ash_window_tree_host_ozone.cc",
134 "wm/maximize_mode/scoped_disable_internal_mouse_and_keyboard_ozone.cc",
135 "wm/maximize_mode/scoped_disable_internal_mouse_and_keyboard_ozone.h",
140 component("ash_with_content") {
142 "content_support/ash_with_content_export.h",
143 "content_support/gpu_support_impl.cc",
144 "content_support/gpu_support_impl.h",
145 "keyboard_overlay/keyboard_overlay_delegate.cc",
146 "keyboard_overlay/keyboard_overlay_delegate.h",
147 "keyboard_overlay/keyboard_overlay_view.cc",
148 "keyboard_overlay/keyboard_overlay_view.h",
151 defines = [ "ASH_WITH_CONTENT_IMPLEMENTATION" ]
158 "//base/third_party/dynamic_annotations",
159 "//content/public/browser",
171 "//ui/views/controls/webview",
177 source_set("test_support") {
179 sources = gypi_values.ash_test_support_sources
180 configs += [ "//build/config:precompiled_headers" ]
187 "//content/test:test_support",
190 "//ui/accessibility",
192 "//ui/app_list:test_support",
193 "//ui/events:events_base",
194 "//ui/events/devices",
197 "//ui/views:test_support",
202 "test/test_metro_viewer_process_host.cc",
203 "test/test_metro_viewer_process_host.h",
208 "//ui/platform_window/win",
209 "//win8:metro_viewer",
210 "//win8:test_support_win8",
211 "//win8:test_registrar",
216 source_set("interactive_ui_test_support") {
218 configs += [ "//build/config:precompiled_headers" ]
224 "test/ash_interactive_ui_test_base.cc",
225 "test/ash_interactive_ui_test_base.h",
235 static_library("ash_shell_lib") {
237 sources = gypi_values.ash_shell_lib_sources
248 #"//chrome:packed_resources", TODO(GYP)
250 "//content/shell:content_shell_lib",
260 "//ui/events:events_base",
264 "//ui/message_center",
267 "//ui/views:test_support",
268 "//ui/views/examples:views_examples_lib",
269 "//ui/views/examples:views_examples_with_content_lib",
273 test("ash_unittests") {
274 sources = gypi_values.ash_unittests_sources
275 configs += [ "//build/config:precompiled_headers" ]
285 "//base/test:test_support",
286 "//components/user_manager",
287 "//content/public/browser",
288 "//content/test:test_support",
292 "//ui/accessibility",
294 "//ui/aura:test_support",
297 "//ui/base:test_support",
299 "//ui/compositor:test_support",
301 "//ui/events/devices",
302 "//ui/events:test_support",
303 "//ui/events:gesture_detection",
307 "//ui/message_center",
308 "//ui/message_center:test_support",
311 "//ui/views:test_support",
312 "//ui/views/controls/webview:test_support",
313 "//ui/web_dialogs:test_support",
320 # TODO(zork): fix this test to build on Windows. See: crosbug.com/26906
321 "focus_cycler_unittest.cc",
323 # All tests for multiple displays: not supported on Windows Ash.
324 "wm/drag_window_resizer_unittest.cc",
326 # Accelerometer is only available on Chrome OS.
327 "wm/maximize_mode/maximize_mode_controller_unittest.cc",
329 # Can't resize on Windows Ash. http://crbug.com/165962
330 "autoclick/autoclick_unittest.cc",
331 "magnifier/magnification_controller_unittest.cc",
332 "sticky_keys/sticky_keys_overlay_unittest.cc",
333 "system/tray/media_security/multi_profile_media_tray_item_unittest.cc",
334 "virtual_keyboard_controller_unittest.cc",
335 "wm/workspace/workspace_window_resizer_unittest.cc",
338 #'<(SHARED_INTERMEDIATE_DIR)/ui/resources/ui_unscaled_resources.rc', TODO(GYP)
342 configs += [ "//build/config/compiler:no_size_t_to_int_warning" ]
345 sources -= [ "host/ash_window_tree_host_x11_unittest.cc" ]
348 sources += [ "first_run/first_run_helper_unittest.cc" ]
350 "//device/bluetooth",
352 "//ui/display:test_util",
353 "//ui/display/types",
354 "//chromeos:power_manager_proto",
355 "//chromeos:test_support_without_gmock",
359 "accelerators/magnifier_key_scroller_unittest.cc",
360 "accelerators/spoken_feedback_toggler_unittest.cc",
361 "display/resolution_notification_controller_unittest.cc",
362 "touch/touchscreen_util_unittest.cc",
366 if (!use_x11 || !is_chromeos) {
367 sources -= [ "touch/touch_transformer_controller_unittest.cc" ]
370 # TODO(GYP) is this necessary?
371 #['OS=="linux" and component=="shared_library" and use_allocator!="none"', {
372 # ldflags = "-rdynamic"
375 sources -= [ "sticky_keys/sticky_keys_unittest.cc" ]
379 executable("ash_shell") {
382 "shell/shell_main.cc",
387 "//build/config/sanitizers:deps",
388 "//components/user_manager",
392 configs -= [ "//build/config/win:console" ]
393 configs += [ "//build/config/win:windowed" ]
394 deps += [ "//sandbox" ]
398 deps += [ "//device/bluetooth" ]
401 # When adding support for isolates, please have a look at run-time dependencies
402 # in the ash_unittests_run target in ash.gyp.