Waydroid: Difference between revisions
imported>Onny Add note about keyboard layout |
imported>Onny Add note about umlaute |
||
Line 99: | Line 99: | ||
According to [https://github.com/waydroid/waydroid/issues/209 an upstream issue], changing the keyboard layout doesn't seem possible at the moment. | According to [https://github.com/waydroid/waydroid/issues/209 an upstream issue], changing the keyboard layout doesn't seem possible at the moment. | ||
=== Missing umlaute or UTF8 support === | |||
According to [https://github.com/waydroid/waydroid/issues/536 an upstream issue] Android might fail to display special characters correctly. | |||
==See Also:== | ==See Also:== | ||
* [https://wiki.archlinux.org/title/Waydroid | |||
* [https://wiki.archlinux.org/title/Waydroid Waydroid article on the Archlinux Wiki] |
Revision as of 11:33, 28 September 2022
WayDroid is an application which uses LXC containers to run Android applications on a non-Android system.
Installation
We will need to enable the WayDroid and LXD options (the WayDroid module enables LXC).
/etc/nixos/configuration.nix
{ pkgs, ... }:
{
virtualisation = {
waydroid.enable = true;
lxd.enable = true;
};
}
Apply changes
# Rebuild NixOS config.
nixos-rebuild switch
You'll need to finish the WayDroid install in your shell.
# Fetch WayDroid images.
# You can add the parameters "-s GAPPS -f" to have GApps support.
sudo waydroid init
Before the following steps, you might need to do some GPU adjustments. See the troubleshooting section.
Usage
Start the container
# Start the WayDroid LXC container
sudo systemctl start waydroid-container
# You'll know it worked by checking the journal You should see "Started Waydroid Container".
sudo journalctl -u waydroid-container
# Start WayDroid session
# You'll know it is finished when you see the message "Android with user 0 is ready".
waydroid session start
General usage
# Start Android UI
waydroid show-full-ui
# List Android apps
waydroid app list
# Start an Android app
waydroid app launch <application name>
# Install an Android app
waydroid app install </path/to/app.apk>
# Enter the LXC shell
sudo waydroid shell
# Overrides the full-ui width
waydroid prop set persist.waydroid.width 608
Resetting Android Container
# Stop Waydroid container
sudo systemctl stop waydroid-container
# Removing images and user data
sudo rm -r /var/lib/waydroid/* ~/.local/share/waydroid
Troubleshooting
GPU Adjustments
In case you have an NVIDIA card or an RX 6800 series, you'll need to disable GBM and mesa-drivers:
/var/lib/waydroid/waydroid_base.prop
ro.hardware.gralloc=default
ro.hardware.egl=swiftshader
Linux 5.18+
Linux 5.18 and later removed ashmem in favor of memfd, right now you need to tell waydroid (1.2.1 and later) to use the new module:
/var/lib/waydroid/waydroid_base.prop
sys.use_memfd=true
Changing keyboard layout
According to an upstream issue, changing the keyboard layout doesn't seem possible at the moment.
Missing umlaute or UTF8 support
According to an upstream issue Android might fail to display special characters correctly.