Skip to content

Commit

Permalink
Add compiler flags for windows
Browse files Browse the repository at this point in the history
This adds MSVC compiler flags to enable the DEBUG/NDEBUG defines, enable exceptions, turn on optimizations for Release builds, and link to the correct runtime library
  • Loading branch information
RichyHBM authored Jul 30, 2017
1 parent e580686 commit 2d54c15
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,10 @@ if platform == "linux":
env.Append(CPPPATH=['.', godot_headers_path, 'include', 'include/core'])

if platform == "windows":
if target == "debug":
env.Append(CCFLAGS = ['-EHsc', '-D_DEBUG', '/MDd'])
else:
env.Append(CCFLAGS = ['-O2', '-EHsc', '-DNDEBUG', '/MD'])
env.Append(LIBS=[godot_name])
env.Append(LIBPATH=[godot_lib_path])

Expand Down

0 comments on commit 2d54c15

Please sign in to comment.