mirror of
https://github.com/wesnoth/wesnoth
synced 2025-05-21 18:12:31 +00:00
scons: Added an option to support using multilib gcc in 32-bit mode
multilib_arch=32 will pass -m32 to both compiler and linker causing multilib gcc to produce 32bit binaries.
This commit is contained in:
parent
3fd592c2e2
commit
e9eb8d316f
@ -97,6 +97,7 @@ opts.AddVariables(
|
||||
PathVariable('gtkdir', 'Directory where GTK SDK is installed.', "", OptionalPath),
|
||||
PathVariable('luadir', 'Directory where Lua binary package is unpacked.', "", OptionalPath),
|
||||
('host', 'Cross-compile host.', ''),
|
||||
EnumVariable('multilib_arch', 'Address model for multilib compiler: 32-bit or 64-bit', "", ["", "32", "64"]),
|
||||
('jobs', 'Set the number of parallel compilations', "1", lambda key, value, env: int(value), int),
|
||||
BoolVariable('distcc', 'Use distcc', False),
|
||||
BoolVariable('ccache', "Use ccache", False),
|
||||
@ -304,6 +305,10 @@ configure_args = dict(
|
||||
|
||||
env.MergeFlags(env["extra_flags_config"])
|
||||
|
||||
if env["multilib_arch"]:
|
||||
multilib_flag = "-m" + env["multilib_arch"]
|
||||
env.AppendUnique(CCFLAGS = [multilib_flag], LINKFLAGS = [multilib_flag])
|
||||
|
||||
# Some tests need to load parts of boost
|
||||
env.PrependENVPath('LD_LIBRARY_PATH', env["boostlibdir"])
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user