Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/sdks
diff options
context:
space:
mode:
authorZoltan Varga <vargaz@gmail.com>2020-06-23 01:55:44 +0300
committerGitHub <noreply@github.com>2020-06-23 01:55:44 +0300
commit09c44c932388ccee54c83aa99b4e6a43cdc51ed5 (patch)
treedf8c822aa621d9609085802b25f1f4346c354c14 /sdks
parentdba7d43c7e38b171a476663ba84fd15ca51cd7f0 (diff)
[wasm] Use wasm-opt --strip-dwarf instead of wasm-strip which is missing from recent emscripten versions. (#20006)
Fixes https://github.com/mono/mono/issues/20002.
Diffstat (limited to 'sdks')
-rw-r--r--sdks/wasm/packager.cs4
1 files changed, 2 insertions, 2 deletions
diff --git a/sdks/wasm/packager.cs b/sdks/wasm/packager.cs
index 2cb3507319b..ff6f68e2218 100644
--- a/sdks/wasm/packager.cs
+++ b/sdks/wasm/packager.cs
@@ -861,7 +861,7 @@ class Driver {
emcc_link_flags += "-O0 ";
string strip_cmd = "";
if (opts.NativeStrip)
- strip_cmd = " && $wasm_strip $out_wasm";
+ strip_cmd = " && $wasm_opt --strip-dwarf $out_wasm -o $out_wasm";
if (enable_simd) {
aot_args += "mattr=simd,";
emcc_flags += "-s SIMD=1 ";
@@ -902,7 +902,7 @@ class Driver {
else
ninja.WriteLine ("cross = $mono_sdkdir/wasm-cross-release/bin/wasm32-unknown-none-mono-sgen");
ninja.WriteLine ("emcc = source $emsdk_env && emcc");
- ninja.WriteLine ("wasm_strip = $emscripten_sdkdir/upstream/bin/wasm-strip");
+ ninja.WriteLine ("wasm_opt = $emscripten_sdkdir/upstream/bin/wasm-opt");
ninja.WriteLine ($"emcc_flags = -Oz -g {emcc_flags}-s DISABLE_EXCEPTION_CATCHING=0 -s ALLOW_MEMORY_GROWTH=1 -s TOTAL_MEMORY=134217728 -s NO_EXIT_RUNTIME=1 -s ERROR_ON_UNDEFINED_SYMBOLS=1 -s \"EXTRA_EXPORTED_RUNTIME_METHODS=[\'ccall\', \'cwrap\', \'setValue\', \'getValue\', \'UTF8ToString\']\" -s \"EXPORTED_FUNCTIONS=[\'___cxa_is_pointer_type\', \'___cxa_can_catch\']\" -s \"DEFAULT_LIBRARY_FUNCS_TO_INCLUDE=[\'setThrew\', \'memset\']\"");
ninja.WriteLine ($"aot_base_args = llvmonly,asmonly,no-opt,static,direct-icalls,deterministic,{aot_args}");