anchor.diff:      libXrandr
       fontconfig
       glew
  +
  +    # Headless executable
  +    libGL
  +    SDL2
     ];
   
     patches = [
       ./appdir.patch # Ryujinx attempts to write to the nix store. This patch redirects it to "~/.config/Ryujinx" on Linux.
  +  ];
  +
  +  projectFile = "Ryujinx.sln";
  +  testProjectFile = "Ryujinx.Tests/Ryujinx.Tests.csproj";
  +  doCheck = true;
  +
  +  dotnetFlags = [
  +    "/p:ExtraDefineConstants=DISABLE_UPDATER"
  +  ];
  +
  +  executables = [
  +    "Ryujinx.Headless.SDL2"
  +    "Ryujinx.Ava"
  +    "Ryujinx"
     ];
   
     makeWrapperArgs = [
  
positive.code:     install -D ./ryujinx-mime.xml $out/share/mime/packages/ryujinx-mime.xml
      install -D ./ryujinx-logo.svg $out/share/icons/hicolor/scalable/apps/ryujinx.svg
  
      substituteInPlace $out/share/applications/ryujinx.desktop --replace \
        "Exec=Ryujinx" "Exec=$out/bin/Ryujinx"
  
      popd
    '';
  
negative.code: , libXrandr
  , fontconfig
  , glew
  , libGL
  , SDL2
  , SDL2_mixer
  }:
  
  buildDotnetModule rec {
    pname = "ryujinx";
    version = "1.1.248"; # Based off of the official github actions builds: https://github.com/Ryujinx/Ryujinx/actions/workflows/release.yml
  
    src = fetchFromGitHub {
      owner = "Ryujinx";
      repo = "Ryujinx";
      rev = "5ff5fe47bad947a95545390865c597bec6c62070";
      sha256 = "0nfzf7q58mhdyszwv3mbz3wqf4w0m1p3fmf3cpga1pf9mfq65nqz";
    };
  
    nugetDeps = ./deps.nix;
  
    nativeBuildInputs = [
      wrapGAppsHook
  