Announcing Chrome/Linux + Ozone/Mus project

178 views
Skip to first unread message

Antonio Gomes

unread,
May 15, 2017, 10:13:41 AM5/15/17
to ozon...@chromium.org, Tom Anderson, s...@chromium.org
Hi all.

Since mid January, Igalia has been working on a project whose goal was
to make the latest Chromium browser capable of running on top of the
Ozone backends suitable for Linux desktop environments.

https://github.com/Igalia/chromium/tree/ozone-wayland-dev#chromium-for-wayland

Note that some attempts were taken to add Wayland support to Chromium
previously [0]. Although it had a good community support and results, it
got stalled and the latest officially supported Chromium baseline was m49.

Additionally, the way Ozone/Wayland tackled the problem was by extending
the classes responsible for desktop integration
(//ui/views/widget/desktop_aura/) with a Wayland implementation, sibling
to the existing X11 and Windows supports.

This new effort extends the existing Mus machinery in a way that
Chromium can be executed on non-ChromeOS environments without any
functionality loss when compared to regular Linux/X11 Chromium builds.
Additionally, the project is based on the idea of keeping the Chromium
baseline always as close as possible to upstream development, as well as
aligned with Google's own plans.

UI service and Ozone
----------------------

Ozone [1] is an abstraction layer underneath the UI Service - aka Mus.
It aims to abstract away windowing, graphics and input handling details
from its upper layers, using a well defined set of interfaces. The Mus +
Ozone combination allows Mus to run on top of various graphics backends
Ozone supports - namely DRM/GBM, X11, Wayland and Headless.

In that context, the mus+ash project [2] makes it possible to launch the
Ash desktop environment on top of Mus. Today, for instance,
Ozone/ChromeOS builds of Chrome are supported, and this new setup can be
trigerred by passing either --mash or --mus parameters.

$ <out>/chrome --mash --ozone-platform={x11 | wayland | etc}
--user-data-dir=~/tmp

Or

$ <out>/chrome --mus --ozone-platform={x11 | wayland | etc}
--user-data-dir=~/tmp

The above commands launch the "mash" environment, a ChromeOS oriented
Window Manager for applications (including the Chrome browser itself) to
run in what we have been calling "internal window" mode. In this mode,
applications do not "talk" directly to the host Window Manager. Instead,
all windowing management is handled by the Mash Window Manager and
Aura/Mus - see the screenshot [3] below for reference - and all the aura
windows in the system end up sharing a single display.

[0] https://github.com/01org/ozone-wayland
[1]
https://chromium.googlesource.com/chromium/src/+/master/docs/ozone_overview.md
[2] https://www.chromium.org/developers/mus-ash
[3] https://people.igalia.com/agomes/mus+ash/chrome_mash_ozone_x11_may08.png

External window mode support
-----------------------------

In order to make the Chromium browser to be capable of launching on
Ozone/LinuxOS targets, both Mus and Ozone are needed to be extended to
launch Chromium in "external window mode", a regular desktop application
similar to the exiting Linux/X11 Chromium builds (kudos rjkroege@ for
the terminology here :).

Thanks to the way Ozone is implemented, adding "external window mode"
support to Mus allows us to precisely meet our primarily goal: make it
possible to run the same Chromium browser binary natively one either X11
or Wayland based environments, through Ozone.

The project
-----------

In order to expedite a working prototype, we decided to host the project
on GitHub [4], but the ideal goal is to upstream the work once current
upstream priorities regarding Mash stabilize. Please see the details
about how to build/run in [4].

Today's project snapshot [5][6], for instance, runs on top of Chromium
ToT as of (May/15) - see also details about rebase strategy in [4]. To
put it short, we rebase against ToT on a weekly basis.

[4]
https://github.com/Igalia/chromium/tree/ozone-wayland-dev#chromium-for-wayland
[5] https://www.youtube.com/watch?v=tb027dDkg7E
[6] https://www.youtube.com/watch?v=D6jAucPocmg

Comments welcome,


Contacts:
Antonio Gomes <toni...@igalia.com>
Maksim Sisov <msi...@igalia.com>
Frédéric Wang <fw...@igalia.com>

-
Antonio

Bo

unread,
May 15, 2017, 11:31:21 AM5/15/17
to Ozone-Dev, thomasa...@google.com, s...@chromium.org
That sounds an exiting news. Thanks for the efforts!
Without a try, does content shell also work with the implementation?

Best regards,
Bo

Antonio Gomes

unread,
May 17, 2017, 11:48:48 AM5/17/17
to Bo, Ozone-Dev, Tom Anderson, Scott Violet
Hi Bo. Thanks for checking.

I believe content_shell would work on if/when the content module is
"ported" to work with Mus, which I do not think it is the case today.

To my understanding for content_shell to run on Wayland, it would need
to take the Ozone code path. Ozone today is an abstraction layer
underneath the Mus component, not underneath Aura or Views directly
(as it once was?).

But I think this is a pertinent question nevertheless. From an
Chromium embedder perspective (e.g. CEF), the content API is still the
main embedding entry point. In order to be able to embed Chromium's
browser engine (not the browser) into apps that target systems
different than X11, the Content module would need to run with Ozone
(i.e. Mus).

Lets see what others say.
> --
> You received this message because you are subscribed to the Google Groups
> "Ozone-Dev" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to ozone-dev+...@chromium.org.



--
--Antonio Gomes
Reply all
Reply to author
Forward
0 new messages