Note: The issues described below have been resolved: Unity8 can run on 18.04. (There are still issues to be resolved, but the following is now only of historical interests.)

Background

As mention recently Unity8 has two problem areas running on Ubuntu 18.04LTS.

Mir-on-Mir doesn't work. This means that the configuration used previously of lightdm starting unity-system-compositor (to handle the "hardware") and Unity8 connecting to unity-system-compositor doesn't work. Client applications that use libmirclient cannot use EGL (only applications that use software rendering will work).

Note that these are not Ubuntu specific, they are the same issues that prevent Unity8 running on other distros.

I think the way ahead is:

Don't use Mir-on-Mir

With a bit of tweaking to Mir Unity8 will be able to run under the GNOME Display Manager [GDM]. The Mir team is aiming to have the necessary tweaks in place for the 18.04 release along with an example "Mir" desktop session.

Until the Mir changes are available this approach can be "faked". Switch to a virtual terminal, log in and type the following:

$ sudo chown -R $USER /dev/input $ QML_BAD_GUI_RENDER_LOOP=1 QT_QPA_PLATFORM=mirserver unity8

(Thanks to @malditobastardo from the "UBports Unity8 Dev" group who volunteered to test this.)

Applications should use Wayland to connect to Unity8

For Qt it is necessary to install qtwayland5.

This means changes to the environment variables set in the application environment. That means changes to any launchers (e.g. ubuntu-app-launch).

From:

GDK_BACKEND=mir QT_QPA_PLATFORM=ubuntumirclient SDL_VIDEODRIVER=mir

To:

GDK_BACKEND=wayland QT_QPA_PLATFORM=wayland SDL_VIDEODRIVER=wayland

Once again this can be faked using miral-app-run <application> from the command line. (miral-app-run is in the mir-demos package.)

There are still limitations to the Wayland support both in Mir and in the toolkits and the experience may not be perfect. In the release version of Mir Qt and SDL applications will work (with some issues) but GTK apps don't yet work as they require an unstable Wayland extension that Mir does not implement yet.

This extension (xdg-shell-v6) has been enabled on Mir "master" but not yet released. My experience with GTK apps is that they are pretty good at working with this (although there are still some Mir issues to resolve). Some Qt based applications are problematic (They also behave badly on, e.g., Gnome shell if forced to use Wayland and not X11.)

Please note

All of this is "in development" so don't wreck your real machine by "just trying it": Use a Virtual Machine!!

Things will not be "consumer ready" right away, there will be further improvements needed. This is just what is needed to get things running. (But, once these changes are in place, porting to other distros should just be a matter of compiling and packaging.)