ui.gni 1.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  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.
  4. # =============================================
  5. # PLEASE DO NOT ADD MORE FLAGS TO THIS FILE
  6. # =============================================
  7. #
  8. # These flags are effectively global. Your feature flag should go near the
  9. # code it controls. Most of these items are here now because they control
  10. # legacy global #defines passed to the compiler (now replaced with generated
  11. # buildflag headers -- see //build/buildflag_header.gni).
  12. #
  13. # These flags are ui-related so should eventually be moved to various places
  14. # in //ui/*.
  15. #
  16. # There is more advice on where to put build flags in the "Build flag" section
  17. # of //build/config/BUILDCONFIG.gn.
  18. import("//build/config/chromecast_build.gni")
  19. import("//build/config/chromeos/args.gni")
  20. import("//build/config/chromeos/ui_mode.gni")
  21. import("//build/config/ozone.gni")
  22. declare_args() {
  23. # Indicates if Aura is enabled. Aura is a low-level windowing library, sort
  24. # of a replacement for GDI or GTK.
  25. use_aura = is_win || is_linux || is_chromeos || is_fuchsia
  26. }
  27. declare_args() {
  28. # True means the UI is built using the "views" framework.
  29. toolkit_views = is_mac || is_win || is_linux || is_chromeos || is_fuchsia
  30. use_glib =
  31. is_linux && !is_castos &&
  32. # Avoid the need for glib when Android is building things via secondary
  33. # toolchains.
  34. target_os != "android"
  35. }
  36. assert(!use_glib || (is_linux && !is_castos))
  37. use_atk = use_glib && current_toolchain == default_toolchain
  38. # Whether using Xvfb to provide a display server for a test might be
  39. # necessary.
  40. use_xvfb_in_this_config =
  41. is_linux || (is_chromeos_lacros && !is_chromeos_device)
  42. #
  43. # =============================================
  44. # PLEASE DO NOT ADD MORE FLAGS TO THIS FILE
  45. # =============================================
  46. #
  47. # See comment at the top.