Buildsystem: Windows cross-compilation on Linux defaults to 64-bit

This commit is contained in:
Rémi Verschelde 2017-09-13 22:36:15 +02:00
parent cc30e2a9a5
commit f48a1c9ebf
1 changed files with 6 additions and 3 deletions

View File

@ -226,10 +226,13 @@ def configure(env):
else:
env["PROGSUFFIX"] = env["PROGSUFFIX"] + ".exe" # for linux cross-compilation
mingw_prefix = ""
if (env["bits"] == "default"):
env["bits"] = "64" if "PROGRAMFILES(X86)" in os.environ else "32"
if (os.name == "nt"):
env["bits"] = "64" if "PROGRAMFILES(X86)" in os.environ else "32"
else: # default to 64-bit on Linux
env["bits"] = "64"
mingw_prefix = ""
if (env["bits"] == "32"):
env.Append(LINKFLAGS=['-static'])