Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1826)

Unified Diff: build/config/ui.gni

Issue 160143002: Hook up more GN toolkit and UI-based flags. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « build/config/linux/BUILD.gn ('k') | tools/gn/secondary/chrome/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/config/ui.gni
diff --git a/build/config/ui.gni b/build/config/ui.gni
new file mode 100644
index 0000000000000000000000000000000000000000..b9969c06e36a4ca6707e32791b90ba67aa04ea94
--- /dev/null
+++ b/build/config/ui.gni
@@ -0,0 +1,61 @@
+# Copyright 2014 The Chromium Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+# This file contains UI-related build flags. It should theoretically be in the
+# src/ui directory and only things that depend on the ui module should get the
+# definitions.
+#
+# However, today we have many "bad" dependencies on some of these flags from,
+# e.g. base, so they need to be global.
+
+declare_args() {
+ # True means the UI is built useing the "views" framework.
+ toolkit_views = false
+
+ # Indicates if Ash is enabled. Ash is the Aura SHell which provides a
+ # desktop-like environment for Aura. Requires use_aura = true
+ use_ash = false
+
+ # Indicates if Aura is enabled. Aura is a low-level windowing library, sort
+ # of a replacement for GDI or GTK.
+ use_aura = false
+
+ # Indicates if Ozone is enabled. Ozone is a low-level library layer for Linux
+ # that does not require X11.
+ use_ozone = false
+}
+
+if (is_win || is_chromeos) {
+ # Windows currelty implies Aura.
+ # TODO(brettw) bug 342937 move to declare_args block.
+ use_ash = true
+ use_aura = true
+}
+
+if (is_linux || use_ozone) {
+ use_aura = true
+}
+
+if (!use_aura) {
+ use_ash = false # Ash needs Aura.
+}
+
+# TODO(brettw) bug 342937 move this to the declare_args block above when this
+# is supported. It would look like:
+# toolkit_views = is_win || is_chromeos || use_aura
+if (is_win || is_chromeos || use_aura) {
+ toolkit_views = true
+}
+
+# Additional dependent variables -----------------------------------------------
+#
+# These variables depend on other variables and can't be set externally.
+
+# Indicates if the UI toolkit depends on GTK.
+toolkit_uses_gtk = is_linux && !is_chromeos && !use_aura && !use_ozone
+
+# Indicates if the UI toolkit depends on X11.
+use_x11 = is_linux && !use_ozone
+
+use_glib = is_linux
« no previous file with comments | « build/config/linux/BUILD.gn ('k') | tools/gn/secondary/chrome/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698