Termux X11 is a Termux add-on app providing Android frontend for X. The performance is better than VNC server. Although it supports touching gestures, it’s better to have your mouse and keyboard connected to the phone.
1. Install Termux X11
Termux X11 is still in alpha stage.
Install Termux
Login to your Github account. Download latest APK from Termux-x11 Github workflows. Download the Termux X11 APK (Branch: master)
Unzip the archives and install Termux-x11 apk.
Launch Termux, instal x11-repo. Then install termux-x11-nightly
|
|
2. Run X11 apps in Termux
Open Termux X11 APP and you will see this
Go back to Termux. Install XFCE4 and GIMP
|
|
- Launch XFCE4 with dbus-launch
|
|
If you encounter Make sure an X server isn't already running(EE)
error, close Termux, then “Force stop” and “Clear cache” Termux and Termux X11 in Android system settings.
Now you should see XFCE4 runnning in Termux X11.
You could change Touchscreen input mode in Termux X11 preferences in notification bar.
If the font is too big, open System settings → Appearance → check Cutsom DPI。
Press
CTRL+Z
in Termux to stop XFCE4.
3. Run X11 apps in Proot-distro
Install a proot-distro. For example Debian or Arch Linux.
Open Termux X11 app. Then go back to Termux.
Login to proot-distro as a normal user with
--shared-tmp
.
|
|
- Add user to video and audio groups:
|
|
- Launch desktop environment. For example, XFCE4
|
|
Install
onboard
package for the floating keyboard.Proot-distro have more packages than Termux. For an instance, it is possible to play Minecraft with MultiMC.
4. Run X11 apps in chroot
Root permission is required.
Setup a chroot environment, for exmaple chroot Ubuntu with XFCE4
Set SELinux to Permissive
|
|
- Start Termux X11 APP. Go back to Termux, execute:
|
|
- Log into chroot. Start XFCE4
|
|
5. Starting Wayland session in Termux
Termux-x11 is a XWayland server. However it is possible to start a nested Wayland session.
Just intall weston
and launch it in the terminal:
|
|
6. GPU Acceleration in Termux X11
See:virglrenderer: Termux GPU Hardware Acceleration Tutorial