BUILD.gn 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. # Copyright 2016 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.
  4. import("//build/config/features.gni")
  5. import("//chrome/version.gni")
  6. import("//remoting/remoting_options.gni")
  7. if (is_win) {
  8. import("//remoting/host/installer/win/generate_clsids.gni")
  9. import("//remoting/host/predefines_win.gni")
  10. }
  11. # TODO(nicholss): Move this and other defines to version.h.in.
  12. # Various remoting targets need this version definition.
  13. config("version") {
  14. defines = [
  15. "VERSION=$chrome_version_full",
  16. "VERSION_MAJOR=$chrome_version_major",
  17. "VERSION_BUILD=$chrome_version_build",
  18. "VERSION_PATCH=$chrome_version_patch",
  19. ]
  20. }
  21. config("remoting_me2me_host") {
  22. defines = []
  23. if (is_win && remoting_multi_process != 0 && remoting_rdp_session != 0) {
  24. defines += [ "REMOTING_RDP_SESSION" ]
  25. }
  26. if (remoting_multi_process != 0) {
  27. defines += [ "REMOTING_MULTI_PROCESS" ]
  28. }
  29. }
  30. config("host_implementation") {
  31. defines = []
  32. if (is_win || is_linux) {
  33. defines += [ "HOST_IMPLEMENTATION" ]
  34. }
  35. if (is_win) {
  36. defines += host_predefines
  37. defines += [
  38. "_ATL_APARTMENT_THREADED",
  39. "_ATL_CSTRING_EXPLICIT_CONSTRUCTORS",
  40. "_ATL_NO_AUTOMATIC_NAMESPACE",
  41. "_ATL_NO_EXCEPTIONS",
  42. "REMOTING_HOST_BINARY=BINARY_CORE",
  43. "RDP_DESKTOP_SESSION_CLSID=\"$rdp_desktop_session_clsid\"",
  44. "HOST_IMPLEMENTATION",
  45. "ISOLATION_AWARE_ENABLED=1",
  46. "STRICT",
  47. ]
  48. if (is_chrome_branded && is_official_build) {
  49. defines += [ "REMOTING_ENABLE_BREAKPAD" ]
  50. }
  51. if (remoting_multi_process != 0 && remoting_rdp_session != 0) {
  52. defines += [ "REMOTING_RDP_SESSION" ]
  53. }
  54. if (remoting_multi_process != 0) {
  55. defines += [ "REMOTING_MULTI_PROCESS" ]
  56. }
  57. }
  58. }