forked from Frogging-Family/wine-tkg-git
-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
103 additions
and
0 deletions.
There are no files selected for viewing
38 changes: 38 additions & 0 deletions
38
wine-tkg-git/wine-tkg-userpatches/lsteamclient_pid_hack.mypatch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
From 890c356dda291442ce73c71976e66f75a75e072d Mon Sep 17 00:00:00 2001 | ||
From: Andrew Eikum <aeikum@codeweavers.com> | ||
Date: Thu, 27 Apr 2017 13:25:04 -0500 | ||
Subject: [PATCH] HACK: steam: kernelbase: Substitute the current pid for the | ||
Steam client pid. | ||
|
||
--- | ||
dlls/kernelbase/process.c | 15 +++++++++++++++ | ||
1 file changed, 15 insertions(+) | ||
|
||
diff --git a/dlls/kernelbase/process.c b/dlls/kernelbase/process.c | ||
index 39de15066d4..6ea1d3f53c2 100644 | ||
--- a/dlls/kernelbase/process.c | ||
+++ b/dlls/kernelbase/process.c | ||
@@ -1041,6 +1041,21 @@ HANDLE WINAPI DECLSPEC_HOTPATCH OpenProcess( DWORD access, BOOL inherit, DWORD i | ||
attr.SecurityDescriptor = NULL; | ||
attr.SecurityQualityOfService = NULL; | ||
|
||
+ /* PROTON HACK: | ||
+ * On Windows, the Steam client puts its process ID into the registry | ||
+ * at: | ||
+ * | ||
+ * [HKCU\Software\Valve\Steam\ActiveProcess] | ||
+ * PID=dword:00000008 | ||
+ * | ||
+ * Games get that pid from the registry and then query it with | ||
+ * OpenProcess to ensure Steam is running. Since we aren't running the | ||
+ * Windows Steam in Wine, instead we hack this magic number into the | ||
+ * registry and then substitute the game's process itself in its place | ||
+ * so it can query a valid process. | ||
+ */ | ||
+ if (id == 0xfffe) id = GetCurrentProcessId(); | ||
+ | ||
cid.UniqueProcess = ULongToHandle(id); | ||
cid.UniqueThread = 0; | ||
|
||
-- | ||
GitLab |
65 changes: 65 additions & 0 deletions
65
wine-tkg-git/wine-tkg-userpatches/lsteamclient_reg_hack.mypatch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
From 92cccd853a8f66c59de9e9eeb2bb76105c147ad6 Mon Sep 17 00:00:00 2001 | ||
From: Andrew Eikum <aeikum@codeweavers.com> | ||
Date: Wed, 27 Dec 2017 13:31:59 -0600 | ||
Subject: [PATCH] HACK: steam: wine.inf: Add required Steam registry entries. | ||
|
||
--- | ||
loader/wine.inf.in | 25 ++++++++++++++++++++++--- | ||
1 file changed, 22 insertions(+), 3 deletions(-) | ||
|
||
diff --git a/loader/wine.inf.in b/loader/wine.inf.in | ||
index f1525c4f6dd..fdb0161f75d 100644 | ||
--- a/loader/wine.inf.in | ||
+++ b/loader/wine.inf.in | ||
@@ -95,7 +95,8 @@ AddReg=\ | ||
Tapi,\ | ||
ThemeManager,\ | ||
VersionInfo,\ | ||
- LicenseInformation | ||
+ LicenseInformation, \ | ||
+ SteamClient | ||
|
||
[DefaultInstall.ntamd64] | ||
RegisterDlls=RegisterDllsSection | ||
@@ -120,7 +121,8 @@ AddReg=\ | ||
Tapi,\ | ||
ThemeManager,\ | ||
VersionInfo.ntamd64,\ | ||
- LicenseInformation | ||
+ LicenseInformation, \ | ||
+ SteamClient.ntamd64 | ||
|
||
[DefaultInstall.ntarm64] | ||
RegisterDlls=RegisterDllsSection | ||
@@ -160,7 +162,8 @@ AddReg=\ | ||
Misc,\ | ||
Tapi,\ | ||
VersionInfo.ntamd64,\ | ||
- LicenseInformation | ||
+ LicenseInformation, \ | ||
+ SteamClient.ntamd64 | ||
|
||
[Wow64Install.ntarm64] | ||
WineFakeDlls=FakeDllsWin32 | ||
@@ -2672,3 +2675,19 @@ EtcFiles = 12,etc | ||
InfFiles = 17 | ||
NlsFiles = 11 | ||
SortFiles = 10,globalization\sorting | ||
+ | ||
+[SteamClient] | ||
+HKCU,Software\Valve\Steam,"SteamPath",,"%16422%\Steam" | ||
+HKCU,Software\Valve\Steam,"SteamExe",,"%16422%\Steam\Steam.exe" | ||
+HKCU,Software\Valve\Steam\ActiveProcess,"PID",0x10001,0x0000fffe | ||
+HKCU,Software\Valve\Steam\ActiveProcess,"SteamClientDll",,"%16422%\Steam\steamclient.dll" | ||
+HKCU,Software\Valve\Steam\ActiveProcess,"SteamPath",,"%16422%\Steam" | ||
+ | ||
+[SteamClient.ntamd64] | ||
+HKCU,Software\Valve\Steam,"SteamPath",,"%16422%\Steam" | ||
+HKCU,Software\Valve\Steam,"SteamExe",,"%16422%\Steam\Steam.exe" | ||
+HKCU,Software\Valve\Steam\ActiveProcess,"PID",0x10001,0x0000fffe | ||
+HKCU,Software\Valve\Steam\ActiveProcess,"SteamClientDll",,"%16426%\Steam\steamclient.dll" | ||
+HKCU,Software\Valve\Steam\ActiveProcess,"SteamClientDll64",,"C:\windows\system32\lsteamclient.dll" | ||
+HKCU,Software\Valve\Steam\ActiveProcess,"SteamPath",,"%16426%\Steam" | ||
+HKLM,Software\Wow6432Node\Valve\Steam,"InstallPath",,"%16422%\Steam" | ||
-- | ||
GitLab |