Index: services/ui/ws/BUILD.gn |
diff --git a/services/ui/ws/BUILD.gn b/services/ui/ws/BUILD.gn |
index 7408a083aa3096666fb3d6b3e14aa045de381222..3cfa81745aa0652951b81a023b1b007deda2942b 100644 |
--- a/services/ui/ws/BUILD.gn |
+++ b/services/ui/ws/BUILD.gn |
@@ -9,6 +9,8 @@ import("//services/service_manager/public/cpp/service.gni") |
import("//services/service_manager/public/service_manifest.gni") |
import("//services/service_manager/public/tools/test/service_test.gni") |
+is_external_mode = use_ozone && !is_chromeos |
msw
2017/03/09 16:51:22
nit: add a comment explaining what this is, eg. "T
fwang
2017/03/09 21:52:49
Done.
|
+ |
static_library("lib") { |
sources = [ |
"accelerator.cc", |
@@ -171,10 +173,18 @@ static_library("test_support") { |
"test_change_tracker.h", |
"window_server_service_test_base.cc", |
"window_server_service_test_base.h", |
- "window_server_test_base.cc", |
- "window_server_test_base.h", |
] |
+ if (!is_external_mode) { |
+ # WindowServerTestBase assumes an initial display (and root) is provided |
+ # at startup, which is not the case on platforms running external window |
+ # mode. |
+ sources += [ |
+ "window_server_test_base.cc", |
+ "window_server_test_base.h", |
+ ] |
+ } |
+ |
deps = [ |
"//base", |
"//base/test:test_config", |
@@ -223,12 +233,17 @@ service_test("mus_ws_unittests") { |
"user_display_manager_unittest.cc", |
"window_coordinate_conversions_unittest.cc", |
"window_finder_unittest.cc", |
- "window_manager_client_unittest.cc", |
"window_manager_state_unittest.cc", |
"window_tree_client_unittest.cc", |
"window_tree_unittest.cc", |
] |
+ if (!is_external_mode) { |
+ # A window manager client is not needed on platforms running external |
+ # window mode, since the host system is always the window manager. |
+ sources += [ "window_manager_client_unittest.cc" ] |
+ } |
+ |
catalog = ":mus_ws_unittests_catalog" |
deps = [ |