Commit 26a1704c authored by Andrey Kosyakov's avatar Andrey Kosyakov Committed by Commit Bot

Revert "X11 and Ozone: enable use_x11 and use_ozone"

This reverts commit f985905e.

Reason for revert: break headless build.
Repro: mkdir ./out/headless && echo 'import("//build/args/headless.gn")' > out/headless/args.gn && gn gen ./out/headless

Waiting for editor on "/usr/local/google/home/caseq/cr/src/out/headless/args.gn"...
Generating files...
ERROR at //ui/events/platform/x11/BUILD.gn:51:5: Assertion failed.
    assert(ozone_platform_x11)
    ^-----
See //components/viz/demo/BUILD.gn:73:7: which caused the file to be included.
      "//ui/events/platform/x11",
      ^-------------------------

Original change's description:
> X11 and Ozone: enable use_x11 and use_ozone
> 
> This is the final change that enables use_x11
> and use_ozone for Linux builds and (as it was
> before) excludes X11 for chromeos, chromecast,
> lacros.
> 
> in order to run ozone/X11/wayland, one must pass
> —enable-features=UseOzonePlatform
> —ozone-platform=x11 or wayland. otherwise,
> non-ozone/X11 is used.
> 
> it’s also possible to completely disable X11
> so that clients, who need that kind of build can
> continue to have that.
> 
> Bug: 1085700
> Change-Id: I171bcb53c406555a1d4bec3e88d76dc676310d48
> Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2315869
> Reviewed-by: Thomas Anderson <thomasanderson@chromium.org>
> Reviewed-by: Robert Kroeger <rjkroege@chromium.org>
> Reviewed-by: Scott Violet <sky@chromium.org>
> Commit-Queue: Maksim Sisov (GMT+3) <msisov@igalia.com>
> Cr-Commit-Position: refs/heads/master@{#801523}

TBR=rjkroege@chromium.org,sky@chromium.org,thomasanderson@chromium.org,msisov@igalia.com

Change-Id: Id1f451c6b8a9aeeaa48a8d12da2776b8676aca09
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: 1085700
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2376482Reviewed-by: default avatarAndrey Kosyakov <caseq@chromium.org>
Commit-Queue: Andrey Kosyakov <caseq@chromium.org>
Cr-Commit-Position: refs/heads/master@{#801565}
parent 72db5cf8
...@@ -18,19 +18,11 @@ ...@@ -18,19 +18,11 @@
# of //build/config/BUILDCONFIG.gn. # of //build/config/BUILDCONFIG.gn.
import("//build/config/chromecast_build.gni") import("//build/config/chromecast_build.gni")
import("//build/config/chromeos/ui_mode.gni")
declare_args() { declare_args() {
# Indicates if Ozone is enabled. Ozone is a low-level library layer for Linux # Indicates if Ozone is enabled. Ozone is a low-level library layer for Linux
# that does not require X11. # that does not require X11. Enabling this feature disables use of x11.
use_ozone = use_ozone = is_chromeos || (is_chromecast && !is_android) || is_fuchsia
is_chromeos || (is_chromecast && !is_android) || is_fuchsia || is_linux
# Indicates if the UI toolkit depends on X11.
# Enabled by default. Can be disabled if Ozone only build is required and
# vice-versa.
use_x11 =
is_linux && !is_chromecast && !is_chromeos && !chromeos_is_browser_only
# Indicates if Aura is enabled. Aura is a low-level windowing library, sort # Indicates if Aura is enabled. Aura is a low-level windowing library, sort
# of a replacement for GDI or GTK. # of a replacement for GDI or GTK.
...@@ -45,6 +37,13 @@ declare_args() { ...@@ -45,6 +37,13 @@ declare_args() {
use_glib = is_desktop_linux && !is_chromecast use_glib = is_desktop_linux && !is_chromecast
} }
# Additional dependent variables -----------------------------------------------
#
# These variables depend on other variables and can't be set externally.
# Indicates if the UI toolkit depends on X11.
use_x11 = is_linux && !use_ozone
# Make sure glib is not used if building for ChromeOS/Chromecast # Make sure glib is not used if building for ChromeOS/Chromecast
assert(!use_glib || (is_linux && !is_chromeos && !is_chromecast)) assert(!use_glib || (is_linux && !is_chromeos && !is_chromecast))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment