An attempt to automate the process of setting up a minimal proot xfce DE inside termux with Hardware Acceleration and Pulse Audio support.
- Download
Termux
andTermux:Boot
fromF-Droid
- Open
Termux
and run following command:source <(curl -sSL https://raw.githubusercontent.com/Vikasg7/termux-scripts/main/scripts/1-install-proot-distro.sh) debian
- Restart the phone
- You should be able to ssh or vnc into proot-distro using localhost or DNS Server IP (192.168.1.x)
ssh 192.168.1.x -p 8022
Note: 192.168.1.x can be replaced with localhostvncviewer -passwd your_password 192.168.1.x:1
- termux-x11 is also supported. Disable vncserver by commenting out the following line in
.termux/boot/startup
:and uncomment following line.proot-distro login debian --user vikas --no-kill-on-exit --shared-tmp --bind $HOME/storage:/mnt/Phone -- /bin/bash -c 'rm -rf /tmp/.X* && vncserver -autokill yes'
# proot-distro login debian --user vikas --no-kill-on-exit --shared-tmp --bind $HOME/storage:/mnt/Phone -- /bin/bash -c 'termux-x11 -xstartup "bash .vnc/xstartup" :1'
- Restart the phone and open termux-x11 app, you should see the desktop.
By default opengl drivers are enabled. You can switch to zink(vulkan) by
- commenting out the following line in
.termux/boot/startup
and uncommenting the following linevirgl_test_server_android &
# MESA_LOADER_DRIVER_OVERRIDE=zink GALLIUM_DRIVER=zink ZINK_DESCRIPTORS=lazy virgl_test_server --use-egl-surfaceless --use-gles &
- and commenting out the following line in
.vnc/xstartup
inside proot-distroand uncommenting the following lineexport GALLIUM_DRIVER=virpipe
# export GALLIUM_DRIVER=zink
- Restart the phone
- Enable USB/Wireless Debugging, Install android-tools on your PC and Connect your device to a PC with adb.
- Persist adb config on reboot
adb shell "/system/bin/device_config set_sync_disabled_for_tests persistent"
- Disable Killing Phantom Processes. Here is the Explanation.
adb shell "/system/bin/device_config put activity_manager max_phantom_processes 2147483647"
- figure out audio
- test Hardware acceleration using glmark2