summaryrefslogtreecommitdiffstats
path: root/platform/windows/detect.py
diff options
context:
space:
mode:
authorRémi Verschelde <rverschelde@gmail.com>2017-09-21 10:30:17 +0200
committerGitHub <noreply@github.com>2017-09-21 10:30:17 +0200
commite8a0c5da77bc9d8a1944f5f368d7c414a6c0624a (patch)
tree6016cfaeb25589e4a43035aa812a6062eff421ac /platform/windows/detect.py
parent34c4c8046cb0d74878af879a9737d6878a75a464 (diff)
parent88be952fc9021df7e10adc49211e5024d200a665 (diff)
downloadredot-engine-e8a0c5da77bc9d8a1944f5f368d7c414a6c0624a.tar.gz
Merge pull request #11243 from hpvb/add-debug-info-on-release
Create separate debug info files by default
Diffstat (limited to 'platform/windows/detect.py')
-rw-r--r--platform/windows/detect.py12
1 files changed, 11 insertions, 1 deletions
diff --git a/platform/windows/detect.py b/platform/windows/detect.py
index 5bd9a78f49..65eb51a2f3 100644
--- a/platform/windows/detect.py
+++ b/platform/windows/detect.py
@@ -64,6 +64,7 @@ def get_opts():
return [
('mingw_prefix_32', 'MinGW prefix (Win32)', mingw32),
('mingw_prefix_64', 'MinGW prefix (Win64)', mingw64),
+ ('debug_symbols', 'Add debug symbols to release version (yes/no/full)', 'yes')
]
@@ -213,11 +214,20 @@ def configure(env):
env.Append(LINKFLAGS=['-Wl,--subsystem,windows'])
+ if (env["debug_symbols"] == "yes"):
+ env.Prepend(CCFLAGS=['-g1'])
+ if (env["debug_symbols"] == "full"):
+ env.Prepend(CCFLAGS=['-g2'])
+
elif (env["target"] == "release_debug"):
env.Append(CCFLAGS=['-O2', '-DDEBUG_ENABLED'])
+ if (env["debug_symbols"] == "yes"):
+ env.Prepend(CCFLAGS=['-g1'])
+ if (env["debug_symbols"] == "full"):
+ env.Prepend(CCFLAGS=['-g2'])
elif (env["target"] == "debug"):
- env.Append(CCFLAGS=['-g', '-DDEBUG_ENABLED', '-DDEBUG_MEMORY_ENABLED'])
+ env.Append(CCFLAGS=['-g3', '-DDEBUG_ENABLED', '-DDEBUG_MEMORY_ENABLED'])
## Compiler configuration