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 d0d2680 commit b92b391
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 @@ -214,6 +214,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 b92b391

Please sign in to comment.