{ lib , fetchFromGitHub , libxcb , makeBinaryWrapper , nix-update-script , pkg-config , rustPlatform , xcb-util-cursor , xwayland , withSystemd ? true }: rustPlatform.buildRustPackage rec { pname = "xwayland-satellite"; version = "0.8.0-fix5"; src = fetchFromGitHub { owner = "myNicole98"; repo = "xwayland-satellite"; # Use 'rev' for a specific commit hash (recommended for reproducibility) rev = "5791082542687dfc0d5d7cb4df24cb4950ae1579"; # OR use 'tag' if you want to use a git tag # tag = "v0.8.0-fix"; hash = "sha256-uuyvKzKJrR1E6yxnaUYcdugCO/bkhbrZ2Vkov2L6uBU="; }; cargoHash = "sha256-16L6gsvze+m7XCJlOA1lsPNELE3D364ef2FTdkh0rVY="; nativeBuildInputs = [ makeBinaryWrapper pkg-config rustPlatform.bindgenHook ]; buildInputs = [ libxcb xcb-util-cursor ]; buildNoDefaultFeatures = true; buildFeatures = lib.optional withSystemd "systemd"; doCheck = false; postInstall = lib.optionalString withSystemd '' install -Dm0644 resources/xwayland-satellite.service -t $out/lib/systemd/user ''; postFixup = '' wrapProgram $out/bin/xwayland-satellite \ --prefix PATH : "${lib.makeBinPath [ xwayland ]}" ''; passthru.updateScript = nix-update-script { }; meta = { description = "xwayland-satellite with XSETTINGS crash fix"; longDescription = '' Grants rootless Xwayland integration to any Wayland compositor implementing xdg_wm_base. This version includes a fix for XSETTINGS-related crashes with Electron applications. ''; homepage = "https://github.com/myNicole98/xwayland-satellite"; license = lib.licenses.mpl20; mainProgram = "xwayland-satellite"; platforms = lib.platforms.linux; }; }