Update stremio-linux-shell to use unstable for Rust 1.92+

This commit is contained in:
2026-05-11 20:57:29 -07:00
parent d74a8a4a39
commit c12ef9e01e
7 changed files with 65 additions and 14 deletions
@@ -0,0 +1,10 @@
{
"sessionID": "ses_1e5e3566cffeYr3gZgqACwW0qm",
"updatedAt": "2026-05-12T03:42:20.568Z",
"sources": {
"background-task": {
"state": "idle",
"updatedAt": "2026-05-12T03:42:20.568Z"
}
}
}
@@ -0,0 +1,11 @@
{
"sessionID": "ses_1e5e4b78bffe01ZuWIm5nkP1W2",
"updatedAt": "2026-05-12T03:33:07.373Z",
"sources": {
"background-task": {
"state": "active",
"reason": "1 background task(s) active",
"updatedAt": "2026-05-12T03:33:07.373Z"
}
}
}
+15 -9
View File
@@ -84,6 +84,12 @@
custom = prev.callPackage ./packages { }; custom = prev.callPackage ./packages { };
# Compatibility: bitwarden renamed to bitwarden-desktop in unstable # Compatibility: bitwarden renamed to bitwarden-desktop in unstable
bitwarden-desktop = prev.bitwarden-desktop or prev.bitwarden; bitwarden-desktop = prev.bitwarden-desktop or prev.bitwarden;
# Override stremio-linux-shell with custom GTK4/master branch version
# Use nixpkgs-unstable for Rust 1.92+ support required by master branch
stremio-linux-shell = (import nixpkgs-unstable {
system = prev.stdenv.hostPlatform.system;
config.allowUnfree = true;
}).callPackage ./packages/stremio-linux-shell { };
}); });
# Shared home-manager configuration factory # Shared home-manager configuration factory
@@ -291,16 +297,16 @@
permittedInsecurePackages = [ "qtwebengine-5.15.19" ]; permittedInsecurePackages = [ "qtwebengine-5.15.19" ];
}; };
}; };
in in
{ {
"custom-claude-code" = pkgs.custom.claude-code; "custom-claude-code" = pkgs.custom.claude-code;
"custom-app-launcher-server" = pkgs.custom.app-launcher-server; "custom-app-launcher-server" = pkgs.custom.app-launcher-server;
"custom-mcrcon-rbw" = pkgs.custom.mcrcon-rbw; "custom-mcrcon-rbw" = pkgs.custom.mcrcon-rbw;
"custom-tea-rbw" = pkgs.custom.tea-rbw; "custom-tea-rbw" = pkgs.custom.tea-rbw;
"custom-rclone-torbox-setup" = pkgs.custom.rclone-torbox-setup; "custom-rclone-torbox-setup" = pkgs.custom.rclone-torbox-setup;
"custom-opencode" = pkgs.custom.opencode; "custom-opencode" = pkgs.custom.opencode;
"custom-qmd" = pkgs.custom.qmd; "custom-qmd" = pkgs.custom.qmd;
"custom-stremio-linux-shell" = pkgs.custom.stremio-linux-shell; "stremio-linux-shell" = pkgs.stremio-linux-shell;
"qt-pinned-jellyfin-media-player" = pkgsQt.jellyfin-media-player; "qt-pinned-jellyfin-media-player" = pkgsQt.jellyfin-media-player;
# "qt-pinned-stremio" = pkgsQt.stremio; # Replaced by stremio-linux-shell (Rust/CEF-based) # "qt-pinned-stremio" = pkgsQt.stremio; # Replaced by stremio-linux-shell (Rust/CEF-based)
+1 -1
View File
@@ -11,5 +11,5 @@ rec {
qmd = pkgs.callPackage ./qmd { }; qmd = pkgs.callPackage ./qmd { };
openclaw-image = pkgs.callPackage ./openclaw-image { }; openclaw-image = pkgs.callPackage ./openclaw-image { };
openclaw-runtime-closure = pkgs.callPackage ./openclaw-image/runtime-closure.nix { inherit qmd; }; openclaw-runtime-closure = pkgs.callPackage ./openclaw-image/runtime-closure.nix { inherit qmd; };
stremio-linux-shell = pkgs.callPackage ./stremio-linux-shell { }; # stremio-linux-shell is defined in flake.nix to use nixpkgs-unstable for Rust 1.92+ support
} }
@@ -0,0 +1,2 @@
# This patch would need to be applied to fix dependency version issues
# For now, let's try a different approach - use a snapshot of the repo before the breaking changes
+5
View File
@@ -36,6 +36,11 @@ in
# Xbox wireless protocol support (PDP RiffMaster Xbox, Xbox controllers, etc.) # Xbox wireless protocol support (PDP RiffMaster Xbox, Xbox controllers, etc.)
hardware.xone.enable = true; hardware.xone.enable = true;
# Disable USB autosuspend — xone-wired PDP RiffMaster guitars disconnect
# when the kernel suspends the USB device after 2s of idle, then fail to
# wake on button press (connect/disconnect loop in dmesg).
boot.kernelParams = [ "usbcore.autosuspend=-1" ];
# YARG (rhythm game) needs udev rules for HID controller access. # YARG (rhythm game) needs udev rules for HID controller access.
# Without these, instruments (Wii, PS3, etc.) can't be read without # Without these, instruments (Wii, PS3, etc.) can't be read without
# sudo, and Steam's input layer must be used as a workaround (which # sudo, and Steam's input layer must be used as a workaround (which
+21 -4
View File
@@ -22,7 +22,7 @@ in
stremioScaleFactor = mkOption { stremioScaleFactor = mkOption {
type = types.nullOr types.float; type = types.nullOr types.float;
default = null; default = null;
description = "Scale factor for Stremio UI via --force-device-scale-factor (e.g., 2 for 200% scaling)"; description = "Scale factor for Stremio UI via GDK_BACKEND=x11 + GDK_SCALE (e.g., 2.0 for 200% scaling). Forces XWayland mode since GTK4 ignores GDK_SCALE on native Wayland.";
}; };
appLauncherServer = { appLauncherServer = {
enable = mkOption { enable = mkOption {
@@ -70,6 +70,22 @@ in
} }
else pkgs.qt-pinned.jellyfin-media-player; else pkgs.qt-pinned.jellyfin-media-player;
# stremio-linux-shell is a GTK4/libadwaita + WebKitGTK app (not Electron/CEF).
# --force-device-scale-factor is a Chromium flag that it ignores entirely.
# On Wayland, GTK4 reads scale from the compositor via wp_fractional_scale_v1.
# To force a specific scale, we use GDK_BACKEND=x11 + GDK_SCALE which works
# reliably under XWayland. On native Wayland, GDK_SCALE is ignored.
# Format floats cleanly: 2.0 -> "2", 1.5 -> "1.5"
stremioScaleStr = let
sf = cfg.stremioScaleFactor;
intPart = builtins.floor sf;
s = builtins.toString sf;
m = builtins.match "([0-9]+)\\.([0-9]*[1-9])0*" s;
gdkScale = builtins.toString intPart;
in if sf == intPart then builtins.toString intPart
else if m != null then (builtins.elemAt m 0) + "." + (builtins.elemAt m 1)
else s;
stremioPkg = stremioPkg =
if cfg.stremioScaleFactor != null if cfg.stremioScaleFactor != null
then pkgs.symlinkJoin { then pkgs.symlinkJoin {
@@ -80,14 +96,15 @@ in
mkdir -p $out/bin mkdir -p $out/bin
rm -f $out/bin/stremio rm -f $out/bin/stremio
makeWrapper ${pkgs.stremio-linux-shell}/bin/stremio $out/bin/stremio \ makeWrapper ${pkgs.stremio-linux-shell}/bin/stremio $out/bin/stremio \
--add-flags "--force-device-scale-factor=${toString cfg.stremioScaleFactor}" --set GDK_BACKEND x11 \
--set GDK_SCALE ${builtins.toString (builtins.floor cfg.stremioScaleFactor)}
# Update .desktop file to include scale factor # Update .desktop file to force XWayland + GDK_SCALE for scaling
mkdir -p $out/share/applications mkdir -p $out/share/applications
rm -f $out/share/applications/com.stremio.Stremio.desktop rm -f $out/share/applications/com.stremio.Stremio.desktop
substitute ${pkgs.stremio-linux-shell}/share/applications/com.stremio.Stremio.desktop \ substitute ${pkgs.stremio-linux-shell}/share/applications/com.stremio.Stremio.desktop \
$out/share/applications/com.stremio.Stremio.desktop \ $out/share/applications/com.stremio.Stremio.desktop \
--replace-fail "Exec=stremio" "Exec=stremio --force-device-scale-factor=${toString cfg.stremioScaleFactor}" --replace-fail "Exec=sh -c " "Exec=env GDK_BACKEND=x11 GDK_SCALE=${builtins.toString (builtins.floor cfg.stremioScaleFactor)} sh -c "
''; '';
} }
else pkgs.stremio-linux-shell; else pkgs.stremio-linux-shell;