summaryrefslogtreecommitdiffstats
path: root/platform/javascript/detect.py
diff options
context:
space:
mode:
authorAaron Franke <arnfranke@yahoo.com>2021-12-15 17:38:10 -0800
committerRémi Verschelde <rverschelde@gmail.com>2022-08-25 11:19:20 +0200
commit27b0f182758db5d2d4c123c81430c34941161b39 (patch)
tree1182408f0be3567400ff08ace5b4d48b40815641 /platform/javascript/detect.py
parent8916949b5051080e48d21e986eb5d77de67a882d (diff)
downloadredot-engine-27b0f182758db5d2d4c123c81430c34941161b39.tar.gz
Unify bits, arch, and android_arch into env["arch"]
Fully removes the `bits` option and adapts the code that relied on it. Co-authored-by: Rémi Verschelde <rverschelde@gmail.com>
Diffstat (limited to 'platform/javascript/detect.py')
-rw-r--r--platform/javascript/detect.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/platform/javascript/detect.py b/platform/javascript/detect.py
index a769260f01..048c9c2eb4 100644
--- a/platform/javascript/detect.py
+++ b/platform/javascript/detect.py
@@ -46,6 +46,7 @@ def get_opts():
def get_flags():
return [
+ ("arch", "wasm32"),
("tools", False),
("builtin_pcre2_with_jit", False),
("vulkan", False),
@@ -53,6 +54,15 @@ def get_flags():
def configure(env):
+ # Validate arch.
+ supported_arches = ["wasm32"]
+ if env["arch"] not in supported_arches:
+ print(
+ 'Unsupported CPU architecture "%s" for iOS. Supported architectures are: %s.'
+ % (env["arch"], ", ".join(supported_arches))
+ )
+ sys.exit()
+
try:
env["initial_memory"] = int(env["initial_memory"])
except Exception: