diff options
| author | SulfurNitride <SulfurNitride@users.noreply.github.com> | 2026-03-11 04:07:39 -0500 |
|---|---|---|
| committer | SulfurNitride <SulfurNitride@users.noreply.github.com> | 2026-03-11 04:07:39 -0500 |
| commit | f8d99c4f4d03348eb477f812c1769e670a19eb42 (patch) | |
| tree | 60294feab2a92b69c057e4f08ce623b2bac4e55c /src | |
| parent | b3903b9e70d2341397bb02d45e6a01cc65942710 (diff) | |
Fix LOOT launch: clean QT_PLUGIN_PATH and LD_LIBRARY_PATH from env
LOOT's AppImage bundles its own Qt — inheriting Fluorine's
QT_PLUGIN_PATH caused incompatible Qt plugin loading (exit code 6).
Also clean LD_LIBRARY_PATH when the original was empty.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Diffstat (limited to 'src')
| -rw-r--r-- | src/src/loot.cpp | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/src/src/loot.cpp b/src/src/loot.cpp index 00c66e2..794cc9b 100644 --- a/src/src/loot.cpp +++ b/src/src/loot.cpp @@ -1381,12 +1381,21 @@ static bool launchLootGui(QWidget* parent, OrganizerCore& core) lootProcess.setProgram(appImage);
lootProcess.setArguments(args);
- // Restore the original environment if running from AppImage so LOOT
- // doesn't inherit Fluorine's bundled library paths.
+ // Restore the original environment so LOOT's AppImage doesn't inherit
+ // Fluorine's bundled library/plugin paths (which are incompatible with
+ // LOOT's own bundled Qt).
QProcessEnvironment env = QProcessEnvironment::systemEnvironment();
QString origLdPath = env.value("FLUORINE_ORIG_LD_LIBRARY_PATH");
if (!origLdPath.isEmpty()) {
env.insert("LD_LIBRARY_PATH", origLdPath);
+ } else {
+ env.remove("LD_LIBRARY_PATH");
+ }
+ QString origQtPluginPath = env.value("FLUORINE_ORIG_QT_PLUGIN_PATH");
+ if (!origQtPluginPath.isEmpty()) {
+ env.insert("QT_PLUGIN_PATH", origQtPluginPath);
+ } else {
+ env.remove("QT_PLUGIN_PATH");
}
QString origPath = env.value("FLUORINE_ORIG_PATH");
if (!origPath.isEmpty()) {
|
