Add lto scons option, defaulting to "none".

(cherry picked from commit 5f7cf05043)
This commit is contained in:
Lukas Tenbrink
2024-09-21 12:52:50 +02:00
committed by David Snopek
parent d5bdde9509
commit 06fbf3ce95
8 changed files with 69 additions and 0 deletions

View File

@@ -97,4 +97,9 @@ def generate(env):
env.Append(CPPDEFINES=["IOS_ENABLED", "UNIX_ENABLED"])
# Refer to https://github.com/godotengine/godot/blob/master/platform/ios/detect.py:
# Disable by default as it makes linking in Xcode very slow.
if env["lto"] == "auto":
env["lto"] = "none"
common_compiler_flags.generate(env)