Fixed scons configure checks for ming32 cross-compile
Removed option for ANA because it isn't used to my knowledge and was making configure checks more complex.
This commit is contained in:
parent
a16edac8c7
commit
634b0039f8
2 changed files with 10 additions and 23 deletions
21
SConstruct
21
SConstruct
|
@ -82,7 +82,6 @@ opts.AddVariables(
|
|||
('version_suffix', 'suffix that will be added to default values of prefsdir, program_suffix and datadirname', ""),
|
||||
BoolVariable('raw_sockets', 'Set to use raw receiving sockets in the multiplayer network layer rather than the SDL_net facilities', False),
|
||||
BoolVariable('forum_user_handler', 'Enable forum user handler in wesnothd', False),
|
||||
BoolVariable('use_network_ana', 'Use the new network api', False),
|
||||
('server_gid', 'group id of the user who runs wesnothd', ""),
|
||||
('server_uid', 'user id of the user who runs wesnothd', ""),
|
||||
BoolVariable('strict', 'Set to strict compilation', False),
|
||||
|
@ -284,18 +283,15 @@ if env["prereqs"]:
|
|||
conf.CheckLib("m")
|
||||
conf.CheckFunc("round")
|
||||
|
||||
def CheckANA(conf, do_check):
|
||||
if not do_check:
|
||||
return True
|
||||
def CheckAsio(conf):
|
||||
if env["PLATFORM"] == 'win32':
|
||||
conf.env.Append(LIBS = ["libws2_32"])
|
||||
return conf.CheckBoost("system") and \
|
||||
conf.CheckBoost("thread")
|
||||
|
||||
def CheckAsio(conf):
|
||||
return conf.CheckLib("pthread") and \
|
||||
conf.CheckBoost("system") and \
|
||||
conf.CheckBoost("asio", header_only = True)
|
||||
have_libpthread = True
|
||||
else:
|
||||
have_libpthread = conf.CheckLib("pthread")
|
||||
return have_libpthread and \
|
||||
conf.CheckBoost("system") and \
|
||||
conf.CheckBoost("asio", header_only = True)
|
||||
|
||||
if env['host'] in ['x86_64-nacl', 'i686-nacl']:
|
||||
# libppapi_cpp has a reverse dependency on the following function
|
||||
|
@ -326,8 +322,7 @@ if env["prereqs"]:
|
|||
conf.CheckBoostIostreamsBZip2() and \
|
||||
conf.CheckBoost("smart_ptr", header_only = True) and \
|
||||
conf.CheckSDL(require_version = '1.2.7') and \
|
||||
conf.CheckSDL('SDL_net') and \
|
||||
CheckANA(conf, env["use_network_ana"]) or Warning("Base prerequisites are not met.")
|
||||
conf.CheckSDL('SDL_net') or Warning("Base prerequisites are not met.")
|
||||
|
||||
env = conf.Finish()
|
||||
client_env = env.Clone()
|
||||
|
|
|
@ -22,6 +22,7 @@ libwesnoth_core_sources = Split("""
|
|||
map.cpp
|
||||
map_location.cpp
|
||||
md5.cpp
|
||||
network.cpp
|
||||
thread.cpp
|
||||
tstring.cpp
|
||||
util.cpp
|
||||
|
@ -38,15 +39,6 @@ libwesnoth_core_sources = Split("""
|
|||
|
||||
libwesnoth_core_sources.extend(env.Object("network_worker.cpp", EXTRA_DEFINE = env['raw_sockets'] and "NETWORK_USE_RAW_SOCKETS" or None))
|
||||
|
||||
if env["use_network_ana"]:
|
||||
client_env.Append(CPPPATH = ["#/src/ana/api"])
|
||||
libwesnoth_core_sources.append("network_ana.cpp")
|
||||
libwesnoth_core_sources.append("network_manager_ana.cpp")
|
||||
ana = SConscript("ana/src/SConscript", exports = {"env" : client_env})
|
||||
else:
|
||||
libwesnoth_core_sources.append("network.cpp")
|
||||
ana = []
|
||||
|
||||
game_config_env = env.Clone()
|
||||
filesystem_env = env.Clone()
|
||||
if env["PLATFORM"] != "win32":
|
||||
|
@ -73,7 +65,7 @@ libwesnoth_core_sources.extend([
|
|||
filesystem_env.Object("filesystem.cpp")
|
||||
])
|
||||
|
||||
libwesnoth_core = [env.Library("wesnoth_core", libwesnoth_core_sources), ana]
|
||||
libwesnoth_core = [env.Library("wesnoth_core", libwesnoth_core_sources)]
|
||||
|
||||
libwesnoth_sources = Split("""
|
||||
arrow.cpp
|
||||
|
|
Loading…
Add table
Reference in a new issue