-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
11 changed files
with
1,900 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
#! /usr/bin/env python | ||
# encoding: utf-8 | ||
# a1batross, mittorn, 2018 | ||
|
||
from waflib import Utils | ||
import os | ||
|
||
def options(opt): | ||
pass | ||
|
||
def configure(conf): | ||
if conf.env.DEST_OS != 'win32': | ||
conf.check(lib='dl') | ||
|
||
def build(bld): | ||
libs = ['DL'] | ||
defines = ['CLIENT_DLL'] | ||
includes = ['.', | ||
'../dlls', | ||
'../common', | ||
'../engine', | ||
'../pm_shared', | ||
'../game_shared', | ||
'../public'] | ||
|
||
source = bld.path.ant_glob('**/*.cpp') | ||
source += bld.path.parent.ant_glob('game_shared/*.cpp') | ||
source += bld.path.parent.ant_glob('pm_shared/*.c') | ||
|
||
if bld.env.DEST_OS not in ['android', 'dos']: | ||
install_path = os.path.join(bld.env.GAMEDIR, bld.env.CLIENT_INSTALL_DIR) | ||
else: | ||
install_path = bld.env.PREFIX | ||
|
||
bld.shlib( | ||
source = source, | ||
target = 'client' + bld.env.POSTFIX, | ||
name = 'client', | ||
features = 'c cxx', | ||
includes = includes, | ||
defines = defines, | ||
use = libs, | ||
install_path = install_path, | ||
subsystem = bld.env.MSVC_SUBSYSTEM, | ||
idx = bld.get_taskgen_count() | ||
) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,53 @@ | ||
#! /usr/bin/env python | ||
# encoding: utf-8 | ||
# a1batross, mittorn, 2018 | ||
|
||
from waflib import Utils | ||
import os | ||
|
||
def options(opt): | ||
return | ||
|
||
def configure(conf): | ||
if conf.env.COMPILER_CC == 'msvc': | ||
# progs.def removes MSVC function name decoration from GiveFnptrsToDll on Windows. | ||
# Without this, the lookup for this function fails. | ||
hlDefNode = conf.path.find_resource("./progs.def") | ||
|
||
if hlDefNode is not None: | ||
conf.env.append_value('LINKFLAGS', '/def:%s' % hlDefNode.abspath()) | ||
else: | ||
conf.fatal("Could not find progs.def") | ||
|
||
def build(bld): | ||
source = bld.path.ant_glob('**/*.cpp') | ||
source += bld.path.parent.ant_glob('pm_shared/*.c') | ||
source += bld.path.parent.ant_glob('game_shared/*.cpp') | ||
|
||
includes = [ | ||
'.', | ||
'../common', | ||
'../engine', | ||
'../pm_shared', | ||
'../game_shared', | ||
'../public' | ||
] | ||
defines = [] | ||
|
||
if bld.env.DEST_OS not in ['android', 'dos']: | ||
install_path = os.path.join(bld.env.GAMEDIR, bld.env.SERVER_INSTALL_DIR) | ||
else: | ||
install_path = bld.env.PREFIX | ||
|
||
bld.shlib( | ||
source = source, | ||
target = bld.env.SERVER_LIBRARY_NAME + bld.env.POSTFIX, | ||
name = 'server', | ||
features = 'c cxx', | ||
includes = includes, | ||
defines = defines, | ||
install_path = install_path, | ||
subsystem = bld.env.MSVC_SUBSYSTEM, | ||
idx = bld.get_taskgen_count() | ||
) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
#! /usr/bin/env python | ||
# encoding: utf-8 | ||
# a1batross, mittorn, 2018 | ||
|
||
from waflib import Utils | ||
import os | ||
|
||
def options(opt): | ||
return | ||
|
||
def configure(conf): | ||
return | ||
|
||
def build(bld): | ||
source = bld.path.ant_glob('**/*.cpp') | ||
|
||
includes = [ | ||
'.', | ||
'../common', | ||
'../engine', | ||
'../pm_shared', | ||
'../game_shared', | ||
'../public', | ||
'../dlls' | ||
] | ||
defines = [] | ||
|
||
if bld.env.DEST_OS not in ['android', 'dos']: | ||
install_path = os.path.join(bld.env.GAMEDIR, bld.env.SERVER_INSTALL_DIR) | ||
else: | ||
install_path = bld.env.PREFIX | ||
|
||
bld.shlib( | ||
source = source, | ||
target = 'menu' + bld.env.POSTFIX, | ||
name = 'menu', | ||
features = 'c cxx', | ||
includes = includes, | ||
defines = defines, | ||
install_path = install_path, | ||
subsystem = bld.env.MSVC_SUBSYSTEM, | ||
idx = bld.get_taskgen_count() | ||
) | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
GAMEDIR=ID1 # Gamedir path | ||
SERVER_INSTALL_DIR=bin # Where put server dll | ||
CLIENT_INSTALL_DIR=bin # Where put client dll | ||
SERVER_LIBRARY_NAME=progs # Library name for PC platforms |
Oops, something went wrong.