diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2021-09-28 16:32:13 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-09-28 16:32:13 +0200 |
commit | 96766516ec9c75bb202a23dd632cdb4f0dde04dd (patch) | |
tree | 52b8c1de178f2e28170448658a975f4a222a26b4 /methods.py | |
parent | 483b8a598eaaf114bba9fabb2037e01cce9f6523 (diff) | |
parent | b197fc20796494fca03162fd2735821a3bd5bc86 (diff) |
Merge pull request #53166 from JFonS/force_embree_opt
Diffstat (limited to 'methods.py')
-rw-r--r-- | methods.py | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/methods.py b/methods.py index 50b413a0e6..0e71adb40d 100644 --- a/methods.py +++ b/methods.py @@ -56,6 +56,17 @@ def disable_warnings(self): self.Append(CXXFLAGS=["-w"]) +def force_optimization_on_debug(self): + # 'self' is the environment + if self["target"] != "debug": + return + + if self.msvc: + self.Append(CCFLAGS=["/O2"]) + else: + self.Append(CCFLAGS=["-O3"]) + + def add_module_version_string(self, s): self.module_version_string += "." + s |