mirror of
https://github.com/godotengine/godot-cpp.git
synced 2026-01-03 18:09:13 +03:00
[SCons] Add option to build without threads
This is relevant for the Web platform, where builds with and without
threads are incompatible.
(cherry picked from commit b0296bb562)
This commit is contained in:
committed by
David Snopek
parent
1f9a0b7171
commit
aeb8be98ed
@@ -34,8 +34,9 @@ def generate(env):
|
||||
env["SHLIBSUFFIX"] = ".wasm"
|
||||
|
||||
# Thread support (via SharedArrayBuffer).
|
||||
env.Append(CCFLAGS=["-s", "USE_PTHREADS=1"])
|
||||
env.Append(LINKFLAGS=["-s", "USE_PTHREADS=1"])
|
||||
if env["threads"]:
|
||||
env.Append(CCFLAGS=["-s", "USE_PTHREADS=1"])
|
||||
env.Append(LINKFLAGS=["-s", "USE_PTHREADS=1"])
|
||||
|
||||
# Build as side module (shared library).
|
||||
env.Append(CPPFLAGS=["-s", "SIDE_MODULE=1"])
|
||||
|
||||
Reference in New Issue
Block a user