[email protected] | f38dc10 | 2014-02-12 11:34:25 | [diff] [blame] | 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 | |||||
brettw | 1d61ea7 | 2016-08-06 00:03:45 | [diff] [blame] | 5 | # ============================================= |
6 | # PLEASE DO NOT ADD MORE FLAGS TO THIS FILE | ||||
7 | # ============================================= | ||||
[email protected] | f38dc10 | 2014-02-12 11:34:25 | [diff] [blame] | 8 | # |
brettw | 1d61ea7 | 2016-08-06 00:03:45 | [diff] [blame] | 9 | # These flags are effectively global. Your feature flag should go near the |
10 | # code it controls. Most of these items are here now because they control | ||||
11 | # legacy global #defines passed to the compiler (now replaced with generated | ||||
12 | # buildflag headers -- see //build/buildflag_header.gni). | ||||
[email protected] | 3ad0946b | 2014-02-24 21:29:49 | [diff] [blame] | 13 | # |
brettw | 1d61ea7 | 2016-08-06 00:03:45 | [diff] [blame] | 14 | # These flags are ui-related so should eventually be moved to various places |
15 | # in //ui/*. | ||||
16 | # | ||||
17 | # There is more advice on where to put build flags in the "Build flag" section | ||||
18 | # of //build/config/BUILDCONFIG.gn. | ||||
[email protected] | f38dc10 | 2014-02-12 11:34:25 | [diff] [blame] | 19 | |
slan | 77bdc2e6 | 2015-09-21 17:56:26 | [diff] [blame] | 20 | import("//build/config/chromecast_build.gni") |
Yuke Liao | 8f422858 | 2021-04-02 22:28:45 | [diff] [blame] | 21 | import("//build/config/chromeos/args.gni") |
Dirk Pranke | 79d065d | 2020-08-29 03:28:30 | [diff] [blame] | 22 | import("//build/config/chromeos/ui_mode.gni") |
Maksim Sisov | cecaf7e | 2021-09-01 08:01:45 | [diff] [blame^] | 23 | import("//build/config/ozone.gni") |
slan | 77bdc2e6 | 2015-09-21 17:56:26 | [diff] [blame] | 24 | |
[email protected] | f38dc10 | 2014-02-12 11:34:25 | [diff] [blame] | 25 | declare_args() { |
[email protected] | c48ad0b | 2014-02-19 20:31:52 | [diff] [blame] | 26 | # Indicates if Aura is enabled. Aura is a low-level windowing library, sort |
27 | # of a replacement for GDI or GTK. | ||||
Sean McAllister | deaa740 | 2020-07-31 04:42:54 | [diff] [blame] | 28 | use_aura = is_win || is_linux || is_chromeos || is_fuchsia |
[email protected] | f38dc10 | 2014-02-12 11:34:25 | [diff] [blame] | 29 | } |
30 | |||||
dpranke | f6fd4d7 | 2016-11-22 19:43:13 | [diff] [blame] | 31 | declare_args() { |
32 | # True means the UI is built using the "views" framework. | ||||
Sean McAllister | deaa740 | 2020-07-31 04:42:54 | [diff] [blame] | 33 | toolkit_views = is_mac || is_win || is_linux || is_chromeos || is_fuchsia |
Nick Diego Yamane | 632978e0 | 2019-08-14 22:35:41 | [diff] [blame] | 34 | |
Eriko Kurimoto | 037063d | 2021-06-29 01:26:40 | [diff] [blame] | 35 | use_glib = is_linux && !is_chromecast |
dpranke | f6fd4d7 | 2016-11-22 19:43:13 | [diff] [blame] | 36 | } |
37 | |||||
Eriko Kurimoto | 037063d | 2021-06-29 01:26:40 | [diff] [blame] | 38 | assert(!use_glib || (is_linux && !is_chromecast)) |
dpranke | 9de1743 | 2015-06-09 19:04:57 | [diff] [blame] | 39 | |
Maksim Sisov | cecaf7e | 2021-09-01 08:01:45 | [diff] [blame^] | 40 | use_atk = is_linux && !is_chromecast && use_glib && |
41 | current_toolchain == default_toolchain | ||||
Dirk Pranke | 79d065d | 2020-08-29 03:28:30 | [diff] [blame] | 42 | |
43 | # Whether using Xvfb to provide a display server for a test might be | ||||
44 | # necessary. | ||||
Yuke Liao | 8f422858 | 2021-04-02 22:28:45 | [diff] [blame] | 45 | use_xvfb_in_this_config = |
46 | is_linux || (is_chromeos_lacros && !is_chromeos_device) | ||||
Dirk Pranke | 79d065d | 2020-08-29 03:28:30 | [diff] [blame] | 47 | # |
brettw | 1d61ea7 | 2016-08-06 00:03:45 | [diff] [blame] | 48 | # ============================================= |
49 | # PLEASE DO NOT ADD MORE FLAGS TO THIS FILE | ||||
50 | # ============================================= | ||||
51 | # | ||||
52 | # See comment at the top. |