2013-12-30 23:50:56 +01:00
|
|
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
2009-08-30 09:46:56 +02:00
|
|
|
import os
|
|
|
|
|
2014-06-01 04:56:42 +02:00
|
|
|
project = SM.HL2Project(builder, 'sdktools.ext')
|
|
|
|
project.sources += [
|
|
|
|
'extension.cpp',
|
2017-02-16 01:29:43 +01:00
|
|
|
'variant-t.cpp',
|
2014-06-01 04:56:42 +02:00
|
|
|
'inputnatives.cpp',
|
|
|
|
'output.cpp',
|
|
|
|
'outputnatives.cpp',
|
|
|
|
'tempents.cpp',
|
|
|
|
'tenatives.cpp',
|
|
|
|
'teamnatives.cpp',
|
|
|
|
'trnatives.cpp',
|
|
|
|
'vcaller.cpp',
|
|
|
|
'vcallbuilder.cpp',
|
|
|
|
'vdecoder.cpp',
|
|
|
|
'vglobals.cpp',
|
|
|
|
'vhelpers.cpp',
|
|
|
|
'vnatives.cpp',
|
|
|
|
'voice.cpp',
|
|
|
|
'vsound.cpp',
|
|
|
|
'clientnatives.cpp',
|
|
|
|
'hooks.cpp',
|
|
|
|
'gamerulesnatives.cpp',
|
|
|
|
'vstringtable.cpp',
|
|
|
|
'../../public/smsdk_ext.cpp',
|
|
|
|
'../../public/CDetour/detours.cpp',
|
|
|
|
'../../public/asm/asm.c'
|
|
|
|
]
|
|
|
|
|
2013-12-30 23:50:56 +01:00
|
|
|
for sdk_name in SM.sdks:
|
|
|
|
sdk = SM.sdks[sdk_name]
|
2010-05-13 11:18:58 +02:00
|
|
|
|
2014-06-01 04:56:42 +02:00
|
|
|
binary = SM.HL2Config(project, 'sdktools.ext.' + sdk.ext, sdk)
|
2013-12-30 23:50:56 +01:00
|
|
|
binary.compiler.cxxincludes += [
|
|
|
|
os.path.join(sdk.path, 'game', 'shared'),
|
|
|
|
os.path.join(builder.sourcePath, 'public', 'jit'),
|
|
|
|
os.path.join(builder.sourcePath, 'public', 'jit', 'x86'),
|
|
|
|
]
|
2009-08-30 09:46:56 +02:00
|
|
|
|
2014-05-25 10:53:58 +02:00
|
|
|
if sdk.name != 'episode1':
|
2013-12-30 23:50:56 +01:00
|
|
|
binary.compiler.defines += ['HOOKING_ENABLED']
|
2010-07-22 05:23:56 +02:00
|
|
|
|
2017-10-02 14:18:57 +02:00
|
|
|
if binary.compiler.behavior == 'gcc':
|
2013-12-30 23:50:56 +01:00
|
|
|
binary.compiler.cxxflags += ['-Wno-invalid-offsetof']
|
2012-04-14 02:12:24 +02:00
|
|
|
|
2014-06-01 04:56:42 +02:00
|
|
|
SM.extensions += builder.Add(project)
|