summaryrefslogtreecommitdiff
path: root/platform/ios
diff options
context:
space:
mode:
Diffstat (limited to 'platform/ios')
-rw-r--r--platform/ios/detect.py29
1 files changed, 5 insertions, 24 deletions
diff --git a/platform/ios/detect.py b/platform/ios/detect.py
index 0f277d6b3a..74561e9fc5 100644
--- a/platform/ios/detect.py
+++ b/platform/ios/detect.py
@@ -37,7 +37,7 @@ def get_opts():
def get_flags():
return [
("arch", "arm64"), # Default for convenience.
- ("tools", False),
+ ("target", "template_debug"),
("use_volk", False),
]
@@ -52,23 +52,6 @@ def configure(env):
)
sys.exit()
- ## Build type
-
- if env["target"].startswith("release"):
- env.Append(CPPDEFINES=[("NS_BLOCK_ASSERTIONS", 1)])
- if env["optimize"] == "speed": # optimize for speed (default)
- # `-O2` is more friendly to debuggers than `-O3`, leading to better crash backtraces
- # when using `target=release_debug`.
- opt = "-O3" if env["target"] == "release" else "-O2"
- env.Append(CCFLAGS=[opt])
- env.Append(LINKFLAGS=[opt])
- elif env["optimize"] == "size": # optimize for size
- env.Append(CCFLAGS=["-Os"])
- env.Append(LINKFLAGS=["-Os"])
-
- elif env["target"] == "debug":
- env.Append(CCFLAGS=["-g", "-O0"])
-
## LTO
if env["lto"] == "auto": # Disable by default as it makes linking in Xcode very slow.
@@ -145,12 +128,10 @@ def configure(env):
env.Append(ASFLAGS=["-arch", "arm64"])
env.Append(CPPDEFINES=["NEED_LONG_INT"])
- # Disable exceptions on non-tools (template) builds
- if not env["tools"]:
- if env["ios_exceptions"]:
- env.Append(CCFLAGS=["-fexceptions"])
- else:
- env.Append(CCFLAGS=["-fno-exceptions"])
+ if env["ios_exceptions"]:
+ env.Append(CCFLAGS=["-fexceptions"])
+ else:
+ env.Append(CCFLAGS=["-fno-exceptions"])
# Temp fix for ABS/MAX/MIN macros in iOS SDK blocking compilation
env.Append(CCFLAGS=["-Wno-ambiguous-macro"])