Skip to content

Commit

Permalink
prevent anti-virus false positives by changing compile options to mor…
Browse files Browse the repository at this point in the history
…e closely match default VS 2015 options
  • Loading branch information
jacob1 committed Jan 21, 2017
1 parent 1febafd commit 9445c24
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions SConscript
Expand Up @@ -402,10 +402,9 @@ if not msvc:
if platform == "Windows":
env.Append(CPPDEFINES=["WIN", "_WIN32_WINNT=0x0501", "_USING_V110_SDK71_"])
if msvc:
env.Append(CCFLAGS=['/Gm', '/Zi', '/EHsc', '/FS']) #enable minimal rebuild, enable exceptions, allow -j to work in debug builds
env.Append(CCFLAGS=['/Gm', '/Zi', '/EHsc', '/FS', '/GS']) #enable minimal rebuild, ?, enable exceptions, allow -j to work in debug builds, enable security check
env.Append(LINKFLAGS=['/SUBSYSTEM:WINDOWS,"5.01"', '/OPT:REF', '/OPT:ICF'])
if GetOption('static'):
env.Append(CCFLAGS=['/GL']) #whole program optimization (linker may freeze indefinitely without this)
env.Append(LINKFLAGS=['/NODEFAULTLIB:msvcrt.lib', '/LTCG'])
elif not GetOption('debugging'):
env.Append(LINKFLAGS=['/NODEFAULTLIB:msvcrtd.lib'])
Expand Down Expand Up @@ -458,7 +457,7 @@ if GetOption('debugging'):
env.Append(CPPDEFINES=['DEBUG'])
elif GetOption('release'):
if msvc:
env.Append(CCFLAGS=['/O2', '/fp:fast'])
env.Append(CCFLAGS=['/O2', '/Oy-', '/fp:fast'])
if GetOption('static'):
env.Append(CCFLAGS=['/MT'])
else:
Expand Down

0 comments on commit 9445c24

Please sign in to comment.