diff options
Diffstat (limited to 'platform/ios')
-rw-r--r-- | platform/ios/detect.py | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/platform/ios/detect.py b/platform/ios/detect.py index ed7e714c4e..d5e6ee4b46 100644 --- a/platform/ios/detect.py +++ b/platform/ios/detect.py @@ -39,9 +39,6 @@ def get_flags(): ("arch", "arm64"), # Default for convenience. ("tools", False), ("use_volk", False), - # Disable by default even if production is set, as it makes linking in Xcode - # on exports very slow and that's not what most users expect. - ("lto", "none"), ] @@ -73,7 +70,11 @@ def configure(env): env.Append(CCFLAGS=["-gdwarf-2", "-O0"]) env.Append(CPPDEFINES=["_DEBUG", ("DEBUG", 1)]) - # LTO + ## LTO + + if env["lto"] == "auto": # Disable by default as it makes linking in Xcode very slow. + env["lto"] = "none" + if env["lto"] != "none": if env["lto"] == "thin": env.Append(CCFLAGS=["-flto=thin"]) |