summaryrefslogtreecommitdiffstats
path: root/platform
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2023-08-31 08:55:41 +0200
committerRémi Verschelde <rverschelde@gmail.com>2023-08-31 08:55:41 +0200
commit46ff9aa2ca545a66552ebb073e87395951ed166d (patch)
treef8b80922a9b7e542dd4395aebe87826070e02b89 /platform
parent98f684455400461c91641bd55533d8706b1439b4 (diff)
parentbbafe14970cf2a101b8b04dbfafeeaa9ddfb5d4d (diff)
downloadredot-engine-46ff9aa2ca545a66552ebb073e87395951ed166d.tar.gz
Merge pull request #81144 from anvilfolk/incremental-option
SCons: Add option for MSVC incremental linking.
Diffstat (limited to 'platform')
-rw-r--r--platform/windows/detect.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/platform/windows/detect.py b/platform/windows/detect.py
index 9548939695..6e56f2a525 100644
--- a/platform/windows/detect.py
+++ b/platform/windows/detect.py
@@ -185,6 +185,7 @@ def get_opts():
BoolVariable("use_static_cpp", "Link MinGW/MSVC C++ runtime libraries statically", True),
BoolVariable("use_asan", "Use address sanitizer (ASAN)", False),
BoolVariable("debug_crt", "Compile with MSVC's debug CRT (/MDd)", False),
+ BoolVariable("incremental_link", "Use MSVC incremental linking. May increase or decrease build times.", False),
]
@@ -355,8 +356,9 @@ def configure_msvc(env, vcvars_msvc_config):
else:
env.AppendUnique(CCFLAGS=["/MD"])
- # MSVC incremental linking is broken and _increases_ link time (GH-77968).
- env.Append(LINKFLAGS=["/INCREMENTAL:NO"])
+ # MSVC incremental linking is broken and may _increase_ link time (GH-77968).
+ if not env["incremental_link"]:
+ env.Append(LINKFLAGS=["/INCREMENTAL:NO"])
if env["arch"] == "x86_32":
env["x86_libtheora_opt_vc"] = True