diff options
author | Fabio Alessandrelli <fabio.alessandrelli@gmail.com> | 2021-11-26 12:44:51 +0100 |
---|---|---|
committer | Fabio Alessandrelli <fabio.alessandrelli@gmail.com> | 2021-11-26 12:44:51 +0100 |
commit | eaedc92c61abf2958529833f640ef26d219d2274 (patch) | |
tree | b2e6682ccf0c07c64de42ea2184fb2278fc58c78 | |
parent | 1b9fb5c96936a141887b827cf0dfe850d4b04707 (diff) |
[HTML5] Use absolute path for JS lib/pre/externs.
Ensure better compatibility when emcc which may run some tools from
different paths (e.g. closure compiler).
This fixes externs include issues with modern emcc using the closure
compiler.
-rw-r--r-- | platform/javascript/SCsub | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/platform/javascript/SCsub b/platform/javascript/SCsub index fa9e6eed15..8d9ba82fd4 100644 --- a/platform/javascript/SCsub +++ b/platform/javascript/SCsub @@ -28,11 +28,11 @@ if env["javascript_eval"]: sys_env.AddJSLibraries(["js/libs/library_godot_javascript_singleton.js"]) for lib in sys_env["JS_LIBS"]: - sys_env.Append(LINKFLAGS=["--js-library", lib]) + sys_env.Append(LINKFLAGS=["--js-library", lib.abspath]) for js in env["JS_PRE"]: - sys_env.Append(LINKFLAGS=["--pre-js", env.File(js).path]) + sys_env.Append(LINKFLAGS=["--pre-js", js.abspath]) for ext in env["JS_EXTERNS"]: - sys_env["ENV"]["EMCC_CLOSURE_ARGS"] += " --externs " + ext.path + sys_env["ENV"]["EMCC_CLOSURE_ARGS"] += " --externs " + ext.abspath build = [] if env["gdnative_enabled"]: |