sourcemod/extensions/tf2/AMBuilder
Benoist e07c120cab
CDetour safetyhook (#2162)
* Add safetyhook, remove libudis86

Co-authored-by: bottiger1 <55270538+bottiger1@users.noreply.github.com>

* Add modified CDetour

Co-authored-by: bottiger1 <55270538+bottiger1@users.noreply.github.com>

* Add CDetour [Safetyhook] to build script

* Re-enable loader/core/corelogic, and fix new C++20 error

* Reenable all extensions (except dhooks)

* Make cstrike compile against new CDetour

* Remove unused variable in sdktools output?

* Make sdktools compile against new cdetour

* Downgrade to C++17

* remove auto

* fix compilation on linux

* Re-enable dhooks

* Re-authorise old compilers

* Fix invalid downgrade of std::optional

* readd libudis86 for dhooks only

---------

Co-authored-by: Kenzzer <kenzzer@users.noreply.github.com>
Co-authored-by: bottiger1 <55270538+bottiger1@users.noreply.github.com>
2024-05-21 01:53:44 +00:00

26 lines
689 B
Python

# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
import os
if 'tf2' in SM.sdks:
sdk = SM.sdks['tf2']
for cxx in builder.targets:
if not cxx.target.arch in sdk['platforms'][cxx.target.platform]:
continue
binary = SM.HL2Library(builder, cxx, 'game.tf2.ext.' + sdk['extension'], sdk)
SM.AddCDetour(binary)
binary.sources += [
'extension.cpp',
'natives.cpp',
'RegNatives.cpp',
'util.cpp',
'criticals.cpp',
'holiday.cpp',
'teleporter.cpp',
'gameplayrules.cpp',
'conditions.cpp',
'../../public/smsdk_ext.cpp'
]
binary.compiler.defines += ['HAVE_STRING_H']
SM.extensions += [builder.Add(binary)]