mirror of
https://github.com/alliedmodders/amxmodx.git
synced 2025-01-26 13:48:03 +03:00
Merge pull request #1 from alliedmodders/ambuild
Port AMX Mod X to AMBuild 2. Former-commit-id: caa26e5133dc97557b7d7e111de73c1dcac7fe94
This commit is contained in:
commit
d46d657190
349
AMBuildScript
Normal file
349
AMBuildScript
Normal file
@ -0,0 +1,349 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python :
|
||||||
|
import os
|
||||||
|
|
||||||
|
class AMXXConfig(object):
|
||||||
|
def __init__(self):
|
||||||
|
self.binaries = []
|
||||||
|
self.modules = []
|
||||||
|
self.plugins = {}
|
||||||
|
self.libpc300 = None
|
||||||
|
self.amxxpc = None
|
||||||
|
self.metamod_path = None
|
||||||
|
self.hlsdk_path = None
|
||||||
|
self.mysql_path = None
|
||||||
|
self.generated_headers = None
|
||||||
|
self.csx_app = None
|
||||||
|
|
||||||
|
def detectProductVersion(self):
|
||||||
|
builder.AddConfigureFile('product.version')
|
||||||
|
builder.AddConfigureFile('.git/HEAD')
|
||||||
|
|
||||||
|
# For OS X dylib versioning
|
||||||
|
import re
|
||||||
|
with open(os.path.join(builder.sourcePath, 'product.version'), 'r') as fp:
|
||||||
|
productContents = fp.read()
|
||||||
|
m = re.match('(\d+)\.(\d+)\.(\d+).*', productContents)
|
||||||
|
if m == None:
|
||||||
|
self.productVersion = '1.0.0'
|
||||||
|
else:
|
||||||
|
major, minor, release = m.groups()
|
||||||
|
self.productVersion = '{0}.{1}.{2}'.format(major, minor, release)
|
||||||
|
|
||||||
|
def detectMetamod(self):
|
||||||
|
if len(builder.options.metamod_path):
|
||||||
|
self.metamod_path = os.path.join(builder.originalCwd, builder.options.metamod_path)
|
||||||
|
if not os.path.exists(os.path.join(self.metamod_path, 'metamod')):
|
||||||
|
raise Exception('Metamod path does not exist: {0}'.format(builder.options.metamod_path))
|
||||||
|
else:
|
||||||
|
try_paths = [
|
||||||
|
os.path.join(builder.sourcePath, '..', 'metamod'),
|
||||||
|
os.path.join(builder.sourcePath, '..', 'metamod-am'),
|
||||||
|
]
|
||||||
|
for try_path in try_paths:
|
||||||
|
if os.path.exists(os.path.join(try_path, 'metamod')):
|
||||||
|
self.metamod_path = os.path.normpath(try_path)
|
||||||
|
break
|
||||||
|
if not self.metamod_path:
|
||||||
|
raise Exception('Could not find the source code to Metamod! Try passing --metamod to configure.py.')
|
||||||
|
|
||||||
|
def detectHlsdk(self):
|
||||||
|
if len(builder.options.hlsdk_path):
|
||||||
|
self.hlsdk_path = os.path.join(builder.originalCwd, builder.options.hlsdk_path)
|
||||||
|
if not os.path.exists(self.hlsdk_path):
|
||||||
|
raise Exception('Metamod path does not exist: {0}'.format(builder.options.hlsdk_path))
|
||||||
|
else:
|
||||||
|
try_paths = [
|
||||||
|
os.path.join(builder.sourcePath, '..', 'hlsdk'),
|
||||||
|
]
|
||||||
|
for try_path in try_paths:
|
||||||
|
if os.path.exists(try_path):
|
||||||
|
self.hlsdk_path = os.path.normpath(try_path)
|
||||||
|
break
|
||||||
|
if not self.hlsdk_path:
|
||||||
|
raise Exception('Could not find the HLSDK! Try passing --hlsdk to configure.py.')
|
||||||
|
|
||||||
|
def detectMysql(self):
|
||||||
|
if builder.options.disable_mysql:
|
||||||
|
return
|
||||||
|
|
||||||
|
if len(builder.options.mysql_path):
|
||||||
|
self.mysql_path = os.path.join(builder.originalCwd, builder.options.mysql_path)
|
||||||
|
if not os.path.exists(self.mysql_path):
|
||||||
|
raise Exception('Metamod path does not exist: {0}'.format(builder.options.mysql_path))
|
||||||
|
else:
|
||||||
|
try_paths = [
|
||||||
|
os.path.join(builder.sourcePath, '..', 'mysql-5.0'),
|
||||||
|
]
|
||||||
|
for try_path in try_paths:
|
||||||
|
if os.path.exists(try_path):
|
||||||
|
self.mysql_path = os.path.normpath(try_path)
|
||||||
|
break
|
||||||
|
if not self.mysql_path:
|
||||||
|
raise Exception('Could not find MySQL! Try passing --mysql to configure.py.')
|
||||||
|
|
||||||
|
def configure(self):
|
||||||
|
builder.AddConfigureFile('pushbuild.txt')
|
||||||
|
|
||||||
|
cfg = builder.DetectCompilers()
|
||||||
|
cxx = cfg.cxx
|
||||||
|
|
||||||
|
if cxx.behavior == 'gcc':
|
||||||
|
cfg.cflags += [
|
||||||
|
'-pipe',
|
||||||
|
'-fno-strict-aliasing',
|
||||||
|
'-Wall',
|
||||||
|
'-Werror',
|
||||||
|
'-Wno-uninitialized',
|
||||||
|
'-Wno-unused',
|
||||||
|
'-Wno-switch',
|
||||||
|
'-m32',
|
||||||
|
]
|
||||||
|
cfg.cxxflags += [
|
||||||
|
'-Wno-invalid-offsetof',
|
||||||
|
]
|
||||||
|
|
||||||
|
cfg.linkflags += ['-m32']
|
||||||
|
|
||||||
|
have_gcc = cxx.name == 'gcc'
|
||||||
|
have_clang = cxx.name == 'clang'
|
||||||
|
|
||||||
|
if have_clang or (have_gcc and cxx.majorVersion >= 4):
|
||||||
|
cfg.cflags += ['-fvisibility=hidden']
|
||||||
|
cfg.cxxflags += ['-fvisibility-inlines-hidden']
|
||||||
|
if (have_gcc and cxx.minorVersion >= 7) or (have_clang and cxx.majorVersion >= 3):
|
||||||
|
cfg.cxxflags += ['-Wno-delete-non-virtual-dtor']
|
||||||
|
|
||||||
|
if have_gcc:
|
||||||
|
cfg.cflags += ['-Wno-parentheses']
|
||||||
|
elif have_clang:
|
||||||
|
cfg.cflags += ['-Wno-logical-op-parentheses']
|
||||||
|
|
||||||
|
cfg.cxxflags += [
|
||||||
|
'-fno-exceptions',
|
||||||
|
'-fno-rtti',
|
||||||
|
]
|
||||||
|
elif cxx.name == 'msvc':
|
||||||
|
if builder.options.debug == '1':
|
||||||
|
cfg.cflags += ['/MTd']
|
||||||
|
cfg.linkflags += ['/NODEFAULTLIB:libcmt']
|
||||||
|
else:
|
||||||
|
cfg.cflags += ['/MT']
|
||||||
|
cfg.defines += [
|
||||||
|
'_CRT_SECURE_NO_DEPRECATE',
|
||||||
|
'_CRT_SECURE_NO_WARNINGS',
|
||||||
|
'_CRT_NONSTDC_NO_DEPRECATE',
|
||||||
|
'_ITERATOR_DEBUG_LEVEL=0',
|
||||||
|
]
|
||||||
|
cfg.cflags += [
|
||||||
|
'/W3',
|
||||||
|
]
|
||||||
|
cfg.cxxflags += [
|
||||||
|
'/EHsc',
|
||||||
|
'/GR-',
|
||||||
|
'/TP',
|
||||||
|
]
|
||||||
|
cfg.linkflags += [
|
||||||
|
'/MACHINE:X86',
|
||||||
|
'/SUBSYSTEM:WINDOWS',
|
||||||
|
'kernel32.lib',
|
||||||
|
'user32.lib',
|
||||||
|
'gdi32.lib',
|
||||||
|
'winspool.lib',
|
||||||
|
'comdlg32.lib',
|
||||||
|
'advapi32.lib',
|
||||||
|
'shell32.lib',
|
||||||
|
'ole32.lib',
|
||||||
|
'oleaut32.lib',
|
||||||
|
'uuid.lib',
|
||||||
|
'odbc32.lib',
|
||||||
|
'odbccp32.lib',
|
||||||
|
]
|
||||||
|
|
||||||
|
# Optimization
|
||||||
|
if builder.options.opt == '1':
|
||||||
|
cfg.defines += ['NDEBUG']
|
||||||
|
if cxx.behavior == 'gcc':
|
||||||
|
cfg.cflags += ['-O2']
|
||||||
|
elif cxx.behavior == 'msvc':
|
||||||
|
cfg.cflags += ['/Ox']
|
||||||
|
cfg.linkflags += ['/OPT:ICF', '/OPT:REF']
|
||||||
|
|
||||||
|
# Debugging
|
||||||
|
if builder.options.debug == '1':
|
||||||
|
cfg.defines += ['DEBUG', '_DEBUG']
|
||||||
|
if cxx.behavior == 'msvc':
|
||||||
|
cfg.cflags += ['/Od', '/RTC1']
|
||||||
|
|
||||||
|
# This needs to be after our optimization flags which could otherwise disable it.
|
||||||
|
if cxx.name == 'msvc':
|
||||||
|
# Don't omit the frame pointer.
|
||||||
|
cfg.cflags += ['/Oy-']
|
||||||
|
|
||||||
|
# Platform-specifics
|
||||||
|
if builder.target_platform == 'linux':
|
||||||
|
cfg.defines += ['_LINUX', 'POSIX', 'LINUX']
|
||||||
|
cfg.postlink += ['-ldl']
|
||||||
|
if cxx.name == 'gcc':
|
||||||
|
cfg.postlink += ['-static-libgcc']
|
||||||
|
elif cxx.name == 'clang':
|
||||||
|
cfg.postlink += ['-lgcc_eh']
|
||||||
|
elif builder.target_platform == 'mac':
|
||||||
|
cfg.defines += ['OSX', '_OSX', 'POSIX']
|
||||||
|
cfg.postlink += [
|
||||||
|
'-mmacosx-version-min=10.5',
|
||||||
|
'-arch', 'i386',
|
||||||
|
'-lstdc++',
|
||||||
|
'-stdlib=libstdc++',
|
||||||
|
]
|
||||||
|
cfg.cxxflags += ['-stdlib=libstdc++']
|
||||||
|
elif builder.target_platform == 'windows':
|
||||||
|
cfg.defines += ['WIN32', '_WINDOWS']
|
||||||
|
|
||||||
|
# Finish up.
|
||||||
|
cfg.defines += [
|
||||||
|
'AMX_NOPROPLIST',
|
||||||
|
'PAWN_CELL_SIZE=32',
|
||||||
|
'AMBUILD',
|
||||||
|
]
|
||||||
|
|
||||||
|
cfg.includes += [os.path.join(builder.buildPath, 'includes')]
|
||||||
|
return
|
||||||
|
|
||||||
|
#
|
||||||
|
# Low-level compiler and binary construction.
|
||||||
|
#
|
||||||
|
|
||||||
|
def MMCompiler(self, context):
|
||||||
|
compiler = context.compiler.clone()
|
||||||
|
compiler.cxxincludes += [
|
||||||
|
os.path.join(self.metamod_path, 'metamod'),
|
||||||
|
os.path.join(self.hlsdk_path, 'common'),
|
||||||
|
os.path.join(self.hlsdk_path, 'dlls'),
|
||||||
|
os.path.join(self.hlsdk_path, 'engine'),
|
||||||
|
os.path.join(self.hlsdk_path, 'game_shared'),
|
||||||
|
os.path.join(self.hlsdk_path, 'public'),
|
||||||
|
os.path.join(self.hlsdk_path, 'pm_shared'),
|
||||||
|
]
|
||||||
|
return compiler
|
||||||
|
|
||||||
|
def LibraryBuilder(self, context, compiler, name):
|
||||||
|
binary = compiler.Library(name)
|
||||||
|
binary.compiler.cxxincludes += [os.path.join(context.currentSourcePath)]
|
||||||
|
if builder.target_platform == 'windows':
|
||||||
|
binary.compiler.rcdefines += [
|
||||||
|
'BINARY_NAME="{0}"'.format(binary.outputFile),
|
||||||
|
'AMBUILD',
|
||||||
|
'RC_COMPILE',
|
||||||
|
]
|
||||||
|
elif builder.target_platform == 'mac':
|
||||||
|
binary.compiler.postlink += [
|
||||||
|
'-compatibility_version', '1.0.0',
|
||||||
|
'-current_version', self.productVersion
|
||||||
|
]
|
||||||
|
#binary.compiler.linkflags += [self.versionlib]
|
||||||
|
binary.compiler.sourcedeps += AMXX.generated_headers
|
||||||
|
return binary
|
||||||
|
|
||||||
|
def ModuleBuilder(self, context, compiler, name):
|
||||||
|
compiler.cxxincludes += [
|
||||||
|
os.path.join(context.currentSourcePath, 'sdk'),
|
||||||
|
]
|
||||||
|
|
||||||
|
if builder.target_platform == 'mac' or builder.target_platform == 'windows':
|
||||||
|
name = name + '_amxx'
|
||||||
|
elif builder.target_platform == 'linux':
|
||||||
|
name = name + '_amxx_i386'
|
||||||
|
|
||||||
|
return self.LibraryBuilder(context, compiler, name)
|
||||||
|
|
||||||
|
def ProgramBuilder(self, context, compiler, name):
|
||||||
|
binary = compiler.Program(name)
|
||||||
|
binary.compiler.cxxincludes += [os.path.join(context.currentSourcePath)]
|
||||||
|
if builder.target_platform == 'windows':
|
||||||
|
binary.compiler.rcdefines += [
|
||||||
|
'BINARY_NAME="{0}"'.format(binary.outputFile),
|
||||||
|
'AMBUILD',
|
||||||
|
'RC_COMPILE',
|
||||||
|
]
|
||||||
|
binary.compiler.sourcedeps += AMXX.generated_headers
|
||||||
|
return binary
|
||||||
|
|
||||||
|
#
|
||||||
|
# High level job construction for libraries, metamod plugins, modules, and
|
||||||
|
# executables.
|
||||||
|
#
|
||||||
|
|
||||||
|
def Library(self, context, name):
|
||||||
|
compiler = context.compiler.clone()
|
||||||
|
return self.LibraryBuilder(context, compiler, name)
|
||||||
|
|
||||||
|
def MetaPlugin(self, context, name):
|
||||||
|
compiler = self.MMCompiler(context)
|
||||||
|
|
||||||
|
if builder.target_platform == 'mac' or builder.target_platform == 'windows':
|
||||||
|
name = name + '_mm'
|
||||||
|
elif builder.target_platform == 'linux':
|
||||||
|
name = name + '_mm_i386'
|
||||||
|
|
||||||
|
return self.LibraryBuilder(context, compiler, name)
|
||||||
|
|
||||||
|
def Module(self, context, name):
|
||||||
|
compiler = context.compiler.clone()
|
||||||
|
return self.ModuleBuilder(context, compiler, name)
|
||||||
|
|
||||||
|
def MetaModule(self, context, name):
|
||||||
|
compiler = self.MMCompiler(context)
|
||||||
|
return self.ModuleBuilder(context, compiler, name)
|
||||||
|
|
||||||
|
def Program(self, context, name):
|
||||||
|
compiler = context.compiler.clone()
|
||||||
|
return self.ProgramBuilder(context, compiler, name)
|
||||||
|
|
||||||
|
AMXX = AMXXConfig()
|
||||||
|
AMXX.detectProductVersion()
|
||||||
|
AMXX.detectMetamod()
|
||||||
|
AMXX.detectHlsdk()
|
||||||
|
AMXX.detectMysql()
|
||||||
|
AMXX.configure()
|
||||||
|
|
||||||
|
AMXX.generated_headers = builder.RunScript(
|
||||||
|
'support/Versioning',
|
||||||
|
{ 'AMXX': AMXX }
|
||||||
|
)
|
||||||
|
|
||||||
|
builder.RunBuildScripts(
|
||||||
|
[
|
||||||
|
'amxmodx/AMBuilder',
|
||||||
|
'compiler/amxxpc/AMBuilder',
|
||||||
|
'compiler/libpc300/AMBuilder',
|
||||||
|
'dlls/cstrike/cstrike/AMBuilder',
|
||||||
|
'dlls/cstrike/csx/AMBuilder',
|
||||||
|
'dlls/dod/dodfun/AMBuilder',
|
||||||
|
'dlls/dod/dodx/AMBuilder',
|
||||||
|
'dlls/engine/AMBuilder',
|
||||||
|
'dlls/fakemeta/AMBuilder',
|
||||||
|
'dlls/fun/AMBuilder',
|
||||||
|
'dlls/geoip/AMBuilder',
|
||||||
|
'dlls/hamsandwich/AMBuilder',
|
||||||
|
'dlls/mysqlx/AMBuilder',
|
||||||
|
'dlls/ns/AMBuilder',
|
||||||
|
'dlls/nvault/AMBuilder',
|
||||||
|
'dlls/regex/AMBuilder',
|
||||||
|
'dlls/sockets/AMBuilder',
|
||||||
|
'dlls/sqlite/AMBuilder',
|
||||||
|
'dlls/tfcx/AMBuilder',
|
||||||
|
'dlls/ts/tsfun/AMBuilder',
|
||||||
|
'dlls/ts/tsx/AMBuilder',
|
||||||
|
'plugins/AMBuilder',
|
||||||
|
],
|
||||||
|
{
|
||||||
|
'AMXX': AMXX
|
||||||
|
}
|
||||||
|
)
|
||||||
|
|
||||||
|
# The csstats.dat reader is Windows-only.
|
||||||
|
if builder.target_platform == 'windows':
|
||||||
|
builder.RunScript('dlls/cstrike/csx/WinCSX/AMBuilder', { 'AMXX': AMXX })
|
||||||
|
|
||||||
|
# Finally, do packaging.
|
||||||
|
builder.RunScript('support/PackageScript', { 'AMXX': AMXX })
|
100
amxmodx/AMBuilder
Normal file
100
amxmodx/AMBuilder
Normal file
@ -0,0 +1,100 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.MetaPlugin(builder, 'amxmodx')
|
||||||
|
|
||||||
|
binary.compiler.defines += [
|
||||||
|
'JIT',
|
||||||
|
'ASM32',
|
||||||
|
'HAVE_STDINT_H',
|
||||||
|
]
|
||||||
|
|
||||||
|
if builder.target_platform == 'mac':
|
||||||
|
jit_objects = [
|
||||||
|
binary.Dep('JIT/amxexecn-darwin.o'),
|
||||||
|
binary.Dep('JIT/amxjitsn-darwin.o'),
|
||||||
|
binary.Dep('JIT/natives-darwin-x86.o'),
|
||||||
|
binary.Dep('JIT/helpers-darwin-x86.o'),
|
||||||
|
]
|
||||||
|
elif builder.target_platform == 'linux':
|
||||||
|
jit_objects = [
|
||||||
|
binary.Dep('JIT/amxexecn.o'),
|
||||||
|
binary.Dep('JIT/amxjitsn.o'),
|
||||||
|
binary.Dep('JIT/natives-x86.o'),
|
||||||
|
binary.Dep('JIT/helpers-x86.o'),
|
||||||
|
]
|
||||||
|
elif builder.target_platform == 'windows':
|
||||||
|
jit_objects = [
|
||||||
|
binary.Dep('JIT/amxexecn.obj'),
|
||||||
|
binary.Dep('JIT/amxjitsn.obj'),
|
||||||
|
binary.Dep('JIT/helpers-x86.obj'),
|
||||||
|
binary.Dep('JIT/natives-x86.obj'),
|
||||||
|
]
|
||||||
|
|
||||||
|
binary.compiler.linkflags += jit_objects
|
||||||
|
|
||||||
|
if builder.target_platform == 'linux':
|
||||||
|
binary.compiler.linkflags += [binary.Dep('zlib/libz.a')]
|
||||||
|
elif builder.target_platform == 'mac':
|
||||||
|
binary.compiler.linkflags += [binary.Dep('zlib/libz-darwin.a')]
|
||||||
|
elif builder.target_platform == 'windows':
|
||||||
|
binary.compiler.linkflags += [binary.Dep('zlib\\zlib.lib')]
|
||||||
|
|
||||||
|
if builder.target_platform == 'mac':
|
||||||
|
binary.compiler.postlink += [
|
||||||
|
'-Wl,-read_only_relocs,suppress'
|
||||||
|
]
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'meta_api.cpp',
|
||||||
|
'CFile.cpp',
|
||||||
|
'CVault.cpp',
|
||||||
|
'vault.cpp',
|
||||||
|
'float.cpp',
|
||||||
|
'file.cpp',
|
||||||
|
'modules.cpp',
|
||||||
|
'CMisc.cpp',
|
||||||
|
'CTask.cpp',
|
||||||
|
'string.cpp',
|
||||||
|
'amxmodx.cpp',
|
||||||
|
'CEvent.cpp',
|
||||||
|
'CCmd.cpp',
|
||||||
|
'CLogEvent.cpp',
|
||||||
|
'srvcmd.cpp',
|
||||||
|
'strptime.cpp',
|
||||||
|
'amxcore.cpp',
|
||||||
|
'amxtime.cpp',
|
||||||
|
'power.cpp',
|
||||||
|
'amxxlog.cpp',
|
||||||
|
'fakemeta.cpp',
|
||||||
|
'amxxfile.cpp',
|
||||||
|
'CLang.cpp',
|
||||||
|
'md5.cpp',
|
||||||
|
'emsg.cpp',
|
||||||
|
'CForward.cpp',
|
||||||
|
'CPlugin.cpp',
|
||||||
|
'CModule.cpp',
|
||||||
|
'CMenu.cpp',
|
||||||
|
'util.cpp',
|
||||||
|
'amx.cpp',
|
||||||
|
'amxdbg.cpp',
|
||||||
|
'natives.cpp',
|
||||||
|
'newmenus.cpp',
|
||||||
|
'debugger.cpp',
|
||||||
|
'optimizer.cpp',
|
||||||
|
'format.cpp',
|
||||||
|
'messages.cpp',
|
||||||
|
'libraries.cpp',
|
||||||
|
'vector.cpp',
|
||||||
|
'sorting.cpp',
|
||||||
|
'amxmod_compat.cpp',
|
||||||
|
'nongpl_matches.cpp',
|
||||||
|
'CFlagManager.cpp',
|
||||||
|
'datastructs.cpp',
|
||||||
|
'trie_natives.cpp',
|
||||||
|
]
|
||||||
|
|
||||||
|
if builder.target_platform == 'windows':
|
||||||
|
binary.sources += ['version.rc']
|
||||||
|
|
||||||
|
AMXX.binaries += [builder.Add(binary)]
|
@ -39,7 +39,7 @@
|
|||||||
#include "CFlagManager.h"
|
#include "CFlagManager.h"
|
||||||
#include "nongpl_matches.h"
|
#include "nongpl_matches.h"
|
||||||
#include "format.h"
|
#include "format.h"
|
||||||
#include "svn_version.h"
|
#include <amxmodx_version.h>
|
||||||
|
|
||||||
extern CFlagManager FlagMan;
|
extern CFlagManager FlagMan;
|
||||||
CVector<CAdminData *> DynamicAdmins;
|
CVector<CAdminData *> DynamicAdmins;
|
||||||
|
@ -44,7 +44,7 @@
|
|||||||
#define vsnprintf _vsnprintf
|
#define vsnprintf _vsnprintf
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include "svn_version.h"
|
#include <amxmodx_version.h>
|
||||||
|
|
||||||
CLog::CLog()
|
CLog::CLog()
|
||||||
{
|
{
|
||||||
|
@ -50,7 +50,7 @@
|
|||||||
|
|
||||||
#include "datastructs.h"
|
#include "datastructs.h"
|
||||||
#include "CFlagManager.h"
|
#include "CFlagManager.h"
|
||||||
#include "svn_version.h"
|
#include <amxmodx_version.h>
|
||||||
#include "trie_natives.h"
|
#include "trie_natives.h"
|
||||||
|
|
||||||
plugin_info_t Plugin_info =
|
plugin_info_t Plugin_info =
|
||||||
|
@ -30,7 +30,7 @@
|
|||||||
*/
|
*/
|
||||||
|
|
||||||
#include "amxmodx.h"
|
#include "amxmodx.h"
|
||||||
#include "svn_version.h"
|
#include <amxmodx_version.h>
|
||||||
|
|
||||||
void amx_command()
|
void amx_command()
|
||||||
{
|
{
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
#define SVN_VERSION_STRING "1.8.2-dev"
|
|
||||||
#define SVN_VERSION_DWORD 1,8,2,0
|
|
||||||
#define SVN_VERSION_PRODUCT "1.8.2"
|
|
||||||
#define SVN_BUILD_ID SVN_VERSION_STRING " 9:7ff502465eae"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
#define SVN_VERSION_STRING "$PMAJOR$.$PMINOR$.$PREVISION$$BUILD_STRING$"
|
|
||||||
#define SVN_VERSION_DWORD $PMAJOR$,$PMINOR$,$PREVISION$,0
|
|
||||||
#define SVN_VERSION_PRODUCT "$PMAJOR$.$PMINOR$.$PREVISION$"
|
|
||||||
#define SVN_BUILD_ID SVN_VERSION_STRING " $BUILD_ID$"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -6,7 +6,13 @@
|
|||||||
// Generated from the TEXTINCLUDE 2 resource.
|
// Generated from the TEXTINCLUDE 2 resource.
|
||||||
//
|
//
|
||||||
#include "winres.h"
|
#include "winres.h"
|
||||||
#include "svn_version.h"
|
#if defined AMBUILD
|
||||||
|
# include <amxmodx_version.h>
|
||||||
|
#else
|
||||||
|
# define SVN_VERSION_DWORD 1, 8, 3, 0
|
||||||
|
# define SVN_VERSION_STRING "dev-local"
|
||||||
|
# define SVN_VERSION SVN_VERSION_STRING
|
||||||
|
#endif
|
||||||
|
|
||||||
/////////////////////////////////////////////////////////////////////////////
|
/////////////////////////////////////////////////////////////////////////////
|
||||||
#undef APSTUDIO_READONLY_SYMBOLS
|
#undef APSTUDIO_READONLY_SYMBOLS
|
||||||
@ -49,7 +55,7 @@ BEGIN
|
|||||||
VALUE "LegalCopyright", "Copyright (c) 2004-2007, AMX Mod X Dev Team"
|
VALUE "LegalCopyright", "Copyright (c) 2004-2007, AMX Mod X Dev Team"
|
||||||
VALUE "OriginalFilename", "amxmodx_mm.dll"
|
VALUE "OriginalFilename", "amxmodx_mm.dll"
|
||||||
VALUE "ProductName", "AMX Mod X"
|
VALUE "ProductName", "AMX Mod X"
|
||||||
VALUE "ProductVersion", SVN_VERSION_PRODUCT
|
VALUE "ProductVersion", SVN_VERSION
|
||||||
END
|
END
|
||||||
END
|
END
|
||||||
BLOCK "VarFileInfo"
|
BLOCK "VarFileInfo"
|
||||||
|
35
compiler/amxxpc/AMBuilder
Normal file
35
compiler/amxxpc/AMBuilder
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.Program(builder, 'amxxpc')
|
||||||
|
|
||||||
|
binary.compiler.defines += [
|
||||||
|
'AMX_ANSIONLY',
|
||||||
|
]
|
||||||
|
|
||||||
|
if builder.target_platform != 'windows':
|
||||||
|
binary.compiler.cxxflags.remove('-fno-exceptions')
|
||||||
|
|
||||||
|
if builder.target_platform == 'linux':
|
||||||
|
binary.compiler.postlink += [
|
||||||
|
'-ldl',
|
||||||
|
binary.Dep('libz.a'),
|
||||||
|
]
|
||||||
|
elif builder.target_platform == 'mac':
|
||||||
|
binary.compiler.postlink += [binary.Dep('libz-darwin.a')]
|
||||||
|
elif builder.target_platform == 'windows':
|
||||||
|
binary.compiler.defines += ['_MBCS']
|
||||||
|
binary.compiler.linkflags += [binary.Dep('zlib.lib')]
|
||||||
|
binary.compiler.linkflags.remove('/SUBSYSTEM:WINDOWS')
|
||||||
|
binary.compiler.linkflags.append('/SUBSYSTEM:CONSOLE')
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'amx.cpp',
|
||||||
|
'amxxpc.cpp',
|
||||||
|
'Binary.cpp',
|
||||||
|
]
|
||||||
|
|
||||||
|
if builder.target_platform == 'windows':
|
||||||
|
binary.sources += ['amxxpc1.rc']
|
||||||
|
|
||||||
|
AMXX.amxxpc = builder.Add(binary)
|
@ -775,7 +775,7 @@ static void expand(unsigned char *code, long codesize, long memsize)
|
|||||||
do {
|
do {
|
||||||
codesize--;
|
codesize--;
|
||||||
/* no input byte should be shifted out completely */
|
/* no input byte should be shifted out completely */
|
||||||
assert(shift<8*sizeof(cell));
|
assert(size_t(shift)<8*sizeof(cell));
|
||||||
/* we work from the end of a sequence backwards; the final code in
|
/* we work from the end of a sequence backwards; the final code in
|
||||||
* a sequence may not have the continuation bit set */
|
* a sequence may not have the continuation bit set */
|
||||||
assert(shift>0 || (code[(size_t)codesize] & 0x80)==0);
|
assert(shift>0 || (code[(size_t)codesize] & 0x80)==0);
|
||||||
|
@ -69,7 +69,7 @@ int main(int argc, char **argv)
|
|||||||
exit(0);
|
exit(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
pc_printf("Welcome to the AMX Mod X %s Compiler.\n", VERSION_STRING);
|
pc_printf("Welcome to the AMX Mod X %s Compiler.\n", SVN_VERSION);
|
||||||
pc_printf("Copyright (c) 1997-2013 ITB CompuPhase, AMX Mod X Team\n\n");
|
pc_printf("Copyright (c) 1997-2013 ITB CompuPhase, AMX Mod X Team\n\n");
|
||||||
|
|
||||||
if (argc < 2)
|
if (argc < 2)
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
#ifndef _AMXXSC_INCLUDE_H
|
#ifndef _AMXXSC_INCLUDE_H
|
||||||
#define _AMXXSC_INCLUDE_H
|
#define _AMXXSC_INCLUDE_H
|
||||||
|
|
||||||
#define VERSION_STRING "1.8.1-300"
|
#include <amxmodx_version.h>
|
||||||
#define MAGIC_HEADER2 0x414D5858
|
#define MAGIC_HEADER2 0x414D5858
|
||||||
#define MAGIC_VERSION 0x0300
|
#define MAGIC_VERSION 0x0300
|
||||||
|
|
||||||
|
41
compiler/libpc300/AMBuilder
Normal file
41
compiler/libpc300/AMBuilder
Normal file
@ -0,0 +1,41 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.Library(builder, 'amxxpc32')
|
||||||
|
|
||||||
|
binary.compiler.includes += [builder.currentSourcePath]
|
||||||
|
|
||||||
|
if builder.target_platform in ['mac', 'linux']:
|
||||||
|
binary.compiler.defines += ['ENABLE_BINRELOC']
|
||||||
|
binary.compiler.postlink += ['-lm', '-lpthread']
|
||||||
|
|
||||||
|
binary.compiler.defines += [
|
||||||
|
'NO_MAIN',
|
||||||
|
'PAWNC_DLL',
|
||||||
|
'HAVE_STDINT_H',
|
||||||
|
]
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'sc1.c',
|
||||||
|
'sc2.c',
|
||||||
|
'sc3.c',
|
||||||
|
'sc4.c',
|
||||||
|
'sc5.c',
|
||||||
|
'sc6.c',
|
||||||
|
'sc7.c',
|
||||||
|
'scvars.c',
|
||||||
|
'scmemfil.c',
|
||||||
|
'scstate.c',
|
||||||
|
'sclist.c',
|
||||||
|
'sci18n.c',
|
||||||
|
'scexpand.c',
|
||||||
|
'pawncc.c',
|
||||||
|
'libpawnc.c',
|
||||||
|
'prefix.c',
|
||||||
|
'memfile.c',
|
||||||
|
]
|
||||||
|
|
||||||
|
if builder.target_platform == 'windows':
|
||||||
|
binary.sources+= ['libpawnc.rc']
|
||||||
|
|
||||||
|
AMXX.libpc300 = builder.Add(binary)
|
@ -763,6 +763,7 @@ SC_VDECL int sc_needsemicolon;/* semicolon required to terminate expressions? */
|
|||||||
SC_VDECL int sc_dataalign; /* data alignment value */
|
SC_VDECL int sc_dataalign; /* data alignment value */
|
||||||
SC_VDECL int sc_alignnext; /* must frame of the next function be aligned? */
|
SC_VDECL int sc_alignnext; /* must frame of the next function be aligned? */
|
||||||
SC_VDECL int pc_docexpr; /* must expression be attached to documentation comment? */
|
SC_VDECL int pc_docexpr; /* must expression be attached to documentation comment? */
|
||||||
|
SC_VDECL int sc_showincludes; /* show include files? */
|
||||||
SC_VDECL int curseg; /* 1 if currently parsing CODE, 2 if parsing DATA */
|
SC_VDECL int curseg; /* 1 if currently parsing CODE, 2 if parsing DATA */
|
||||||
SC_VDECL cell sc_stksize; /* stack size */
|
SC_VDECL cell sc_stksize; /* stack size */
|
||||||
SC_VDECL cell sc_amxlimit; /* abstract machine size limit */
|
SC_VDECL cell sc_amxlimit; /* abstract machine size limit */
|
||||||
|
@ -487,7 +487,9 @@ int pc_compile(int argc, char *argv[])
|
|||||||
tname=NULL;
|
tname=NULL;
|
||||||
sname=NULL;
|
sname=NULL;
|
||||||
#else
|
#else
|
||||||
tname=tempnam(NULL,"pawn");
|
char *buffer = strdup(P_tmpdir "/pawn.XXXXXX");
|
||||||
|
close(mkstemp(buffer));
|
||||||
|
tname=buffer;
|
||||||
#endif
|
#endif
|
||||||
ftmp=(FILE*)pc_createsrc(tname);
|
ftmp=(FILE*)pc_createsrc(tname);
|
||||||
for (fidx=0; (sname=get_sourcefile(fidx))!=NULL; fidx++) {
|
for (fidx=0; (sname=get_sourcefile(fidx))!=NULL; fidx++) {
|
||||||
@ -1013,6 +1015,9 @@ static void parseoptions(int argc,char **argv,char *oname,char *ename,char *pnam
|
|||||||
hwndFinish=(HWND)0;
|
hwndFinish=(HWND)0;
|
||||||
break;
|
break;
|
||||||
#endif
|
#endif
|
||||||
|
case 'h':
|
||||||
|
sc_showincludes = 1;
|
||||||
|
break;
|
||||||
case 'i':
|
case 'i':
|
||||||
strncpy(str,option_value(ptr),sizeof str); /* set name of include directory */
|
strncpy(str,option_value(ptr),sizeof str); /* set name of include directory */
|
||||||
str[sizeof(str)-1]='\0';
|
str[sizeof(str)-1]='\0';
|
||||||
@ -1295,7 +1300,8 @@ static void setconfig(char *root)
|
|||||||
insert_path(path);
|
insert_path(path);
|
||||||
/* same for the codepage root */
|
/* same for the codepage root */
|
||||||
#if !defined NO_CODEPAGE
|
#if !defined NO_CODEPAGE
|
||||||
*ptr='\0';
|
if (ptr)
|
||||||
|
*ptr='\0';
|
||||||
if (!cp_path(path,"codepage"))
|
if (!cp_path(path,"codepage"))
|
||||||
error(109,path); /* codepage path */
|
error(109,path); /* codepage path */
|
||||||
#endif
|
#endif
|
||||||
|
@ -142,6 +142,9 @@ static char *extensions[] = { ".inc", ".p", ".pawn" };
|
|||||||
*ext='\0'; /* restore filename */
|
*ext='\0'; /* restore filename */
|
||||||
return FALSE;
|
return FALSE;
|
||||||
} /* if */
|
} /* if */
|
||||||
|
if (sc_showincludes && sc_status==statFIRST) {
|
||||||
|
fprintf(stdout, "Note: including file: %s\n", name);
|
||||||
|
}
|
||||||
PUSHSTK_P(inpf);
|
PUSHSTK_P(inpf);
|
||||||
PUSHSTK_P(inpfname); /* pointer to current file name */
|
PUSHSTK_P(inpfname); /* pointer to current file name */
|
||||||
PUSHSTK_P(curlibrary);
|
PUSHSTK_P(curlibrary);
|
||||||
|
@ -85,6 +85,7 @@ SC_VDEFINE int sc_rationaltag=0; /* tag for rational numbers */
|
|||||||
SC_VDEFINE int rational_digits=0; /* number of fractional digits */
|
SC_VDEFINE int rational_digits=0; /* number of fractional digits */
|
||||||
SC_VDEFINE int sc_allowproccall=0; /* allow/detect tagnames in lex() */
|
SC_VDEFINE int sc_allowproccall=0; /* allow/detect tagnames in lex() */
|
||||||
SC_VDEFINE short sc_is_utf8=FALSE; /* is this source file in UTF-8 encoding */
|
SC_VDEFINE short sc_is_utf8=FALSE; /* is this source file in UTF-8 encoding */
|
||||||
|
SC_VDEFINE int sc_showincludes=0; /* show include files */
|
||||||
|
|
||||||
SC_VDEFINE constvalue sc_automaton_tab = { NULL, "", 0, 0}; /* automaton table */
|
SC_VDEFINE constvalue sc_automaton_tab = { NULL, "", 0, 0}; /* automaton table */
|
||||||
SC_VDEFINE constvalue sc_state_tab = { NULL, "", 0, 0}; /* state table */
|
SC_VDEFINE constvalue sc_state_tab = { NULL, "", 0, 0}; /* state table */
|
||||||
|
31
configure.py
Normal file
31
configure.py
Normal file
@ -0,0 +1,31 @@
|
|||||||
|
# vim: set ts=2 sw=2 tw=99 noet:
|
||||||
|
import sys
|
||||||
|
try:
|
||||||
|
from ambuild2 import run
|
||||||
|
except:
|
||||||
|
try:
|
||||||
|
import ambuild
|
||||||
|
sys.stderr.write('It looks like you have AMBuild 1 installed, but this project uses AMBuild 2.\n')
|
||||||
|
sys.stderr.write('Upgrade to the latest version of AMBuild to continue.\n')
|
||||||
|
except:
|
||||||
|
sys.stderr.write('AMBuild must be installed to build this project.\n')
|
||||||
|
sys.stderr.write('http://www.alliedmods.net/ambuild\n')
|
||||||
|
sys.exit(1)
|
||||||
|
|
||||||
|
run = run.PrepareBuild(sourcePath=sys.path[0])
|
||||||
|
run.default_build_folder = 'obj-' + run.target_platform
|
||||||
|
run.options.add_option('--enable-debug', action='store_const', const='1', dest='debug',
|
||||||
|
help='Enable debugging symbols')
|
||||||
|
run.options.add_option('--enable-optimize', action='store_const', const='1', dest='opt',
|
||||||
|
help='Enable optimization')
|
||||||
|
run.options.add_option('--no-mysql', action='store_true', default=False, dest='disable_mysql',
|
||||||
|
help='Disable building MySQL extension')
|
||||||
|
run.options.add_option('--breakpad-dump', action='store_true', dest='breakpad_dump',
|
||||||
|
default=False, help='Dump and upload breakpad symbols')
|
||||||
|
run.options.add_option('--metamod', type='string', dest='metamod_path', default='',
|
||||||
|
help='Path to Metamod source code')
|
||||||
|
run.options.add_option('--hlsdk', type='string', dest='hlsdk_path', default='',
|
||||||
|
help='Path to the HLSDK')
|
||||||
|
run.options.add_option('--mysql', type='string', dest='mysql_path', default='',
|
||||||
|
help='Path to MySQL')
|
||||||
|
run.Configure()
|
13
dlls/cstrike/cstrike/AMBuilder
Normal file
13
dlls/cstrike/cstrike/AMBuilder
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.MetaModule(builder, 'cstrike')
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'sdk/amxxmodule.cpp',
|
||||||
|
'CstrikePlayer.cpp',
|
||||||
|
'cstrike.cpp',
|
||||||
|
'CstrikeHacks.cpp',
|
||||||
|
]
|
||||||
|
|
||||||
|
AMXX.modules += [builder.Add(binary)]
|
@ -3,7 +3,11 @@
|
|||||||
#ifndef __MODULECONFIG_H__
|
#ifndef __MODULECONFIG_H__
|
||||||
#define __MODULECONFIG_H__
|
#define __MODULECONFIG_H__
|
||||||
|
|
||||||
#include "svn_version.h"
|
#if defined AMBUILD
|
||||||
|
# include <amxmodx_version.h>
|
||||||
|
#else
|
||||||
|
# define SVN_VERSION "dev-local"
|
||||||
|
#endif
|
||||||
|
|
||||||
// Module info
|
// Module info
|
||||||
#define MODULE_NAME "CStrike"
|
#define MODULE_NAME "CStrike"
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "1.8.2-dev"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "$PMAJOR$.$PMINOR$.$PREVISION$$BUILD_STRING$"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
15
dlls/cstrike/csx/AMBuilder
Normal file
15
dlls/cstrike/csx/AMBuilder
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.MetaModule(builder, 'csx')
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'sdk/amxxmodule.cpp',
|
||||||
|
'CRank.cpp',
|
||||||
|
'CMisc.cpp',
|
||||||
|
'meta_api.cpp',
|
||||||
|
'rank.cpp',
|
||||||
|
'usermsg.cpp',
|
||||||
|
]
|
||||||
|
|
||||||
|
AMXX.modules += [builder.Add(binary)]
|
22
dlls/cstrike/csx/WinCSX/AMBuilder
Normal file
22
dlls/cstrike/csx/WinCSX/AMBuilder
Normal file
@ -0,0 +1,22 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.Program(builder, 'WinCSX')
|
||||||
|
|
||||||
|
binary.compiler.includes += [
|
||||||
|
os.path.join(builder.currentSourcePath, 'resources'),
|
||||||
|
]
|
||||||
|
binary.compiler.defines += ['_MBCS']
|
||||||
|
binary.compiler.linkflags += [
|
||||||
|
'comctl32.lib',
|
||||||
|
]
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'CRank.cpp',
|
||||||
|
'WinCSX.cpp',
|
||||||
|
'stdafx.cpp',
|
||||||
|
'resources/WinCSX.rc',
|
||||||
|
]
|
||||||
|
|
||||||
|
AMXX.csx_app = builder.Add(binary)
|
||||||
|
|
@ -3,7 +3,11 @@
|
|||||||
#ifndef __MODULECONFIG_H__
|
#ifndef __MODULECONFIG_H__
|
||||||
#define __MODULECONFIG_H__
|
#define __MODULECONFIG_H__
|
||||||
|
|
||||||
#include "svn_version.h"
|
#if defined AMBUILD
|
||||||
|
# include <amxmodx_version.h>
|
||||||
|
#else
|
||||||
|
# define SVN_VERSION "dev-local"
|
||||||
|
#endif
|
||||||
|
|
||||||
// Module info
|
// Module info
|
||||||
#define MODULE_NAME "CSX"
|
#define MODULE_NAME "CSX"
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "1.8.2-dev"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "$PMAJOR$.$PMINOR$.$PREVISION$$BUILD_STRING$"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
16
dlls/dod/dodfun/AMBuilder
Normal file
16
dlls/dod/dodfun/AMBuilder
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.MetaModule(builder, 'dodfun')
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'sdk/amxxmodule.cpp',
|
||||||
|
'NBase.cpp',
|
||||||
|
'CMisc.cpp',
|
||||||
|
'NPD.cpp',
|
||||||
|
'Utils.cpp',
|
||||||
|
'usermsg.cpp',
|
||||||
|
'moduleconfig.cpp',
|
||||||
|
]
|
||||||
|
|
||||||
|
AMXX.modules += [builder.Add(binary)]
|
@ -3,7 +3,11 @@
|
|||||||
#ifndef __MODULECONFIG_H__
|
#ifndef __MODULECONFIG_H__
|
||||||
#define __MODULECONFIG_H__
|
#define __MODULECONFIG_H__
|
||||||
|
|
||||||
#include "svn_version.h"
|
#if defined AMBUILD
|
||||||
|
# include <amxmodx_version.h>
|
||||||
|
#else
|
||||||
|
# define SVN_VERSION "dev-local"
|
||||||
|
#endif
|
||||||
|
|
||||||
// Module info
|
// Module info
|
||||||
#define MODULE_NAME "DoD Fun"
|
#define MODULE_NAME "DoD Fun"
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "1.8.2-dev"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "$PMAJOR$.$PMINOR$.$PREVISION$$BUILD_STRING$"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
17
dlls/dod/dodx/AMBuilder
Normal file
17
dlls/dod/dodx/AMBuilder
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.MetaModule(builder, 'dodx')
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'sdk/amxxmodule.cpp',
|
||||||
|
'CRank.cpp',
|
||||||
|
'CMisc.cpp',
|
||||||
|
'NBase.cpp',
|
||||||
|
'NRank.cpp',
|
||||||
|
'usermsg.cpp',
|
||||||
|
'Utils.cpp',
|
||||||
|
'moduleconfig.cpp',
|
||||||
|
]
|
||||||
|
|
||||||
|
AMXX.modules += [builder.Add(binary)]
|
@ -3,7 +3,11 @@
|
|||||||
#ifndef __MODULECONFIG_H__
|
#ifndef __MODULECONFIG_H__
|
||||||
#define __MODULECONFIG_H__
|
#define __MODULECONFIG_H__
|
||||||
|
|
||||||
#include "svn_version.h"
|
#if defined AMBUILD
|
||||||
|
# include <amxmodx_version.h>
|
||||||
|
#else
|
||||||
|
# define SVN_VERSION "dev-local"
|
||||||
|
#endif
|
||||||
|
|
||||||
// Module info
|
// Module info
|
||||||
#define MODULE_NAME "DoDX"
|
#define MODULE_NAME "DoDX"
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "1.8.2-dev"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "$PMAJOR$.$PMINOR$.$PREVISION$$BUILD_STRING$"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
16
dlls/engine/AMBuilder
Normal file
16
dlls/engine/AMBuilder
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.MetaModule(builder, 'engine')
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'sdk/amxxmodule.cpp',
|
||||||
|
'amxxapi.cpp',
|
||||||
|
'engine.cpp',
|
||||||
|
'entity.cpp',
|
||||||
|
'globals.cpp',
|
||||||
|
'forwards.cpp',
|
||||||
|
'amxmod_compat.cpp',
|
||||||
|
]
|
||||||
|
|
||||||
|
AMXX.modules += [builder.Add(binary)]
|
@ -3,7 +3,11 @@
|
|||||||
#ifndef __MODULECONFIG_H__
|
#ifndef __MODULECONFIG_H__
|
||||||
#define __MODULECONFIG_H__
|
#define __MODULECONFIG_H__
|
||||||
|
|
||||||
#include "svn_version.h"
|
#if defined AMBUILD
|
||||||
|
# include <amxmodx_version.h>
|
||||||
|
#else
|
||||||
|
# define SVN_VERSION "dev-local"
|
||||||
|
#endif
|
||||||
|
|
||||||
// Module info
|
// Module info
|
||||||
#define MODULE_NAME "Engine"
|
#define MODULE_NAME "Engine"
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "1.8.2-dev"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "$PMAJOR$.$PMINOR$.$PREVISION$$BUILD_STRING$"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
20
dlls/fakemeta/AMBuilder
Normal file
20
dlls/fakemeta/AMBuilder
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.MetaModule(builder, 'fakemeta')
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'sdk/amxxmodule.cpp',
|
||||||
|
'dllfunc.cpp',
|
||||||
|
'engfunc.cpp',
|
||||||
|
'fakemeta_amxx.cpp',
|
||||||
|
'pdata.cpp',
|
||||||
|
'forward.cpp',
|
||||||
|
'fm_tr.cpp',
|
||||||
|
'pev.cpp',
|
||||||
|
'glb.cpp',
|
||||||
|
'fm_tr2.cpp',
|
||||||
|
'misc.cpp',
|
||||||
|
]
|
||||||
|
|
||||||
|
AMXX.modules += [builder.Add(binary)]
|
@ -3,7 +3,11 @@
|
|||||||
#ifndef __MODULECONFIG_H__
|
#ifndef __MODULECONFIG_H__
|
||||||
#define __MODULECONFIG_H__
|
#define __MODULECONFIG_H__
|
||||||
|
|
||||||
#include "svn_version.h"
|
#if defined AMBUILD
|
||||||
|
# include <amxmodx_version.h>
|
||||||
|
#else
|
||||||
|
# define SVN_VERSION "dev-local"
|
||||||
|
#endif
|
||||||
|
|
||||||
// Module info
|
// Module info
|
||||||
#define MODULE_NAME "FakeMeta"
|
#define MODULE_NAME "FakeMeta"
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "1.8.2-dev"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "$PMAJOR$.$PMINOR$.$PREVISION$$BUILD_STRING$"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
11
dlls/fun/AMBuilder
Normal file
11
dlls/fun/AMBuilder
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.MetaModule(builder, 'fun')
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'sdk/amxxmodule.cpp',
|
||||||
|
'fun.cpp',
|
||||||
|
]
|
||||||
|
|
||||||
|
AMXX.modules += [builder.Add(binary)]
|
@ -3,7 +3,11 @@
|
|||||||
#ifndef __MODULECONFIG_H__
|
#ifndef __MODULECONFIG_H__
|
||||||
#define __MODULECONFIG_H__
|
#define __MODULECONFIG_H__
|
||||||
|
|
||||||
#include "svn_version.h"
|
#if defined AMBUILD
|
||||||
|
# include <amxmodx_version.h>
|
||||||
|
#else
|
||||||
|
# define SVN_VERSION "dev-local"
|
||||||
|
#endif
|
||||||
|
|
||||||
// Module info
|
// Module info
|
||||||
#define MODULE_NAME "Fun"
|
#define MODULE_NAME "Fun"
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "1.8.2-dev"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "$PMAJOR$.$PMINOR$.$PREVISION$$BUILD_STRING$"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
15
dlls/geoip/AMBuilder
Normal file
15
dlls/geoip/AMBuilder
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.Module(builder, 'geoip')
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'sdk/amxxmodule.cpp',
|
||||||
|
'GeoIP.c',
|
||||||
|
'geoip_amxx.cpp',
|
||||||
|
]
|
||||||
|
|
||||||
|
if builder.target_platform == 'windows':
|
||||||
|
binary.compiler.postlink += ['ws2_32.lib']
|
||||||
|
|
||||||
|
AMXX.modules += [builder.Add(binary)]
|
@ -3,7 +3,11 @@
|
|||||||
#ifndef __MODULECONFIG_H__
|
#ifndef __MODULECONFIG_H__
|
||||||
#define __MODULECONFIG_H__
|
#define __MODULECONFIG_H__
|
||||||
|
|
||||||
#include "svn_version.h"
|
#if defined AMBUILD
|
||||||
|
# include <amxmodx_version.h>
|
||||||
|
#else
|
||||||
|
# define SVN_VERSION "dev-local"
|
||||||
|
#endif
|
||||||
|
|
||||||
// Module info
|
// Module info
|
||||||
#define MODULE_NAME "GeoIP"
|
#define MODULE_NAME "GeoIP"
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "1.8.2-dev"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "$PMAJOR$.$PMINOR$.$PREVISION$$BUILD_STRING$"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
19
dlls/hamsandwich/AMBuilder
Normal file
19
dlls/hamsandwich/AMBuilder
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.MetaModule(builder, 'hamsandwich')
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'sdk/amxxmodule.cpp',
|
||||||
|
'amxx_api.cpp',
|
||||||
|
'config_parser.cpp',
|
||||||
|
'hook_callbacks.cpp',
|
||||||
|
'hook_native.cpp',
|
||||||
|
'srvcmd.cpp',
|
||||||
|
'call_funcs.cpp',
|
||||||
|
'hook_create.cpp',
|
||||||
|
'DataHandler.cpp',
|
||||||
|
'pdata.cpp',
|
||||||
|
]
|
||||||
|
|
||||||
|
AMXX.modules += [builder.Add(binary)]
|
@ -3,7 +3,11 @@
|
|||||||
#ifndef __MODULECONFIG_H__
|
#ifndef __MODULECONFIG_H__
|
||||||
#define __MODULECONFIG_H__
|
#define __MODULECONFIG_H__
|
||||||
|
|
||||||
#include "../svn_version.h"
|
#if defined AMBUILD
|
||||||
|
# include <amxmodx_version.h>
|
||||||
|
#else
|
||||||
|
# define SVN_VERSION "dev-local"
|
||||||
|
#endif
|
||||||
|
|
||||||
// Module info
|
// Module info
|
||||||
#define MODULE_NAME "Ham Sandwich"
|
#define MODULE_NAME "Ham Sandwich"
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "1.8.2-dev"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "$PMAJOR$.$PMINOR$.$PREVISION$$BUILD_STRING$"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
48
dlls/mysqlx/AMBuilder
Normal file
48
dlls/mysqlx/AMBuilder
Normal file
@ -0,0 +1,48 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
if AMXX.mysql_path:
|
||||||
|
binary = AMXX.MetaModule(builder, 'mysql')
|
||||||
|
|
||||||
|
binary.compiler.cxxincludes += [
|
||||||
|
os.path.join(AMXX.mysql_path, 'include'),
|
||||||
|
os.path.join(builder.currentSourcePath, 'mysql'),
|
||||||
|
os.path.join(builder.currentSourcePath, 'thread'),
|
||||||
|
]
|
||||||
|
|
||||||
|
binary.compiler.defines += [
|
||||||
|
'SM_DEFAULT_THREADER',
|
||||||
|
'stricmp=strcasecmp',
|
||||||
|
]
|
||||||
|
|
||||||
|
if builder.target_platform is 'linux' or builder.target_platform is 'mac':
|
||||||
|
binary.compiler.linkflags += [
|
||||||
|
os.path.join(AMXX.mysql_path, 'lib', 'libmysqlclient_r.a'),
|
||||||
|
'-lz',
|
||||||
|
'-lpthread',
|
||||||
|
'-lm'
|
||||||
|
]
|
||||||
|
elif builder.target_platform is 'windows':
|
||||||
|
binary.compiler.linkflags += [
|
||||||
|
os.path.join(AMXX.mysql_path, 'lib', 'opt', 'mysqlclient.lib'),
|
||||||
|
os.path.join(AMXX.mysql_path, 'lib', 'opt', 'zlib.lib'),
|
||||||
|
'wsock32.lib'
|
||||||
|
]
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'basic_sql.cpp',
|
||||||
|
'handles.cpp',
|
||||||
|
'module.cpp',
|
||||||
|
'threading.cpp',
|
||||||
|
'sdk/amxxmodule.cpp',
|
||||||
|
'oldcompat_sql.cpp',
|
||||||
|
'thread/BaseWorker.cpp',
|
||||||
|
'thread/ThreadWorker.cpp',
|
||||||
|
'thread/PosixThreads.cpp',
|
||||||
|
'mysql/MysqlQuery.cpp',
|
||||||
|
'mysql/MysqlResultSet.cpp',
|
||||||
|
'mysql/MysqlDatabase.cpp',
|
||||||
|
'mysql/MysqlDriver.cpp',
|
||||||
|
]
|
||||||
|
|
||||||
|
AMXX.modules += [builder.Add(binary)]
|
@ -3,7 +3,11 @@
|
|||||||
#ifndef __MODULECONFIG_H__
|
#ifndef __MODULECONFIG_H__
|
||||||
#define __MODULECONFIG_H__
|
#define __MODULECONFIG_H__
|
||||||
|
|
||||||
#include "svn_version.h"
|
#if defined AMBUILD
|
||||||
|
# include <amxmodx_version.h>
|
||||||
|
#else
|
||||||
|
# define SVN_VERSION "dev-local"
|
||||||
|
#endif
|
||||||
|
|
||||||
/** Module info
|
/** Module info
|
||||||
* -The logtag is the tag that the module's log messages will be
|
* -The logtag is the tag that the module's log messages will be
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "1.8.2-dev"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "$PMAJOR$.$PMINOR$.$PREVISION$$BUILD_STRING$"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
25
dlls/ns/AMBuilder
Normal file
25
dlls/ns/AMBuilder
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.MetaModule(builder, 'ns')
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'sdk/amxxmodule.cpp',
|
||||||
|
'dllapi.cpp',
|
||||||
|
'utils.cpp',
|
||||||
|
'amxxapi.cpp',
|
||||||
|
'engineapi.cpp',
|
||||||
|
'TitleManager.cpp',
|
||||||
|
'ParticleManager.cpp',
|
||||||
|
'MessageHandler.cpp',
|
||||||
|
'GameManager.cpp',
|
||||||
|
'natives/general.cpp',
|
||||||
|
'natives/player.cpp',
|
||||||
|
'natives/player_memory.cpp',
|
||||||
|
'natives/structure.cpp',
|
||||||
|
'natives/weapons.cpp',
|
||||||
|
'natives/particles.cpp',
|
||||||
|
'natives/memberfuncs.cpp',
|
||||||
|
]
|
||||||
|
|
||||||
|
AMXX.modules += [builder.Add(binary)]
|
@ -3,7 +3,11 @@
|
|||||||
#ifndef __MODULECONFIG_H__
|
#ifndef __MODULECONFIG_H__
|
||||||
#define __MODULECONFIG_H__
|
#define __MODULECONFIG_H__
|
||||||
|
|
||||||
#include "../svn_version.h"
|
#if defined AMBUILD
|
||||||
|
# include <amxmodx_version.h>
|
||||||
|
#else
|
||||||
|
# define SVN_VERSION "dev-local"
|
||||||
|
#endif
|
||||||
|
|
||||||
// Module info
|
// Module info
|
||||||
#define MODULE_NAME "NS"
|
#define MODULE_NAME "NS"
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "1.8.2-dev"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "$PMAJOR$.$PMINOR$.$PREVISION$$BUILD_STRING$"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
14
dlls/nvault/AMBuilder
Normal file
14
dlls/nvault/AMBuilder
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.Module(builder, 'nvault')
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'sdk/amxxmodule.cpp',
|
||||||
|
'amxxapi.cpp',
|
||||||
|
'Binary.cpp',
|
||||||
|
'Journal.cpp',
|
||||||
|
'NVault.cpp',
|
||||||
|
]
|
||||||
|
|
||||||
|
AMXX.modules += [builder.Add(binary)]
|
@ -3,7 +3,11 @@
|
|||||||
#ifndef __MODULECONFIG_H__
|
#ifndef __MODULECONFIG_H__
|
||||||
#define __MODULECONFIG_H__
|
#define __MODULECONFIG_H__
|
||||||
|
|
||||||
#include "svn_version.h"
|
#if defined AMBUILD
|
||||||
|
# include <amxmodx_version.h>
|
||||||
|
#else
|
||||||
|
# define SVN_VERSION "dev-local"
|
||||||
|
#endif
|
||||||
|
|
||||||
// Module info
|
// Module info
|
||||||
#define MODULE_NAME "nVault"
|
#define MODULE_NAME "nVault"
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "1.8.2-dev"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "$PMAJOR$.$PMINOR$.$PREVISION$$BUILD_STRING$"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
21
dlls/regex/AMBuilder
Normal file
21
dlls/regex/AMBuilder
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.Module(builder, 'regex')
|
||||||
|
|
||||||
|
if builder.target_platform == 'linux':
|
||||||
|
binary.compiler.postlink += [binary.Dep('lib_linux/libpcre.a')]
|
||||||
|
elif builder.target_platform == 'mac':
|
||||||
|
binary.compiler.postlink += [binary.Dep('lib_darwin/libpcre.a')]
|
||||||
|
elif builder.target_platform == 'windows':
|
||||||
|
binary.compiler.postlink += [binary.Dep('lib_win\\pcre.lib')]
|
||||||
|
|
||||||
|
binary.compiler.defines += ['PCRE_STATIC']
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'sdk/amxxmodule.cpp',
|
||||||
|
'module.cpp',
|
||||||
|
'CRegEx.cpp',
|
||||||
|
]
|
||||||
|
|
||||||
|
AMXX.modules += [builder.Add(binary)]
|
@ -3,7 +3,11 @@
|
|||||||
#ifndef __MODULECONFIG_H__
|
#ifndef __MODULECONFIG_H__
|
||||||
#define __MODULECONFIG_H__
|
#define __MODULECONFIG_H__
|
||||||
|
|
||||||
#include "svn_version.h"
|
#if defined AMBUILD
|
||||||
|
# include <amxmodx_version.h>
|
||||||
|
#else
|
||||||
|
# define SVN_VERSION "dev-local"
|
||||||
|
#endif
|
||||||
|
|
||||||
// Module info
|
// Module info
|
||||||
#define MODULE_NAME "RegEx"
|
#define MODULE_NAME "RegEx"
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "1.8.2-dev"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "$PMAJOR$.$PMINOR$.$PREVISION$$BUILD_STRING$"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
14
dlls/sockets/AMBuilder
Normal file
14
dlls/sockets/AMBuilder
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.Module(builder, 'sockets')
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'sdk/amxxmodule.cpp',
|
||||||
|
'sockets.cpp',
|
||||||
|
]
|
||||||
|
|
||||||
|
if builder.target_platform == 'windows':
|
||||||
|
binary.compiler.postlink += ['wsock32.lib', 'ws2_32.lib']
|
||||||
|
|
||||||
|
AMXX.modules += [builder.Add(binary)]
|
@ -3,7 +3,11 @@
|
|||||||
#ifndef __MODULECONFIG_H__
|
#ifndef __MODULECONFIG_H__
|
||||||
#define __MODULECONFIG_H__
|
#define __MODULECONFIG_H__
|
||||||
|
|
||||||
#include "svn_version.h"
|
#if defined AMBUILD
|
||||||
|
# include <amxmodx_version.h>
|
||||||
|
#else
|
||||||
|
# define SVN_VERSION "dev-local"
|
||||||
|
#endif
|
||||||
|
|
||||||
// Module info
|
// Module info
|
||||||
#define MODULE_NAME "Sockets"
|
#define MODULE_NAME "Sockets"
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "1.8.2-dev"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "$PMAJOR$.$PMINOR$.$PREVISION$$BUILD_STRING$"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
85
dlls/sqlite/AMBuilder
Normal file
85
dlls/sqlite/AMBuilder
Normal file
@ -0,0 +1,85 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.MetaModule(builder, 'sqlite')
|
||||||
|
binary.compiler.cxxincludes += [
|
||||||
|
os.path.join(builder.currentSourcePath, 'sqlitepp'),
|
||||||
|
os.path.join(builder.currentSourcePath, 'thread'),
|
||||||
|
os.path.join(builder.currentSourcePath, 'sqlite-source'),
|
||||||
|
]
|
||||||
|
binary.compiler.defines += [
|
||||||
|
'SM_DEFAULT_THREADER',
|
||||||
|
'stricmp=strcasecmp',
|
||||||
|
]
|
||||||
|
|
||||||
|
if builder.target_platform == 'linux':
|
||||||
|
binary.compiler.postlink += ['-lpthread']
|
||||||
|
|
||||||
|
binary.sources += [
|
||||||
|
'basic_sql.cpp',
|
||||||
|
'handles.cpp',
|
||||||
|
'module.cpp',
|
||||||
|
'threading.cpp',
|
||||||
|
'sdk/amxxmodule.cpp',
|
||||||
|
'oldcompat_sql.cpp',
|
||||||
|
'thread/BaseWorker.cpp',
|
||||||
|
'thread/ThreadWorker.cpp',
|
||||||
|
'sqlitepp/SqliteQuery.cpp',
|
||||||
|
'sqlitepp/SqliteResultSet.cpp',
|
||||||
|
'sqlitepp/SqliteDatabase.cpp',
|
||||||
|
'sqlitepp/SqliteDriver.cpp',
|
||||||
|
'sqlite-source/alter.c',
|
||||||
|
'sqlite-source/analyze.c',
|
||||||
|
'sqlite-source/attach.c',
|
||||||
|
'sqlite-source/auth.c',
|
||||||
|
'sqlite-source/btree.c',
|
||||||
|
'sqlite-source/build.c',
|
||||||
|
'sqlite-source/callback.c',
|
||||||
|
'sqlite-source/complete.c',
|
||||||
|
'sqlite-source/date.c',
|
||||||
|
'sqlite-source/delete.c',
|
||||||
|
'sqlite-source/expr.c',
|
||||||
|
'sqlite-source/func.c',
|
||||||
|
'sqlite-source/hash.c',
|
||||||
|
'sqlite-source/insert.c',
|
||||||
|
'sqlite-source/legacy.c',
|
||||||
|
'sqlite-source/loadext.c',
|
||||||
|
'sqlite-source/main.c',
|
||||||
|
'sqlite-source/opcodes.c',
|
||||||
|
'sqlite-source/os.c',
|
||||||
|
'sqlite-source/pager.c',
|
||||||
|
'sqlite-source/parse.c',
|
||||||
|
'sqlite-source/pragma.c',
|
||||||
|
'sqlite-source/prepare.c',
|
||||||
|
'sqlite-source/printf.c',
|
||||||
|
'sqlite-source/random.c',
|
||||||
|
'sqlite-source/select.c',
|
||||||
|
'sqlite-source/table.c',
|
||||||
|
'sqlite-source/tokenize.c',
|
||||||
|
'sqlite-source/trigger.c',
|
||||||
|
'sqlite-source/update.c',
|
||||||
|
'sqlite-source/utf.c',
|
||||||
|
'sqlite-source/util.c',
|
||||||
|
'sqlite-source/vacuum.c',
|
||||||
|
'sqlite-source/vdbe.c',
|
||||||
|
'sqlite-source/vdbeapi.c',
|
||||||
|
'sqlite-source/vdbeaux.c',
|
||||||
|
'sqlite-source/vdbefifo.c',
|
||||||
|
'sqlite-source/vdbemem.c',
|
||||||
|
'sqlite-source/vtab.c',
|
||||||
|
'sqlite-source/where.c',
|
||||||
|
]
|
||||||
|
|
||||||
|
if builder.target_platform == 'windows':
|
||||||
|
binary.sources += [
|
||||||
|
'thread/WinThreads.cpp',
|
||||||
|
'sqlite-source/os_win.c',
|
||||||
|
]
|
||||||
|
else:
|
||||||
|
binary.sources += [
|
||||||
|
'thread/PosixThreads.cpp',
|
||||||
|
'sqlite-source/os_unix.c',
|
||||||
|
]
|
||||||
|
|
||||||
|
|
||||||
|
AMXX.modules += [builder.Add(binary)]
|
@ -3,7 +3,11 @@
|
|||||||
#ifndef __MODULECONFIG_H__
|
#ifndef __MODULECONFIG_H__
|
||||||
#define __MODULECONFIG_H__
|
#define __MODULECONFIG_H__
|
||||||
|
|
||||||
#include "svn_version.h"
|
#if defined AMBUILD
|
||||||
|
# include <amxmodx_version.h>
|
||||||
|
#else
|
||||||
|
# define SVN_VERSION "dev-local"
|
||||||
|
#endif
|
||||||
|
|
||||||
// Module info
|
// Module info
|
||||||
#define MODULE_NAME "SQLite"
|
#define MODULE_NAME "SQLite"
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "1.8.2-dev"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "$PMAJOR$.$PMINOR$.$PREVISION$$BUILD_STRING$"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
17
dlls/tfcx/AMBuilder
Normal file
17
dlls/tfcx/AMBuilder
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.MetaModule(builder, 'tfcx')
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'sdk/amxxmodule.cpp',
|
||||||
|
'CRank.cpp',
|
||||||
|
'CMisc.cpp',
|
||||||
|
'NBase.cpp',
|
||||||
|
'NRank.cpp',
|
||||||
|
'usermsg.cpp',
|
||||||
|
'Utils.cpp',
|
||||||
|
'moduleconfig.cpp',
|
||||||
|
]
|
||||||
|
|
||||||
|
AMXX.modules += [builder.Add(binary)]
|
@ -3,7 +3,11 @@
|
|||||||
#ifndef __MODULECONFIG_H__
|
#ifndef __MODULECONFIG_H__
|
||||||
#define __MODULECONFIG_H__
|
#define __MODULECONFIG_H__
|
||||||
|
|
||||||
#include "svn_version.h"
|
#if defined AMBUILD
|
||||||
|
# include <amxmodx_version.h>
|
||||||
|
#else
|
||||||
|
# define SVN_VERSION "dev-local"
|
||||||
|
#endif
|
||||||
|
|
||||||
// Module info
|
// Module info
|
||||||
#define MODULE_NAME "TfcX"
|
#define MODULE_NAME "TfcX"
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "1.8.2-dev"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "$PMAJOR$.$PMINOR$.$PREVISION$$BUILD_STRING$"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
10
dlls/ts/tsfun/AMBuilder
Normal file
10
dlls/ts/tsfun/AMBuilder
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.MetaModule(builder, 'tsfun')
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'sdk/amxxmodule.cpp',
|
||||||
|
]
|
||||||
|
|
||||||
|
AMXX.modules += [builder.Add(binary)]
|
@ -3,7 +3,11 @@
|
|||||||
#ifndef __MODULECONFIG_H__
|
#ifndef __MODULECONFIG_H__
|
||||||
#define __MODULECONFIG_H__
|
#define __MODULECONFIG_H__
|
||||||
|
|
||||||
#include "svn_version.h"
|
#if defined AMBUILD
|
||||||
|
# include <amxmodx_version.h>
|
||||||
|
#else
|
||||||
|
# define SVN_VERSION "dev-local"
|
||||||
|
#endif
|
||||||
|
|
||||||
// Module info
|
// Module info
|
||||||
#define MODULE_NAME "TSFun Wrapper"
|
#define MODULE_NAME "TSFun Wrapper"
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "1.8.2-dev"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "$PMAJOR$.$PMINOR$.$PREVISION$$BUILD_STRING$"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
17
dlls/ts/tsx/AMBuilder
Normal file
17
dlls/ts/tsx/AMBuilder
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
# vim: set sts=2 ts=8 sw=2 tw=99 et ft=python:
|
||||||
|
import os.path
|
||||||
|
|
||||||
|
binary = AMXX.MetaModule(builder, 'tsx')
|
||||||
|
|
||||||
|
binary.sources = [
|
||||||
|
'sdk/amxxmodule.cpp',
|
||||||
|
'CMisc.cpp',
|
||||||
|
'CRank.cpp',
|
||||||
|
'NBase.cpp',
|
||||||
|
'NRank.cpp',
|
||||||
|
'Utils.cpp',
|
||||||
|
'moduleconfig.cpp',
|
||||||
|
'usermsg.cpp',
|
||||||
|
]
|
||||||
|
|
||||||
|
AMXX.modules += [builder.Add(binary)]
|
@ -3,7 +3,11 @@
|
|||||||
#ifndef __MODULECONFIG_H__
|
#ifndef __MODULECONFIG_H__
|
||||||
#define __MODULECONFIG_H__
|
#define __MODULECONFIG_H__
|
||||||
|
|
||||||
#include "svn_version.h"
|
#if defined AMBUILD
|
||||||
|
# include <amxmodx_version.h>
|
||||||
|
#else
|
||||||
|
# define SVN_VERSION "dev-local"
|
||||||
|
#endif
|
||||||
|
|
||||||
// Module info
|
// Module info
|
||||||
#define MODULE_NAME "TSX"
|
#define MODULE_NAME "TSX"
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "1.8.2-dev"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -1,9 +0,0 @@
|
|||||||
#ifndef _INCLUDE_SVN_VERSION_H_
|
|
||||||
#define _INCLUDE_SVN_VERSION_H_
|
|
||||||
|
|
||||||
/** This file is auto-generated by build scripts. Do not edit it unless you know what you're doing. */
|
|
||||||
/** Do not commit the generated .h file, as it will only mess up SVN revision numbers. */
|
|
||||||
|
|
||||||
#define SVN_VERSION "$PMAJOR$.$PMINOR$.$PREVISION$$BUILD_STRING$"
|
|
||||||
|
|
||||||
#endif //_INCLUDE_SVN_VERSION_H_
|
|
@ -1,249 +0,0 @@
|
|||||||
using System;
|
|
||||||
using System.Diagnostics;
|
|
||||||
using System.IO;
|
|
||||||
|
|
||||||
namespace AMXXRelease
|
|
||||||
{
|
|
||||||
//This class specifies the process that builds a release.
|
|
||||||
//It also implements the functions that are unlikely to change from mod to mod.
|
|
||||||
public abstract class ABuilder
|
|
||||||
{
|
|
||||||
protected Config m_Cfg;
|
|
||||||
|
|
||||||
public virtual void OnBuild()
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
public virtual void CreateDir(string dir)
|
|
||||||
{
|
|
||||||
Directory.CreateDirectory(dir);
|
|
||||||
}
|
|
||||||
|
|
||||||
public virtual bool Build(Config cfg, Build build)
|
|
||||||
{
|
|
||||||
m_Cfg = cfg;
|
|
||||||
|
|
||||||
OnBuild();
|
|
||||||
|
|
||||||
int num = build.GetMods();
|
|
||||||
|
|
||||||
AMod mod;
|
|
||||||
for (int i=0; i<num; i++)
|
|
||||||
{
|
|
||||||
mod = build.GetMod(i);
|
|
||||||
if (!BuildMod(mod))
|
|
||||||
{
|
|
||||||
System.Console.WriteLine("Mod failed to build: " + mod.GetName());
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
if (m_Cfg.CompressPath() != null)
|
|
||||||
{
|
|
||||||
CompressDir(
|
|
||||||
PropSlashes(m_Cfg.OutputPath() + "\\" + m_Cfg.GetReleaseName() + "-" + mod.GetName()),
|
|
||||||
PropSlashes(m_Cfg.OutputPath() + "\\" + mod.GetName())
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
public virtual bool BuildMod(AMod mod)
|
|
||||||
{
|
|
||||||
CopyConfigs(mod);
|
|
||||||
if (!BuildModModules(mod))
|
|
||||||
return false;
|
|
||||||
if (!BuildModPlugins(mod))
|
|
||||||
return false;
|
|
||||||
|
|
||||||
string basedir = PropSlashes(m_Cfg.OutputPath() + "\\" + mod.GetModPath());
|
|
||||||
string sourcetree = m_Cfg.GetSourceTree();
|
|
||||||
|
|
||||||
if (!mod.CopyExtraFiles(this, basedir, sourcetree))
|
|
||||||
return false;
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
public virtual void CopyConfigs(AMod mod)
|
|
||||||
{
|
|
||||||
string basedir = PropSlashes(m_Cfg.OutputPath() + "\\" + mod.GetModPath() + "\\configs");
|
|
||||||
|
|
||||||
if (!Directory.Exists(basedir))
|
|
||||||
CreateDir(basedir);
|
|
||||||
|
|
||||||
string srcdir = PropSlashes(m_Cfg.GetSourceTree() + "\\configs");
|
|
||||||
|
|
||||||
if (!Directory.Exists(srcdir))
|
|
||||||
return;
|
|
||||||
|
|
||||||
if (mod.GetPluginDir() != null)
|
|
||||||
srcdir += "\\" + mod.GetBaseName();
|
|
||||||
|
|
||||||
srcdir = PropSlashes(srcdir);
|
|
||||||
|
|
||||||
CopyNormal(this, srcdir, basedir);
|
|
||||||
}
|
|
||||||
|
|
||||||
public static void CopyNormal(ABuilder ab, string src, string dest)
|
|
||||||
{
|
|
||||||
string[] files = Directory.GetFiles(src);
|
|
||||||
|
|
||||||
if (!Directory.Exists(dest))
|
|
||||||
ab.CreateDir(dest);
|
|
||||||
|
|
||||||
for (int i=0; i<files.Length; i++)
|
|
||||||
{
|
|
||||||
File.Copy(files[i],
|
|
||||||
PropSlashes(dest + "\\" + GetFileName(files[i])),
|
|
||||||
true);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public virtual bool BuildModPlugins(AMod mod)
|
|
||||||
{
|
|
||||||
int num = mod.GetPlugins();
|
|
||||||
|
|
||||||
Plugin plugin;
|
|
||||||
string binary, basedir;
|
|
||||||
|
|
||||||
basedir = m_Cfg.OutputPath();
|
|
||||||
basedir += "\\" + mod.GetModPath();
|
|
||||||
basedir = PropSlashes(basedir);
|
|
||||||
|
|
||||||
string dir, file, target;
|
|
||||||
for (int i=0; i<num; i++)
|
|
||||||
{
|
|
||||||
plugin = mod.GetPlugin(i);
|
|
||||||
binary = BuildPlugin(mod, plugin);
|
|
||||||
file = PropSlashes(m_Cfg.GetSourceTree() + "\\plugins\\" + GetFileName(binary));
|
|
||||||
if (!File.Exists(file))
|
|
||||||
{
|
|
||||||
System.Console.WriteLine("Plugin failed to compile: " +
|
|
||||||
mod.GetName() + "::" + plugin.name);
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
dir = PropSlashes(basedir + "\\" + plugin.outdir);
|
|
||||||
if (!Directory.Exists(dir))
|
|
||||||
CreateDir(dir);
|
|
||||||
target = PropSlashes(dir + "\\" + plugin.name + ".amxx");
|
|
||||||
if (File.Exists(target))
|
|
||||||
File.Delete(target);
|
|
||||||
File.Move(file,
|
|
||||||
target);
|
|
||||||
}
|
|
||||||
|
|
||||||
//Copy all files from the plugins dir to scripting
|
|
||||||
|
|
||||||
string search_dir = m_Cfg.GetSourceTree() + "\\plugins";
|
|
||||||
if (mod.GetPluginDir() != null)
|
|
||||||
search_dir += "\\" + mod.GetPluginDir();
|
|
||||||
search_dir = PropSlashes(search_dir);
|
|
||||||
|
|
||||||
string dest;
|
|
||||||
if (Directory.Exists(search_dir))
|
|
||||||
{
|
|
||||||
string[] files = Directory.GetFiles(search_dir);
|
|
||||||
if (!Directory.Exists(PropSlashes(basedir + "\\scripting")))
|
|
||||||
CreateDir(PropSlashes(basedir + "\\scripting"));
|
|
||||||
for (int i=0; i<files.Length; i++)
|
|
||||||
{
|
|
||||||
dest = PropSlashes(basedir + "\\scripting\\" + GetFileName(files[i]));
|
|
||||||
if (mod.ExcludeCopy(files[i]))
|
|
||||||
continue;
|
|
||||||
File.Copy(files[i], dest, true);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
public static string GetFileName(string input)
|
|
||||||
{
|
|
||||||
for (int i=input.Length-1; i>=0; i--)
|
|
||||||
{
|
|
||||||
if ((input[i] == '\\' || input[i] == '/') && i != input.Length-1)
|
|
||||||
{
|
|
||||||
return input.Substring(i+1, input.Length-i-1);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return input;
|
|
||||||
}
|
|
||||||
|
|
||||||
public virtual bool BuildModModules(AMod mod)
|
|
||||||
{
|
|
||||||
int num = mod.GetModules();
|
|
||||||
|
|
||||||
Module module;
|
|
||||||
string binary, basedir;
|
|
||||||
|
|
||||||
basedir = m_Cfg.OutputPath();
|
|
||||||
basedir += "\\" + mod.GetModPath();
|
|
||||||
basedir = PropSlashes(basedir);
|
|
||||||
|
|
||||||
string dir;
|
|
||||||
for (int i=0; i<num; i++)
|
|
||||||
{
|
|
||||||
module = mod.GetModule(i);
|
|
||||||
binary = BuildModule(module);
|
|
||||||
|
|
||||||
if (binary == null)
|
|
||||||
{
|
|
||||||
System.Console.WriteLine("Module failed to compile: " +
|
|
||||||
mod.GetName() + "::" + module.projname + GetLibExt());
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
dir = PropSlashes(basedir + "\\" + module.outdir);
|
|
||||||
if (!Directory.Exists(dir))
|
|
||||||
CreateDir(dir);
|
|
||||||
File.Copy(binary,
|
|
||||||
PropSlashes(dir + "\\" + module.projname + GetLibExt()),
|
|
||||||
true);
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
public virtual string BuildPlugin(AMod mod, Plugin pl)
|
|
||||||
{
|
|
||||||
string modoffs = mod.GetPluginDir();
|
|
||||||
string pldir;
|
|
||||||
|
|
||||||
if (modoffs != null)
|
|
||||||
pldir = modoffs + "\\";
|
|
||||||
else
|
|
||||||
pldir = "";
|
|
||||||
|
|
||||||
AmxxPc(PropSlashes(pldir + pl.source), pl.options);
|
|
||||||
|
|
||||||
string outfile = pldir + pl.name + ".amxx";
|
|
||||||
|
|
||||||
return outfile;
|
|
||||||
}
|
|
||||||
|
|
||||||
public abstract void AmxxPc(string inpath, string args);
|
|
||||||
|
|
||||||
public abstract string BuildModule(Module module);
|
|
||||||
|
|
||||||
public abstract string GetLibExt();
|
|
||||||
|
|
||||||
public abstract void CompressDir(string target, string dir);
|
|
||||||
|
|
||||||
public static string PropSlashes(string path)
|
|
||||||
{
|
|
||||||
char sep;
|
|
||||||
char alt;
|
|
||||||
if (Releaser.IsWindows)
|
|
||||||
{
|
|
||||||
sep = '\\';
|
|
||||||
alt = '/';
|
|
||||||
} else {
|
|
||||||
sep = '/';
|
|
||||||
alt = '\\';
|
|
||||||
}
|
|
||||||
return path.Replace(alt,sep);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,123 +0,0 @@
|
|||||||
using System;
|
|
||||||
using System.Diagnostics;
|
|
||||||
using System.Collections;
|
|
||||||
|
|
||||||
namespace AMXXRelease
|
|
||||||
{
|
|
||||||
//Holds information about a plugin
|
|
||||||
public class Plugin
|
|
||||||
{
|
|
||||||
public string name; //Plugin output file name
|
|
||||||
public string source; //Source code file
|
|
||||||
public string options; //Compile-time options
|
|
||||||
public string outdir; //Output folder
|
|
||||||
|
|
||||||
public Plugin(string Name)
|
|
||||||
{
|
|
||||||
name = (string)Name.Clone();
|
|
||||||
source = (string)Name.Clone();
|
|
||||||
outdir = "plugins";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
//Holds information necessary to compile a module/C++ program
|
|
||||||
public class Module
|
|
||||||
{
|
|
||||||
public string sourcedir; //Source directory
|
|
||||||
public string projname; //Output binary name (such as amxmodx_mm)
|
|
||||||
public string build; //Build configuration
|
|
||||||
public string bindir; //Binary directory
|
|
||||||
public string vcproj; //VCProj file name
|
|
||||||
public string outdir; //Output directory
|
|
||||||
|
|
||||||
public Module()
|
|
||||||
{
|
|
||||||
build = "Release";
|
|
||||||
outdir = "modules";
|
|
||||||
bindir = "msvc10";
|
|
||||||
}
|
|
||||||
|
|
||||||
public Module(string name)
|
|
||||||
{
|
|
||||||
build = "Release";
|
|
||||||
outdir = "modules";
|
|
||||||
sourcedir = "dlls\\" + name;
|
|
||||||
bindir = "msvc10";
|
|
||||||
projname = name + "_amxx";
|
|
||||||
vcproj = name;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
//Class that represents how a mod wants to be built.
|
|
||||||
//It exports a list of functions, mods, and a few
|
|
||||||
// tidbits of information. It can also hook an extra
|
|
||||||
// step for copying miscellanious files.
|
|
||||||
public abstract class AMod
|
|
||||||
{
|
|
||||||
protected ArrayList m_Modules;
|
|
||||||
protected ArrayList m_Plugins;
|
|
||||||
|
|
||||||
public abstract string GetName();
|
|
||||||
|
|
||||||
public virtual string GetBaseName()
|
|
||||||
{
|
|
||||||
return GetName();
|
|
||||||
}
|
|
||||||
|
|
||||||
public AMod()
|
|
||||||
{
|
|
||||||
m_Modules = new ArrayList();
|
|
||||||
m_Plugins = new ArrayList();
|
|
||||||
}
|
|
||||||
|
|
||||||
//called when it's okay to build an extra dir structure
|
|
||||||
// and copy files to it
|
|
||||||
public virtual bool CopyExtraFiles(ABuilder ab, string basedir, string sourcedir)
|
|
||||||
{
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
//defines a copy prevention filter
|
|
||||||
public virtual bool ExcludeCopy(string file)
|
|
||||||
{
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
public virtual string GetPluginDir()
|
|
||||||
{
|
|
||||||
return GetName();
|
|
||||||
}
|
|
||||||
|
|
||||||
public virtual int GetModules()
|
|
||||||
{
|
|
||||||
return m_Modules.Count;
|
|
||||||
}
|
|
||||||
|
|
||||||
public virtual Module GetModule(int i)
|
|
||||||
{
|
|
||||||
return (Module)m_Modules[i];
|
|
||||||
}
|
|
||||||
|
|
||||||
public virtual int GetPlugins()
|
|
||||||
{
|
|
||||||
return m_Plugins.Count;
|
|
||||||
}
|
|
||||||
|
|
||||||
public virtual string GetModPath()
|
|
||||||
{
|
|
||||||
return GetName() + "\\addons\\amxmodx";
|
|
||||||
}
|
|
||||||
|
|
||||||
public virtual Plugin GetPlugin(int i)
|
|
||||||
{
|
|
||||||
return (Plugin)m_Plugins[i];
|
|
||||||
}
|
|
||||||
|
|
||||||
public virtual Plugin AddPlugin(string name)
|
|
||||||
{
|
|
||||||
Plugin pl = new Plugin(name);
|
|
||||||
m_Plugins.Add(pl);
|
|
||||||
return pl;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
Binary file not shown.
Before Width: | Height: | Size: 1.1 KiB |
@ -1,52 +0,0 @@
|
|||||||
using System;
|
|
||||||
using System.Collections;
|
|
||||||
|
|
||||||
namespace AMXXRelease
|
|
||||||
{
|
|
||||||
//Class that iterates the different pieces
|
|
||||||
// to be completed over for the build
|
|
||||||
public class Build
|
|
||||||
{
|
|
||||||
protected ArrayList m_Mods;
|
|
||||||
protected Config m_Cfg;
|
|
||||||
|
|
||||||
public Build(Config cfg)
|
|
||||||
{
|
|
||||||
m_Mods = new ArrayList();
|
|
||||||
m_Cfg = cfg;
|
|
||||||
|
|
||||||
CoreMod core = new CoreMod();
|
|
||||||
ModCstrike cstrike = new ModCstrike();
|
|
||||||
ModDoD dod = new ModDoD();
|
|
||||||
ModTFC tfc = new ModTFC();
|
|
||||||
|
|
||||||
m_Mods.Add(core);
|
|
||||||
m_Mods.Add(cstrike);
|
|
||||||
m_Mods.Add(dod);
|
|
||||||
m_Mods.Add(tfc);
|
|
||||||
|
|
||||||
// These mods don't have OS X builds
|
|
||||||
if (!Releaser.IsOSX)
|
|
||||||
{
|
|
||||||
ModEsf esf = new ModEsf();
|
|
||||||
ModNs ns = new ModNs();
|
|
||||||
ModTs ts = new ModTs();
|
|
||||||
|
|
||||||
m_Mods.Add(esf);
|
|
||||||
m_Mods.Add(ns);
|
|
||||||
m_Mods.Add(ts);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
public virtual int GetMods()
|
|
||||||
{
|
|
||||||
return m_Mods.Count;
|
|
||||||
}
|
|
||||||
|
|
||||||
public virtual AMod GetMod(int i)
|
|
||||||
{
|
|
||||||
return (AMod)m_Mods[i];
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,100 +0,0 @@
|
|||||||
using System;
|
|
||||||
using System.IO;
|
|
||||||
|
|
||||||
namespace AMXXRelease
|
|
||||||
{
|
|
||||||
//Reads in config file info
|
|
||||||
public class Config
|
|
||||||
{
|
|
||||||
private string m_SourceTree;
|
|
||||||
private string m_OutputPath;
|
|
||||||
private string m_DevenvPath;
|
|
||||||
private string m_PathToCompress;
|
|
||||||
private string m_ReleaseName;
|
|
||||||
private string m_MakeOpts;
|
|
||||||
|
|
||||||
public Config()
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
public string GetSourceTree()
|
|
||||||
{
|
|
||||||
return m_SourceTree;
|
|
||||||
}
|
|
||||||
|
|
||||||
public string OutputPath()
|
|
||||||
{
|
|
||||||
return m_OutputPath;
|
|
||||||
}
|
|
||||||
|
|
||||||
public string DevenvPath()
|
|
||||||
{
|
|
||||||
return m_DevenvPath;
|
|
||||||
}
|
|
||||||
|
|
||||||
public string CompressPath()
|
|
||||||
{
|
|
||||||
return m_PathToCompress;
|
|
||||||
}
|
|
||||||
|
|
||||||
public string GetReleaseName()
|
|
||||||
{
|
|
||||||
return m_ReleaseName;
|
|
||||||
}
|
|
||||||
|
|
||||||
public string MakeOpts()
|
|
||||||
{
|
|
||||||
return m_MakeOpts;
|
|
||||||
}
|
|
||||||
|
|
||||||
public bool ReadFromFile(string file)
|
|
||||||
{
|
|
||||||
try
|
|
||||||
{
|
|
||||||
StreamReader sr = new StreamReader(file);
|
|
||||||
|
|
||||||
string line;
|
|
||||||
string delim = "\t \n\r\v";
|
|
||||||
string splt = "=";
|
|
||||||
while ( (line = sr.ReadLine()) != null )
|
|
||||||
{
|
|
||||||
line = line.Trim(delim.ToCharArray());
|
|
||||||
if (line.Length < 1 || line[0] == ';')
|
|
||||||
continue;
|
|
||||||
string [] s = line.Split(splt.ToCharArray());
|
|
||||||
string key, val="";
|
|
||||||
if (s.GetLength(0) >= 1)
|
|
||||||
{
|
|
||||||
key = s[0];
|
|
||||||
if (s.GetLength(0) >= 2)
|
|
||||||
{
|
|
||||||
for(int i=1; i<s.GetLength(0); i++)
|
|
||||||
val += s[i];
|
|
||||||
}
|
|
||||||
key = key.Trim(delim.ToCharArray());
|
|
||||||
val = val.Trim(delim.ToCharArray());
|
|
||||||
if (key.CompareTo("compress")==0)
|
|
||||||
m_PathToCompress = val;
|
|
||||||
if (key.CompareTo("devenv")==0)
|
|
||||||
m_DevenvPath = val;
|
|
||||||
if (key.CompareTo("output")==0)
|
|
||||||
m_OutputPath = val;
|
|
||||||
if (key.CompareTo("source")==0)
|
|
||||||
m_SourceTree = val;
|
|
||||||
if (key.CompareTo("release")==0)
|
|
||||||
m_ReleaseName = val;
|
|
||||||
if (key.CompareTo("makeopts")==0)
|
|
||||||
m_MakeOpts = val;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return true;
|
|
||||||
} catch {
|
|
||||||
Console.WriteLine("Unable to read file: " + file);
|
|
||||||
}
|
|
||||||
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,165 +0,0 @@
|
|||||||
using System;
|
|
||||||
using System.IO;
|
|
||||||
|
|
||||||
namespace AMXXRelease
|
|
||||||
{
|
|
||||||
//AMX Mod X core distribution
|
|
||||||
public class CoreMod : AMod
|
|
||||||
{
|
|
||||||
public CoreMod()
|
|
||||||
{
|
|
||||||
AddModules();
|
|
||||||
AddPlugins();
|
|
||||||
}
|
|
||||||
|
|
||||||
public override sealed string GetName()
|
|
||||||
{
|
|
||||||
return "base";
|
|
||||||
}
|
|
||||||
|
|
||||||
public override sealed string GetPluginDir()
|
|
||||||
{
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
|
|
||||||
public override sealed string GetBaseName()
|
|
||||||
{
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
|
|
||||||
//annoyingly complicated file exclusion filter
|
|
||||||
public override sealed bool ExcludeCopy(string file)
|
|
||||||
{
|
|
||||||
if ( ((file.IndexOf(".so")!=-1) || (ABuilder.GetFileName(file).CompareTo("amxxpc")==0))
|
|
||||||
&& (Releaser.IsWindows || Releaser.IsOSX) )
|
|
||||||
return true;
|
|
||||||
if ( ((file.IndexOf(".dylib")!=-1) || (ABuilder.GetFileName(file).CompareTo("amxxpc_osx")==0))
|
|
||||||
&& (!Releaser.IsOSX) )
|
|
||||||
return true;
|
|
||||||
if ( (file.IndexOf(".sh")!=-1) && Releaser.IsWindows )
|
|
||||||
return true;
|
|
||||||
if ( ((file.IndexOf(".exe")!=-1) || (file.IndexOf(".dll")!=-1))
|
|
||||||
&& (!Releaser.IsWindows) )
|
|
||||||
return true;
|
|
||||||
if (file.IndexOf("dlsym")!=-1)
|
|
||||||
return true;
|
|
||||||
if (ABuilder.GetFileName(file).CompareTo("svn_version.tpl") == 0)
|
|
||||||
{
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
return base.ExcludeCopy(file);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
public override sealed bool CopyExtraFiles(ABuilder ab, string basedir, string source)
|
|
||||||
{
|
|
||||||
//Create directory structures
|
|
||||||
string datadir = basedir + "\\data";
|
|
||||||
|
|
||||||
if (!Directory.Exists(ABuilder.PropSlashes(datadir)))
|
|
||||||
ab.CreateDir(ABuilder.PropSlashes(datadir));
|
|
||||||
|
|
||||||
File.Copy(ABuilder.PropSlashes(source + "\\dlls\\geoip\\GeoIP.dat"),
|
|
||||||
ABuilder.PropSlashes(datadir + "\\GeoIP.dat"),
|
|
||||||
true);
|
|
||||||
|
|
||||||
ABuilder.CopyNormal(ab,
|
|
||||||
ABuilder.PropSlashes(source + "\\plugins\\lang"),
|
|
||||||
ABuilder.PropSlashes(datadir + "\\lang")
|
|
||||||
);
|
|
||||||
|
|
||||||
if (!Directory.Exists(ABuilder.PropSlashes(basedir + "\\logs")))
|
|
||||||
ab.CreateDir(ABuilder.PropSlashes(basedir + "\\logs"));
|
|
||||||
|
|
||||||
ABuilder.CopyNormal(ab,
|
|
||||||
ABuilder.PropSlashes(source + "\\plugins\\include"),
|
|
||||||
ABuilder.PropSlashes(basedir + "\\scripting\\include"));
|
|
||||||
|
|
||||||
ABuilder.CopyNormal(ab,
|
|
||||||
ABuilder.PropSlashes(source + "\\plugins\\include\\amxmod_compat"),
|
|
||||||
ABuilder.PropSlashes(basedir + "\\scripting\\include\\amxmod_compat"));
|
|
||||||
|
|
||||||
ABuilder.CopyNormal(ab,
|
|
||||||
ABuilder.PropSlashes(source + "\\plugins\\amxmod_compat"),
|
|
||||||
ABuilder.PropSlashes(basedir + "\\scripting\\amxmod_compat"));
|
|
||||||
|
|
||||||
ABuilder.CopyNormal(ab,
|
|
||||||
ABuilder.PropSlashes(source + "\\plugins\\testsuite"),
|
|
||||||
ABuilder.PropSlashes(basedir + "\\scripting\\testsuite"));
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
private void AddPlugins()
|
|
||||||
{
|
|
||||||
AddPlugin("admin");
|
|
||||||
|
|
||||||
Plugin admin_sql = new Plugin("admin_sql");
|
|
||||||
admin_sql.source = "admin";
|
|
||||||
admin_sql.options = "USING_SQL=1 -oadmin_sql.amx";
|
|
||||||
m_Plugins.Add(admin_sql);
|
|
||||||
|
|
||||||
Plugin bcompat = new Plugin("amxmod_compat");
|
|
||||||
bcompat.source = "amxmod_compat/amxmod_compat";
|
|
||||||
m_Plugins.Add(bcompat);
|
|
||||||
|
|
||||||
AddPlugin("adminchat");
|
|
||||||
AddPlugin("admincmd");
|
|
||||||
AddPlugin("adminhelp");
|
|
||||||
AddPlugin("adminslots");
|
|
||||||
AddPlugin("adminvote");
|
|
||||||
AddPlugin("antiflood");
|
|
||||||
AddPlugin("imessage");
|
|
||||||
AddPlugin("mapchooser");
|
|
||||||
AddPlugin("mapsmenu");
|
|
||||||
AddPlugin("menufront");
|
|
||||||
AddPlugin("multilingual");
|
|
||||||
AddPlugin("nextmap");
|
|
||||||
AddPlugin("pausecfg");
|
|
||||||
AddPlugin("plmenu");
|
|
||||||
AddPlugin("scrollmsg");
|
|
||||||
AddPlugin("statscfg");
|
|
||||||
AddPlugin("telemenu");
|
|
||||||
AddPlugin("timeleft");
|
|
||||||
AddPlugin("cmdmenu");
|
|
||||||
AddPlugin("pluginmenu");
|
|
||||||
}
|
|
||||||
|
|
||||||
private void AddModules()
|
|
||||||
{
|
|
||||||
Module core = new Module();
|
|
||||||
|
|
||||||
core.sourcedir = "amxmodx";
|
|
||||||
core.vcproj = "amxmodx_mm";
|
|
||||||
core.build = "JITRelease";
|
|
||||||
core.projname = "amxmodx_mm";
|
|
||||||
core.outdir = "dlls";
|
|
||||||
|
|
||||||
Module mysqlx = new Module("mysqlx");
|
|
||||||
mysqlx.projname = "mysql_amxx";
|
|
||||||
|
|
||||||
Module sqlitex = new Module("sqlite");
|
|
||||||
Module engine = new Module("engine");
|
|
||||||
Module fun = new Module("fun");
|
|
||||||
Module geoip = new Module("geoip");
|
|
||||||
Module fakemeta = new Module("fakemeta");
|
|
||||||
Module sockets = new Module("sockets");
|
|
||||||
Module regex = new Module("regex");
|
|
||||||
Module nvault = new Module("nvault");
|
|
||||||
Module sammich = new Module("hamsandwich");
|
|
||||||
|
|
||||||
m_Modules.Add(core);
|
|
||||||
m_Modules.Add(mysqlx);
|
|
||||||
m_Modules.Add(engine);
|
|
||||||
m_Modules.Add(fun);
|
|
||||||
m_Modules.Add(geoip);
|
|
||||||
m_Modules.Add(fakemeta);
|
|
||||||
m_Modules.Add(sockets);
|
|
||||||
m_Modules.Add(regex);
|
|
||||||
m_Modules.Add(nvault);
|
|
||||||
m_Modules.Add(sqlitex);
|
|
||||||
m_Modules.Add(sammich);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
@ -1,131 +0,0 @@
|
|||||||
using System;
|
|
||||||
using System.Diagnostics;
|
|
||||||
using System.IO;
|
|
||||||
|
|
||||||
namespace AMXXRelease
|
|
||||||
{
|
|
||||||
//Build process for any Linux
|
|
||||||
public class LinuxBuilder : ABuilder
|
|
||||||
{
|
|
||||||
private string m_AmxxPc;
|
|
||||||
|
|
||||||
public override void OnBuild()
|
|
||||||
{
|
|
||||||
m_AmxxPc = PropSlashes(m_Cfg.GetSourceTree() + "/plugins/amxxpc");
|
|
||||||
}
|
|
||||||
|
|
||||||
public override void CompressDir(string target, string dir)
|
|
||||||
{
|
|
||||||
ProcessStartInfo info = new ProcessStartInfo();
|
|
||||||
|
|
||||||
info.FileName = m_Cfg.CompressPath();
|
|
||||||
info.WorkingDirectory = dir;
|
|
||||||
|
|
||||||
string [] files = Directory.GetFiles(dir);
|
|
||||||
string file_list = "";
|
|
||||||
for (int i=0; i<files.Length; i++)
|
|
||||||
file_list += GetFileName(files[i]) + " ";
|
|
||||||
files = Directory.GetDirectories(dir);
|
|
||||||
for (int i=0; i<files.Length; i++)
|
|
||||||
file_list += GetFileName(files[i]) + " ";
|
|
||||||
|
|
||||||
ProcessStartInfo chmod = new ProcessStartInfo();
|
|
||||||
chmod.FileName = "/bin/chmod";
|
|
||||||
chmod.WorkingDirectory = dir;
|
|
||||||
chmod.Arguments = "-R 755 " + file_list;
|
|
||||||
chmod.UseShellExecute = false;
|
|
||||||
Process c = Process.Start(chmod);
|
|
||||||
c.WaitForExit();
|
|
||||||
c.Close();
|
|
||||||
|
|
||||||
|
|
||||||
info.Arguments = "zcvf \"" + target + "-linux.tar.gz\" " + file_list;
|
|
||||||
info.UseShellExecute = false;
|
|
||||||
|
|
||||||
Process p = Process.Start(info);
|
|
||||||
p.WaitForExit();
|
|
||||||
p.Close();
|
|
||||||
}
|
|
||||||
|
|
||||||
public override void AmxxPc(string inpath, string args)
|
|
||||||
{
|
|
||||||
ProcessStartInfo info = new ProcessStartInfo();
|
|
||||||
|
|
||||||
info.WorkingDirectory = PropSlashes(m_Cfg.GetSourceTree() + "\\plugins");
|
|
||||||
info.FileName = (string)m_AmxxPc.Clone();
|
|
||||||
info.Arguments = inpath + ".sma";
|
|
||||||
if (args != null)
|
|
||||||
info.Arguments += " " + args;
|
|
||||||
info.UseShellExecute = false;
|
|
||||||
|
|
||||||
Process p = Process.Start(info);
|
|
||||||
p.WaitForExit();
|
|
||||||
p.Close();
|
|
||||||
}
|
|
||||||
|
|
||||||
public override string GetLibExt()
|
|
||||||
{
|
|
||||||
return "_i386.so";
|
|
||||||
}
|
|
||||||
|
|
||||||
public override string BuildModule(Module module)
|
|
||||||
{
|
|
||||||
ProcessStartInfo info = new ProcessStartInfo();
|
|
||||||
|
|
||||||
string dir = m_Cfg.GetSourceTree() + "\\" + module.sourcedir;
|
|
||||||
string file = dir;
|
|
||||||
file += "\\" + "Release" + "\\" + module.projname + GetLibExt();
|
|
||||||
file = PropSlashes(file);
|
|
||||||
|
|
||||||
if (File.Exists(file))
|
|
||||||
File.Delete(file);
|
|
||||||
|
|
||||||
Console.WriteLine(PropSlashes(dir));
|
|
||||||
info.WorkingDirectory = PropSlashes(dir);
|
|
||||||
info.FileName = m_Cfg.DevenvPath();
|
|
||||||
info.Arguments = "clean";
|
|
||||||
info.UseShellExecute = false;
|
|
||||||
|
|
||||||
Process p = Process.Start(info);
|
|
||||||
p.WaitForExit();
|
|
||||||
p.Close();
|
|
||||||
|
|
||||||
info.WorkingDirectory = PropSlashes(dir);
|
|
||||||
info.FileName = m_Cfg.DevenvPath();
|
|
||||||
info.Arguments = m_Cfg.MakeOpts();
|
|
||||||
info.UseShellExecute = false;
|
|
||||||
|
|
||||||
p = Process.Start(info);
|
|
||||||
p.WaitForExit();
|
|
||||||
p.Close();
|
|
||||||
|
|
||||||
if (!File.Exists(file))
|
|
||||||
{
|
|
||||||
Console.WriteLine("Output file failed: " + file);
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
|
|
||||||
//Now we need to see if the DL handle is valid!
|
|
||||||
string dlsym_dir = m_Cfg.GetSourceTree() + "\\plugins";
|
|
||||||
string dlsym = dlsym_dir + "\\dlsym";
|
|
||||||
dlsym = PropSlashes(dlsym);
|
|
||||||
dlsym_dir = PropSlashes(dlsym_dir);
|
|
||||||
info.WorkingDirectory = dlsym_dir;
|
|
||||||
info.FileName = dlsym;
|
|
||||||
info.Arguments = file;
|
|
||||||
info.UseShellExecute = false;
|
|
||||||
info.RedirectStandardOutput = true;
|
|
||||||
|
|
||||||
p = Process.Start(info);
|
|
||||||
string output = p.StandardOutput.ReadToEnd();
|
|
||||||
p.WaitForExit();
|
|
||||||
p.Close();
|
|
||||||
|
|
||||||
if (output.IndexOf("Handle:") == -1)
|
|
||||||
return null;
|
|
||||||
|
|
||||||
return file;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
@ -1,111 +0,0 @@
|
|||||||
using System;
|
|
||||||
using System.Diagnostics;
|
|
||||||
using System.IO;
|
|
||||||
|
|
||||||
namespace AMXXRelease
|
|
||||||
{
|
|
||||||
//Build process for Mac OS X
|
|
||||||
public class MacBuilder : ABuilder
|
|
||||||
{
|
|
||||||
private string m_AmxxPc;
|
|
||||||
|
|
||||||
public override void OnBuild()
|
|
||||||
{
|
|
||||||
m_AmxxPc = PropSlashes(m_Cfg.GetSourceTree() + "/plugins/amxxpc_osx");
|
|
||||||
}
|
|
||||||
|
|
||||||
public override void CompressDir(string target, string dir)
|
|
||||||
{
|
|
||||||
ProcessStartInfo info = new ProcessStartInfo();
|
|
||||||
|
|
||||||
info.FileName = m_Cfg.CompressPath();
|
|
||||||
info.WorkingDirectory = dir;
|
|
||||||
|
|
||||||
string [] files = Directory.GetFiles(dir);
|
|
||||||
string file_list = "";
|
|
||||||
for (int i=0; i<files.Length; i++)
|
|
||||||
file_list += GetFileName(files[i]) + " ";
|
|
||||||
files = Directory.GetDirectories(dir);
|
|
||||||
for (int i=0; i<files.Length; i++)
|
|
||||||
file_list += GetFileName(files[i]) + " ";
|
|
||||||
|
|
||||||
ProcessStartInfo chmod = new ProcessStartInfo();
|
|
||||||
chmod.FileName = "/bin/chmod";
|
|
||||||
chmod.WorkingDirectory = dir;
|
|
||||||
chmod.Arguments = "-R 755 " + file_list;
|
|
||||||
chmod.UseShellExecute = false;
|
|
||||||
Process c = Process.Start(chmod);
|
|
||||||
c.WaitForExit();
|
|
||||||
c.Close();
|
|
||||||
|
|
||||||
info.Arguments = "-r \"" + target + "-mac.zip\" " + ".";
|
|
||||||
info.UseShellExecute = false;
|
|
||||||
|
|
||||||
Process p = Process.Start(info);
|
|
||||||
p.WaitForExit();
|
|
||||||
p.Close();
|
|
||||||
}
|
|
||||||
|
|
||||||
public override void AmxxPc(string inpath, string args)
|
|
||||||
{
|
|
||||||
ProcessStartInfo info = new ProcessStartInfo();
|
|
||||||
|
|
||||||
info.WorkingDirectory = PropSlashes(m_Cfg.GetSourceTree() + "\\plugins");
|
|
||||||
info.FileName = (string)m_AmxxPc.Clone();
|
|
||||||
info.Arguments = inpath + ".sma";
|
|
||||||
if (args != null)
|
|
||||||
info.Arguments += " " + args;
|
|
||||||
info.UseShellExecute = false;
|
|
||||||
|
|
||||||
Process p = Process.Start(info);
|
|
||||||
p.WaitForExit();
|
|
||||||
p.Close();
|
|
||||||
}
|
|
||||||
|
|
||||||
public override string GetLibExt()
|
|
||||||
{
|
|
||||||
return ".dylib";
|
|
||||||
}
|
|
||||||
|
|
||||||
public override string BuildModule(Module module)
|
|
||||||
{
|
|
||||||
ProcessStartInfo info = new ProcessStartInfo();
|
|
||||||
|
|
||||||
string dir = m_Cfg.GetSourceTree() + "\\" + module.sourcedir;
|
|
||||||
string file = dir;
|
|
||||||
file += "\\" + "Release" + "\\" + module.projname + GetLibExt();
|
|
||||||
file = PropSlashes(file);
|
|
||||||
|
|
||||||
if (File.Exists(file))
|
|
||||||
File.Delete(file);
|
|
||||||
|
|
||||||
Console.WriteLine(PropSlashes(dir));
|
|
||||||
info.WorkingDirectory = PropSlashes(dir);
|
|
||||||
info.FileName = m_Cfg.DevenvPath();
|
|
||||||
info.Arguments = "clean";
|
|
||||||
info.UseShellExecute = false;
|
|
||||||
|
|
||||||
Process p = Process.Start(info);
|
|
||||||
p.WaitForExit();
|
|
||||||
p.Close();
|
|
||||||
|
|
||||||
info.WorkingDirectory = PropSlashes(dir);
|
|
||||||
info.FileName = m_Cfg.DevenvPath();
|
|
||||||
info.Arguments = m_Cfg.MakeOpts();
|
|
||||||
info.UseShellExecute = false;
|
|
||||||
|
|
||||||
p = Process.Start(info);
|
|
||||||
p.WaitForExit();
|
|
||||||
p.Close();
|
|
||||||
|
|
||||||
if (!File.Exists(file))
|
|
||||||
{
|
|
||||||
Console.WriteLine("Output file failed: " + file);
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
|
|
||||||
return file;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user