Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add release_debug target #98

Open
wants to merge 2 commits into
base: Godot-3.x
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions SConstruct
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ opts = Variables(customs, ARGUMENTS)
env = DefaultEnvironment()

# Define our parameters
opts.Add(EnumVariable('target', "Compilation target", 'release', ['d', 'debug', 'r', 'release']))
opts.Add(EnumVariable('target', "Compilation target", 'release', ['d', 'debug', 'r', 'release', 'release_debug']))
opts.Add(EnumVariable('platform', "Compilation platform", 'windows', ['windows', 'x11', 'linux', 'osx']))
opts.AddVariables(
PathVariable('openvr_path', 'The path where the OpenVR repo is located.', 'openvr/'),
Expand Down Expand Up @@ -51,7 +51,11 @@ if env['platform'] == 'windows':

env.Append(CCFLAGS = ['-DWIN32', '-D_WIN32', '-D_WINDOWS', '-W3', '-GR', '-D_CRT_SECURE_NO_WARNINGS'])
if env['target'] in ('debug', 'd'):
env.Append(CCFLAGS = ['-EHsc', '-D_DEBUG', '-MDd'])
env.Append(CCFLAGS = ['-EHsc', '-D_DEBUG', '-MDd', '-Zi', '-FS'])
env.Append(LINKFLAGS = ['-DEBUG:FULL'])
elif env['target'] in ('release_debug',):
env.Append(CCFLAGS = ['-O2', '-EHsc', '-DNDEBUG', '-MD', '-Zi', '-FS'])
env.Append(LINKFLAGS = ['-DEBUG:FULL'])
else:
env.Append(CCFLAGS = ['-O2', '-EHsc', '-DNDEBUG', '-MD'])
# untested
Expand Down