Fix: Run EXE installers from their directory in sideload dialog#5394
Fix: Run EXE installers from their directory in sideload dialog#5394BrandowLucas wants to merge 5 commits intoHeroic-Games-Launcher:mainfrom
Conversation
The "Run Installer First" button in the sideload dialog wasn't setting the working directory properly, causing DLL dependencies to not be found. Wine needs the working dir as a Windows path, not Linux path. Changes: - Added getDirname IPC helper to get directory from file path - In runWineCommand, convert Linux cwd to Windows path and use cmd /c cd /d to change directory before running - SideloadDialog now passes the EXE's directory as startFolder
|
All contributors have signed the CLA ✍️ ✅ |
src/frontend/screens/Library/components/InstallModal/SideloadDialog/index.tsx
Outdated
Show resolved
Hide resolved
|
I have read the CLA Document and I hereby sign the CLA |
|
recheck |
"Run EXE on Prefix" wasn't pulling the correct WINEPREFIX. Removed unnecessary path conversion code (cmd /c cd /d trick). Added some useful debug logs
|
Could you clarify what exactly this change achieves? I understand we're not setting the working directory correctly, but DLLs are first searched for in the folder containing the application. The CWD is searched through, but only in a lower priority (reference) If possible, please provide steps to verify the original issue |
I’m not at home right now, so I can’t provide screenshots. However, without this 5-line patch, selecting the run installer first option causes my mounted DVD game Need for Speed Most Wanted After applying the patch, the |
The "Run Installer First" button in the sideload dialog wasn't setting the working directory properly, causing DLL dependencies to not be found. Wine needs the working dir as a Windows path, not Linux path. Changes:
Use the following Checklist if you have changed something on the Backend or Frontend: