temporary fix for windows

This commit is contained in:
Kenzzer 2025-04-03 13:55:02 +00:00
parent 2a1bb88e90
commit 6dd35916ff
No known key found for this signature in database
GPG Key ID: BD2A655EB5DC87A9

View File

@ -534,9 +534,13 @@ class SMConfig(object):
binary.sources += [ os.path.join(public_path, 'CDetour', 'detours.cpp') ]
binary.compiler.cxxincludes += [ os.path.join(public_path, 'safetyhook', 'include') ]
#help(self.libsafetyhook)
for task in self.libsafetyhook:
if task.target.arch == binary.compiler.target.arch:
binary.compiler.linkflags += [task.binary]
if task.target.platform == 'windows':
binary.compiler.linkflags += [task.binary.path.removesuffix('.dll') + '.lib']
else:
binary.compiler.linkflags += [task.binary]
return
raise Exception('No suitable build of safetyhook was found.')