Index: remoting/host/linux/BUILD.gn |
diff --git a/remoting/host/linux/BUILD.gn b/remoting/host/linux/BUILD.gn |
index 0745dc5e5fdccb0837297ffb37c017da9d2b313c..2ecb970d31204dd15a6cff086e132dd5c51b05e4 100644 |
--- a/remoting/host/linux/BUILD.gn |
+++ b/remoting/host/linux/BUILD.gn |
@@ -53,14 +53,26 @@ source_set("linux") { |
"//remoting/protocol", |
"//third_party/webrtc/modules/desktop_capture", |
] |
+ public_deps = [] |
if (use_x11) { |
deps += [ ":x11" ] |
} |
+ if (is_desktop_linux) { |
+ if (use_gtk3) { |
+ public_deps += [ "//build/config/linux/gtk3" ] |
+ } else { |
+ public_deps += [ "//build/config/linux/gtk2" ] |
+ } |
+ } |
} |
source_set("x11") { |
sources = [ |
+ "x11_character_injector.cc", |
+ "x11_character_injector.h", |
+ "x11_keyboard_impl.cc", |
+ "x11_keyboard_impl.h", |
"x11_util.cc", |
"x11_util.h", |
"x_server_clipboard.cc", |
@@ -96,3 +108,39 @@ target("executable", "remoting_native_messaging_host") { |
[ "VERSION=" + "$chrome_version_major" + "." + "$remoting_version_patch" + |
"." + "$chrome_version_build" + "." + "$chrome_version_patch" ] |
} |
+ |
+source_set("unit_tests") { |
+ testonly = true |
+ |
+ sources = [ |
+ "audio_pipe_reader_unittest.cc", |
+ "certificate_watcher_unittest.cc", |
+ "unicode_to_keysym_unittest.cc", |
+ "x11_character_injector_unittest.cc", |
+ "x_server_clipboard_unittest.cc", |
+ ] |
+ |
+ if (!use_x11) { |
+ sources -= [ "unicode_to_keysym_unittest.cc" ] |
+ } |
+ |
+ configs += [ "//remoting/build/config:version" ] |
+ |
+ deps = [ |
+ "//remoting/host", |
+ "//remoting/host:test_support", |
+ "//remoting/host/it2me:common", |
+ "//remoting/host/native_messaging", |
+ "//remoting/host/security_key:unit_tests", |
+ "//remoting/host/setup", |
+ "//remoting/proto", |
+ "//remoting/resources", |
+ "//skia", |
+ "//testing/gmock", |
+ "//testing/gtest", |
+ ] |
+ |
+ if (enable_configuration_policy) { |
+ deps += [ "//components/policy/core/browser:test_support" ] |
+ } |
+} |