Fix OnStartRecording and OnStopRecording forwards on linux

CHLTVServer::StartRecording is called directly in tv_record on linux,
ignoring the vtable.
Add a detour on linux for these two functions, so we always notice when
recording starts.
Windows actually always uses the vtable to get the function address, so
we don't need to detour anything on windows.
This commit is contained in:
Peace-Maker
2016-03-09 23:04:28 +01:00
parent 22c3803718
commit 7c4048690b
7 changed files with 189 additions and 19 deletions
+6
View File
@@ -36,6 +36,12 @@ for sdk_name in ['css', 'csgo']:
binary = Extension.HL2Config(project, projectName + '.ext.' + sdk.ext, sdk)
compiler = binary.compiler
if builder.target_platform == 'linux':
binary.sources += [
os.path.join(Extension.sm_root, 'public', 'CDetour', 'CDetour.cpp'),
os.path.join(Extension.sm_root, 'public', 'asm', 'asm.c')
]
if sdk.name == 'csgo':
compiler.cxxincludes += [
os.path.join(sdk.path, 'common', 'protobuf-2.5.0', 'src'),