wasmerio / wasmer

🚀 The leading Wasm Runtime supporting WASIX and WASI
https://wasmer.io
MIT License
18.93k stars 811 forks source link

There is error when I am tryin to run converted raylib game from wasm to apple M1 #3180

Open lvdpower opened 2 years ago

lvdpower commented 2 years ago

Describe the bug

There is error when I am tryin to run converted raylib game from wasm to apple M1
(I have compiled to webassembly this game and it run via browser good)

https://github.com/zf3/raylib-games-wasm/blob/main/README.md

But I am trying to convert it to native and I have this error.

timur@Mac-mini-timur arkanoid % ./wasmer create-exe arkanoid.wasm -o ./program
Compiler: cranelift Target: aarch64-apple-darwin Format: Symbols Using libwasmer file: /Users/timur/.wasmer/lib/libwasmer.a Using path /Users/timur/.wasmer/lib/libwasmer.a as libwasmer path. ✔ Native executable compiled successfully to ./program.

timur@Mac-mini-timur arkanoid % ./program Error getting WASI imports! Error len: 44 Failed to resolve import "env" "glViewport"

echo "`wasmer -V` | `rustc -V` | `uname -m`"

Steps to reproduce

Expected behavior

Actual behavior

Additional context

syrusakbary commented 2 years ago

wasmer create-exe only works with Wasm WASI executables, we need to improve the error when compiling so create-exe fails with an error early on (it seems the Wasm file was generated with emscripten)

stale[bot] commented 1 year ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] commented 1 year ago

Feel free to reopen the issue if it has been closed by mistake.

stale[bot] commented 4 days ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.