Skip to content

Commit

Permalink
SCons: Disable misbehaving MSVC incremental linking
Browse files Browse the repository at this point in the history
Fixes #77968.

(cherry picked from commit bc1aef8)
  • Loading branch information
akien-mga committed Aug 28, 2023
1 parent 8e5c177 commit 10af8ad
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions platform/windows/detect.py
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,9 @@ def configure_msvc(env, manual_msvc_config):
else:
env.AppendUnique(CCFLAGS=["/MD"])

# MSVC incremental linking is broken and _increases_ link time (GH-77968).
env.Append(LINKFLAGS=["/INCREMENTAL:NO"])

env.AppendUnique(CCFLAGS=["/Gd", "/GR", "/nologo"])
env.AppendUnique(CCFLAGS=["/utf-8"]) # Force to use Unicode encoding.
env.AppendUnique(CXXFLAGS=["/TP"]) # assume all sources are C++
Expand Down

0 comments on commit 10af8ad

Please sign in to comment.