targets/wasi: remove --export-dynamic linker flag

Exporting symbols seems to embed them in the WASM exports section which
causes wasmtime to fail: https://github.com/bytecodealliance/wasmtime/issues/2587
As a workaround, it is possible to specify the `--allow-unknown-exports`
flag on wasmtime.
But as discussed in the above linked issue, this seems to only be a
workaround. For the Rust compiler the fix was to remove the
`--export-dynamic` linker flag when targeting `wasm32-wasi`:
https://github.com/rust-lang/rust/pull/81255
Which is waht this commit does for Tinygo too.
Этот коммит содержится в:
ZauberNerd 2022-03-18 10:42:32 +00:00 коммит произвёл Ayke
родитель 2fdcabdcce
коммит 0b5d300d94

Просмотреть файл

@ -11,7 +11,6 @@
"ldflags": [ "ldflags": [
"--allow-undefined", "--allow-undefined",
"--stack-first", "--stack-first",
"--export-dynamic",
"--no-demangle" "--no-demangle"
], ],
"emulator": ["wasmtime"], "emulator": ["wasmtime"],