Waydroid: Difference between revisions

Added a helpful line to run waydroid in newer linux kernel versions
Onny (talk | contribs)
V4L2 camera forwarding: Simplify setup instructions
 
Line 122: Line 122:
=== V4L2 camera forwarding ===
=== V4L2 camera forwarding ===


Camera forwarding using V4L2 is broken on upstream, but can be achieved by using the Waydroid images of the [https://github.com/WayDroid-ATV Waydroid-ATV project]. Further we also need an unstable Waydroid version (>1.6.2) for running it.<syntaxhighlight lang="nix">
Camera forwarding using V4L2 is broken on upstream, but can be achieved by using the Waydroid images of the [https://github.com/WayDroid-ATV Waydroid-ATV project]. You might [[Waydroid#Resetting Android Container|need to reset]] your existing Waydroid environment. Then stop the container and fetch the latest Waydroid-ATV images.<syntaxhighlight lang="bash">
disabledModules = [
  "virtualisation/waydroid.nix"
];
imports = [
"${inputs.nixpkgs-unstable}/nixos/modules/virtualisation/waydroid.nix"
];
 
nixpkgs.overlays = [
  (self: super: {
    waydroid = (inputs.nixpkgs-unstable.legacyPackages.x86_64-linux.waydroid.overrideAttrs (old: rec {
      version = "0-unstable-2026-04-26";
      src = pkgs.fetchFromGitHub {
        owner = "waydroid";
        repo = "waydroid";
        rev = "9478d59ad5c83b22478594e73d5879b93200fcb2";
        hash = "sha256-L4qU5TSWavxvyPUqVV00NCd0YZqAaKPWTe3dR/q15LE=";
      };
    }));
  })
];
</syntaxhighlight>You might [[Waydroid#Resetting Android Container|need to reset]] your existing Waydroid environment. Then stop the container and fetch the latest Waydroid-ATV images.<syntaxhighlight lang="bash">
systemctl stop waydroid-container
systemctl stop waydroid-container
waydroid init -f \
waydroid init -f \