aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSulfurNitride <SulfurNitride@users.noreply.github.com>2026-04-16 23:04:01 -0500
committerSulfurNitride <SulfurNitride@users.noreply.github.com>2026-04-16 23:04:01 -0500
commite583d6dda3cde9e8bccee313fe1ad69634593708 (patch)
tree6e2fd5ec15bf2e17eec1d0701097801ad6cefb4c
parent1d323579a0da7c2b22e0208e123907f849c99696 (diff)
Fix Proton 11 prefix init hang, switch SLR to steamrt4
Proton 11's toolmanifest sets use_sessions=1, so the "run" verb forks into a persistent session manager that never exits — prefix init hung forever. Use "waitforexitandrun" instead. Also drop WINEDEBUG=-all so init output is visible, and migrate the bundled Steam Linux Runtime downloader from steamrt3/sniper to steamrt4 (Proton 11's required runtime). SLR lookup paths fall back to sniper for users with an existing install. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
-rw-r--r--src/src/prefixsetuprunner.cpp21
-rw-r--r--src/src/protonlauncher.cpp7
-rw-r--r--src/src/settingsdialog.ui2
-rw-r--r--src/src/slrmanager.cpp8
-rw-r--r--src/src/slrmanager.h2
5 files changed, 25 insertions, 15 deletions
diff --git a/src/src/prefixsetuprunner.cpp b/src/src/prefixsetuprunner.cpp
index bc1b9ce..53ab0bd 100644
--- a/src/src/prefixsetuprunner.cpp
+++ b/src/src/prefixsetuprunner.cpp
@@ -797,14 +797,16 @@ bool PrefixSetupRunner::stepProtonInit()
env["SteamGameId"] = QString::number(m_appId);
env["DISPLAY"] = "";
env["WAYLAND_DISPLAY"] = "";
- env["WINEDEBUG"] = "-all";
env["WINEDLLOVERRIDES"] = "msdia80.dll=n;conhost.exe=d;cmd.exe=d";
emit logMessage("Initializing Wine prefix with Proton...");
QByteArray protonOutput;
+ // waitforexitandrun (not "run") is required for Proton 11+ which uses
+ // use_sessions=1 — a plain "run" forks into a session manager that never
+ // exits, hanging prefix init.
const int rc = runProcess(protonScript,
- {"run", "wineboot", "-u"},
+ {"waitforexitandrun", "wineboot", "-u"},
env, -1, &protonOutput);
if (rc != 0) {
// Detect a broken Proton install: setup_prefix copies DLLs from Proton's
@@ -1692,15 +1694,22 @@ QString PrefixSetupRunner::detectSteamPath() const
QString PrefixSetupRunner::detectSLRRunScript() const
{
- // Check NaK-downloaded SLR first.
- const QString nakSlr = fluorineDataDir() + "/steamrt/SteamLinuxRuntime_sniper/run";
- if (QFileInfo::exists(nakSlr))
- return nakSlr;
+ // Check Fluorine-downloaded SLR first (steamrt4 preferred, sniper fallback).
+ const QStringList nakCandidates = {
+ fluorineDataDir() + "/steamrt/SteamLinuxRuntime_4/run",
+ fluorineDataDir() + "/steamrt/SteamLinuxRuntime_sniper/run",
+ };
+ for (const QString& p : nakCandidates) {
+ if (QFileInfo::exists(p))
+ return p;
+ }
const QString steamPath = detectSteamPath();
const QStringList candidates = {
+ steamPath + "/steamapps/common/SteamLinuxRuntime_4/run",
steamPath + "/steamapps/common/SteamLinuxRuntime_sniper/run",
+ QDir::homePath() + "/.local/share/Steam/steamapps/common/SteamLinuxRuntime_4/run",
QDir::homePath() + "/.local/share/Steam/steamapps/common/SteamLinuxRuntime_sniper/run",
"/usr/lib/pressure-vessel/wrap",
};
diff --git a/src/src/protonlauncher.cpp b/src/src/protonlauncher.cpp
index 4e9ed4d..976eed7 100644
--- a/src/src/protonlauncher.cpp
+++ b/src/src/protonlauncher.cpp
@@ -135,18 +135,19 @@ QString detectSteamPath()
return {};
}
-// Find the Steam Linux Runtime (sniper) run script.
+// Find the Steam Linux Runtime run script (steamrt4 preferred, sniper fallback).
// SLR wraps the Proton launch in a pressure-vessel container that provides
// GStreamer, 32-bit libs, and an FHS-compliant environment — required on
-// NixOS and other non-FHS distros.
+// NixOS and other non-FHS distros. Proton 11+ requires steamrt4.
// Returns empty string if SLR is not installed.
QString detectSLRRunScript()
{
const QString steamPath = detectSteamPath();
- // Common SLR sniper locations relative to Steam install
const QStringList candidates = {
+ steamPath + "/steamapps/common/SteamLinuxRuntime_4/run",
steamPath + "/steamapps/common/SteamLinuxRuntime_sniper/run",
+ QDir::home().filePath(".local/share/Steam/steamapps/common/SteamLinuxRuntime_4/run"),
QDir::home().filePath(".local/share/Steam/steamapps/common/SteamLinuxRuntime_sniper/run"),
"/usr/lib/pressure-vessel/wrap",
};
diff --git a/src/src/settingsdialog.ui b/src/src/settingsdialog.ui
index cb158f2..4e10085 100644
--- a/src/src/settingsdialog.ui
+++ b/src/src/settingsdialog.ui
@@ -1799,7 +1799,7 @@ If you disable this feature, MO will only display official DLCs this way. Please
<string>Download Steam Linux Runtime</string>
</property>
<property name="toolTip">
- <string>Download SteamLinuxRuntime_sniper (~180 MB) from Valve's servers. Provides GStreamer, 32-bit libs, and an FHS environment for non-FHS distros (NixOS, etc.). Required for the "Use SLR" option in the Instance Manager.</string>
+ <string>Download SteamLinuxRuntime_4 (steamrt4, ~200 MB) from Valve's servers. Provides GStreamer, 32-bit libs, and an FHS environment for non-FHS distros (NixOS, etc.). Required for the "Use SLR" option in the Instance Manager and for Proton 11+.</string>
</property>
</widget>
</item>
diff --git a/src/src/slrmanager.cpp b/src/src/slrmanager.cpp
index fe60e56..94e4cbf 100644
--- a/src/src/slrmanager.cpp
+++ b/src/src/slrmanager.cpp
@@ -12,9 +12,9 @@
namespace {
-const char* BASE_URL = "https://repo.steampowered.com/steamrt3/images/latest-public-beta";
-const char* ARCHIVE_NAME = "SteamLinuxRuntime_sniper.tar.xz";
-const char* EXTRACTED_DIR = "SteamLinuxRuntime_sniper";
+const char* BASE_URL = "https://repo.steampowered.com/steamrt4/images/latest-public-beta";
+const char* ARCHIVE_NAME = "SteamLinuxRuntime_4.tar.xz";
+const char* EXTRACTED_DIR = "SteamLinuxRuntime_4";
QString slrInstallDir()
{
@@ -147,7 +147,7 @@ QString downloadSlr(const std::function<void(float)>& progressCb,
const QString archivePath = installDir + "/" + ARCHIVE_NAME;
// 2. Download.
- status(QStringLiteral("Downloading Steam Linux Runtime (sniper, ~180 MB)..."));
+ status(QStringLiteral("Downloading Steam Linux Runtime (steamrt4, ~200 MB)..."));
httpGet(QStringLiteral("%1/%2").arg(QLatin1String(BASE_URL), QLatin1String(ARCHIVE_NAME)),
cancelFlag, progress, archivePath);
progress(1.0f);
diff --git a/src/src/slrmanager.h b/src/src/slrmanager.h
index c800c2e..e0a1b3f 100644
--- a/src/src/slrmanager.h
+++ b/src/src/slrmanager.h
@@ -10,7 +10,7 @@ __attribute__((visibility("default"))) bool isSlrInstalled();
/// Returns the path to the SLR `run` script, or empty if not installed.
__attribute__((visibility("default"))) QString getSlrRunScript();
-/// Download and install SteamLinuxRuntime_sniper (~180 MB).
+/// Download and install SteamLinuxRuntime_4 (steamrt4, ~200 MB).
/// Skips if already at the latest version (BUILD_ID check).
/// Returns empty string on success, or an error message.
__attribute__((visibility("default")))